Brain Refuse Depository

Thursday, October 31, 2013

Last Deposit

This may be my last post here. With great pains, I've decided to stop posting to the Brain Refuse Depository. At least, I'm going on an indefinite hiatus.

Why? Well, first of all, I'm not the person I was when I started this blog. I've grown and changed a lot since 2004, which is a good thing. To put that in perspective, I hadn't even started my junior year of high school when I started posting here. And though that person propelled himself in a direction to become the person I am today, I'm not that person, so it doesn't make sense to collocate my current thoughts and attitudes with those of someone whom I'm not, presenting them as if they came from the same. It's fun to look back, but the juxtaposition is unwarranted.

This includes not only the subjects of the posts, but their construction and means. The way in which I went about arguments is different from how I go about them now. Of course, this will continue to change, but the change has been more dramatic in the past three years than any other time in my life.

Second of all, this was always intended to be, at least slightly, anonymous. It isn't really--a lot of people know this is me, but you'd have to know. As I move on to bigger and different things, I'd prefer to concentrate my efforts on a blog that isn't anonymous, constructing a reputation as a researcher.

Third, in my youth, I long struggled to find free, reliable webhosting. Between Geocities, Xoom, and Tripod, I found no satisfactory solution. Eventually, in my angsty teens, DeviantArt came along, and before it was taken over by furries, it was full of angsty teen poetry--my angsty teen poetry. This turned into angsty teen rants, wherein someone recommended I start a blog. So I did, and I never really returned to DeviantArt.
That happened in August 2004, and that's where this blog began.

Life has changed. I can afford to rent webhosting now and do. Consequentially, I have no need for free whatever and can host my own website and blog, at long last.

Saturday, August 25, 2012

A Strong Burger

Marketers can't figure our generation out. They don't seem to have a way to convince us to consume their products, so let me explain in clear terms. We don't trust you, and we are tuned to repel marketing bullshit of any magnitude.

For me and assuredly many others who grew up with me, this started in my childhood. Advertisements for toys and games were shoved down our throats. We listened eagerly, and our expectations grew. When we broke open that toy, and the results looked nothing like we were promised. I may have enjoyed Super Soakers as a kid, but actually using one was nothing like this:

On top of it, they always managed to come up with a bigger, better Super Soaker, one that my childhood budget couldn't afford. The disappointment from each round of commercials compounded when I did manage to get my hands on a new one.

So what happened? You taught us, toy-by-toy, not to trust marketing. No product ever actually delivers on making the consumer as cool, confident, or happy as the product claims to be able to. That's a lesson learned we won't forget.

What do we buy, then? Things we genuinely need and want. For example, I buy music. How do I make decisions on these things? I first ask friends. Consider a conversation I had with a friend of mine the other day:
"I bought Bitte Orca the other day."
"No shit, I love that album."
"Yea man."
"You should hear the new one. I was not disappointed by it."
So, the new album was a quality product, as verified by my friend. This convinced me to buy it.

But sometimes, a friend's recommendation isn't the whole story. Friends convince me because they are genuine. They don't have any motivations except their own desire to express joy for something they enjoyed. This isn't always they case; when they have ulterior motives, I don't really take their opinion at face value--eg, they got caught up selling knives or Amway.

That means that what convinces me to buy things isn't what anyone says but what a genuine reviewer says, like this guy:

This guy is so genuine, it hurts. It convinced me to go to Five Guys for the first time in years. That was a good burger, a strong burger; I was glad to have eaten it. I was glad to have listened to someone with a genuine opinion.

Thursday, May 31, 2012

"What you doin in our shiʔy country?"

A thirteen-year-old whom I suspect was cutting school posed this question--"What you doin in our shitty country?"--to me about two weeks ago outside a museum in Manchester. The short answers: (1) I'd always wanted to travel abroad and figured England would make a good first step and (2) I'm a big Joy Division fan, and Peter Hook was performing some of their songs for the first time in thirty years. For once, I had the money, so if I were to ever go, this was the time to do it.

All-in-all, Manchester reminded me a lot of Chicago. Both cities really came into their own during the industrial age--Manchester before Chicago, but through the same sort of economic growth. Compared to the rest of England, Manchester as a city is only 150 years old or so. Also, both cities are very blue collar--or as the Mancunians put it, "working class"--and, consequentially, egalitarian. Everyone is very friendly. When I first went into a store, I thought they were just trying to sell me shit, but everyone I met was that nice. It was a really great place to visit, and having met a few folks there, I'd love to go back. My stay was brief, and people kept suggesting places to visit. I ran out of time before I could see them all.

Getting There

I left from National Airport last Wednesday. Altogether, the trip was long but not arduous. On the longer flights, I got aisle seats so I could stick my leg out.

On the flight in, I sat next to two women from Newcastle. They'd been in a wedding in Maine. They told me a few things I was surprised about, the most so being that Jersey Shore is huge in the UK. They even have their own spin-off called "Geordie Shore," named for the inhabitants of Newcastle. Consequentially, I wasn't surprised when I saw a large number of Snooki and Guido look-alikes in clubs and in public, colored orange with the appropriate hair stylings.

Arriving in the UK was disorienting for a number of reasons, mostly jetlag. I couldn't get myself to sleep on the flight, opting to read Hooky's book the whole time.

Instincts

To be honest, there isn't too much culture shock going to the UK. We've been separate 250 years, but our countries have been intertwined in trade and communication the last 150. Our cultures never really wandered apart. For example, it's not hard to find a cup of coffee. I was drinking Americanos most of the week, which isn't a bad trade off.

Nevertheless, there's a few things that really threw me for a loop. Left-side driving absolutely blew my mind. I suspected cars driving on the "wrong" side of the road wouldn't get to me too much, but I hadn't the slightest clue. Right-side driving is completely ingrained in my brain, perhaps even as deep as language itself.

Consider this. When you look at a strip of road, you come to all sorts of conclusions about it without much evidence, using what you have learned about roads and driving over the course of your life. Traveling into Manchester by train, I saw a car on a road, driving on the left. By default, I assumed the strip of road the car drove on was a one-way, and being in a more open, grassy area, I looked for the separate part of the divided highway. My brain had "placed" such a separate segment, but when I actually thought to look for it, there was no such segment, and I became very confused.

This same thing occurred in cities, but in an urban context, instead of placing a separate one-way strip, I simply assumed the road was a one-way. When I saw evidence contrary to this, it threw me for a loop, every time. This was incorrect. Doubling my confusion, there actually were one-ways, so without really stopping and thinking, I could never tell what the roads were doing. In other words, I couldn't read them.

After a few days, I started to think I was getting a hang of it, though at times, I gave up and just waited for walk signals. I was no master of the left-handed arts. I remember standing at an intersection, waiting for the light to change. The intersection itself was pretty complicated, but I had expectations as to how it worked. Then a car drove the "wrong" way and totally shattered those expectations.

I was located on the southern side of this intersection. To complicate things, there are a lot of one-ways and what not that merge at this point, but I still expected a car to emerge from my left while traversing the intersection. When one came from my right, it shattered all my hopes--how few they were--of ever driving in the UK.

Besides driving, in England, you don't tip by default. As a friend of mine quoted a bartender, "they pay us properly here." This was instinct was incredibly difficult to overcome, and I always felt really odd leaving somewhere without tipping. This was also very convenient. Tax was also included in the price of things, so if something cost 6 quid, it really cost 6 quid.

Beyond those things, there's a few little differences, and for the most part, I felt like I was having a strange dream where everything was just a little different. A lot of brands carry over to the UK with the same logos and typesetting but different names. The names for things on signs like "bathrooms" and "checkout" become "toilets" and "cash and wrap." It's like in a dream when you read some text, and the text isn't what it ought to be. You know something is off despite that most things match your expectations.

How tied together our countries are became apparent while wandering around on my first day there. I saw a statue that looked an awful lot like Abraham Lincoln. It, in fact, was a statue of Abraham Lincoln.

The textile industry fueled much of Manchester's early growth. When the American Civil War started, imports of cotton from the American south stopped, causing the Lancashire Cotton Famine. The south boycotted exports to try to force the United Kingdom to support the Confederacy. This didn't work, as workers supported the Union cause to end slavery. Abraham Lincoln wrote a letter acknowledging the plight of the Mancunians, and the US government sent some food aid.

All-in-all, I wasn't there too long and didn't have time to make deeper observations. To stay longer, I'd have to find some real business there. I get antsy if I don't have some kind of work to accomplish.

Staying in a Hostel

This was my first time staying in a hostel. It was really cheap, which was the main reason I chose it. I stayed in a ten person dorm room, which was almost never full. This had its advantages and disadvantages.

The hostel itself was clean and well-maintained. There was always free coffee, tea, and toast, which was a nice plus. For the most part, I tried to avoid sitting around though. I didn't travel across an ocean to hide in a room and read a book; I wanted to bump heads with people. This was another reason not to book a hotel room, after all. I had no intention to use it.

The people staying in the room changed from night-to-night. A few stayed two nights, but two rounds of roommates came and went during my stay. In some respects, I liked this. I met and interacted with a lot of people that way; I met people from Australia, France, Brazil, China, and Germany, among others. It was great exchanging thoughts and stories with these folks, even in such a high-speed way.

I was in the hostel for five nights. One of them, the room was full, and that was undoubtedly the worst night. One man snored to no end. Someone later told me of a solution for this--making a loud sound like clapping can make the snorer shut up for five to ten minutes--not all night, but possibly long enough to get to sleep. I wish I'd realized this at the time. It wouldn't have solved the other discomfort of that night--a younger gentleman one bunk below me who was probably the most restless sleeper I'd ever encountered. He may have punched my mattress two or three times and would randomly hum directionless tunes throughout the night. He also did this when he woke up the next morning to iron his shirt again, then meandering randomly around the room for half an hour before building up the nerve to leave.

Even with one bad night, it didn't ruin the trip or even the hostel. I will definitely repeat the experience again. However, I do not recommend hostels if (1)you like your privacy or (2)you want to be left completely alone. If you want to be left alone, though, why are you travelling? Go back home, hide in your house.

Pounds and Dollars

I got lucky with the conversion rate on this trip. I pulled money from Natwest ATMs exclusively, and I don't think either my bank or Natwest charged any fees. I got nearly the exact exchange rate, which is around 1.5 pounds to 1 dollar. This was easy to convert to dollars in my head--just add half the price in pounds.

Thanks to the exchange rate, I was paying less for a lot of things than I would pay back home. Because pounds are a stronger currency, things are sold for fewer pounds than they would be dollars, so though you're carrying fewer pounds, you can end up with equal or greater buying power if the exchange rate is right.

A beer in a pub or club was usually around 3 quid, which worked out to $4.50. In DC, you pay at least $5 on most occasions, plus you have to tip and pay sales tax, so the price always comes out to at least $6 a beer. The same went for a lot of meals. The cheapest meal I bought was at a department store for 2 quid, so $3. This is about what you'd expect to get breakfast for in the States, if not more.

Pubs and Bars

When I first walked into a pub, I was surprised by the atmosphere. The lighting was soft and warm; the floors were carpeted. When I sat down with a pint of cask ale, I really felt comfortable. My feet didn't stick to the floor, for example. I'd never experienced anything like it in the States.

Disappointingly, young people think of pubs as being for old people. They all go to clubs, where you pay 10 quid to get in and then 5 quid for tiny drinks. We do the same thing here, I suppose, but I'd probably spend a lot of time in pubs if we had them in the States. I guess if pubs weren't a novelty, they would be for old people.

18 May

The 18th of May is, as Peter Hook put it, Ian Curtis Day. This was the day that Ian Curtis hung himself at his wife's home in Macclesfield. On the 18th, I went to Macclesfield.

Macclesfield is what one would expect from a small English town. Lots of small townhouses, packed close together. There's a church and market in the middle, cobblestone, gray skies, and green hills in the distance.

To get to Macclesfield, I took a train. The train service was excellent. I probably waited less for trains between cities than I did for the Metro. Round trip was 8 quid.

Upon arrival, I first walked to the cemetery to see Ian's grave. The cemetery was quite large, and I went to a small administrative house to ask for directions. I told the woman working there I was looking for a grave; she already knew what I was looking for and handed me a pre-prepared map.

I'm not sure why I expected no one else to be there. I was there but five minutes, and I spoke with two locals and an American who'd come to pay their respects. A small shrine was on top of the tiny grave marker, sprawled out onto those around it, with pieces of remembrance and loose change placed on top of it.

The American I met there suggested that I check out the book of remembrance in a nearby building. There, turned to the page for 18 May, were lyrics from Twenty-Four Hours written in calligraphy.

After this, I made my way to Barton Street where Ian and his wife had lived. There were other folks there: a girl with a rose who hid behind a corner listening to an iPod and two guys from Preston who had driven up. I spoke with the guys from Preston for a while, and one guy pointed out a lot of stuff to me--the window of the "blue room" where Ian wrote all of his songs, and that the actual unemployment office where Ian worked was really right around the corner, like in this clip:

I hadn't realized it before, but the clip filmed here is the exact walk Ian took to work everyday, from 77 Barton Street to the unemployment office. We took the walk and also walked through South Park where Ian used to walk his dog. They were great guys, and I was happy to have met them.

The show that evening was excellent. Both Hooky and the audience were totally engaged, the occasion giving the show extra poignancy. Hooky didn't do a bad job singing either. Shadowplay (starting at 5:12 in the first video) and Love Will Tear Us Apart were exceptional, as you can hear the audience singing along:

Hooky didn't attempt to do the Ian Curtis dance--I don't think anyone will ever manage to do that right. However, he managed to tap into some of the same morose intensity Ian had had, especially during Decades:

Oh my god, I love your accent!

While in the UK, for the first time in my life, I had a sexy accent. This was really wonderful; girls kept buying me drinks left and right. It's an experience I'd love to repeat.

The same applies in the States for an English accent. It seems both our countries are fascinated with one another. When speaking with people, we often spent most of the discussion comparing our two countries. From the fallout of the Bush years, I expected a lot of disdain, but instead, there was a mutual curiosity that transcends politics.

Final Thoughts

I tried to avoid doing touristy things while in Manchester. This wasn't too difficult, as Manchester isn't really a touristy town. My last day in town though, I visited the Museum of Science and Industry, which is housed in the site of the first ever commercial railroad warehouse. This is because Manchester was the first industrialized city in the world; it wasn't even really a city before that point. The Manchester-Liverpool line, which terminated at that warehouse, was the first commercial railroad.

For a museum, it was quite impressive. Most museums have machinery on display, static and cold. MOSI had real working steam engines. Seeing and hearing a steam engine in action was amazing.

Something the videos don't capture is the heat, radiating off the machines. It made them seem warmer, more alive.

The museum summed up Manchester in a way. So many of the inventions at MOSI were machines where one had been reappropriated and slightly modified to perform a new task, each invention building off the next. This happens in software too, but I hadn't realized it was a driving force behind the majority of inventions.

This process of reinvention was able to take off in Manchester, triggering the industrial revolution, leaving behind waste that--thirty years ago--created an environment that sprouted some of the most brilliant music of the 20th century. A sign outside Factory 251 said that more rockstars have come from Manchester per capita than any other city in the world. I could believe it. In a strange way, Manchester seemed ahead of its time, perpetually pushing forward in culture and science.

Thursday, April 19, 2012

Just Skip Precession

Precession is an effect angular momentum has on a rotating object. It's pretty neat stuff because its consequences seem so strange. It's why tops appear to wobble and boomerangs come back.

A lot of people bring up precession when discussing seasons. This is because the earth is rotating, so it too experiences precession. However, this is not the cause for seasons but a consequence of the cause--tilt. Because the earth is tilted, the length of the day changes as the earth goes around the sun. The length of the day changes the amount of light the earth gets; the amount of light the earth gets affects temperature, an effect we call seasons.

The connection between light absorption and temperature is really important but doesn't get much emphasis. To understand global warming, you first have to grasp this concept. Yet for some reason, precession, an obscure fact related to angular momentum, gets thrown in while explaining seasons. Sure, it's a consequence of tilt, which is the cause for seasons, but it just confuses someone who is trying to grasp the concept that the earth is sideways.

Then, on top of it, people try to use tops as a metaphor to explain precession. Tops precess at about 1 Hz, unlike Earth, which precesses at 8.11012998 × 10^-11 Hz. So then people get confused because you just told them the earth is sideways and then tossed in counter-intuitive facts about angular momentum with a confusing metaphor to explain them. Just skip precession. You can cover it when you discuss momentum. If you're not discussing angular momentum, it's not important.

Sunday, April 15, 2012

Classical Music Riots

A couple months ago, I listened to a Radiolab episode on "Musical Language." One of the things they talked about was how music affects the brain--in particular, Igor Stravinky's Rite of Spring. Apparently, novel sound patterns can trigger the release of dopamine in the brain. In small doses, dopamine is pleasing. However, a large enough disruption can cause hallucinations and psychosis. This has happened before, many times, because of classical music. Here are a few:

I'm not sure whether this is the exact portion that triggered a riot or not. This is the oldest one on the list. In 1830, a portion of the piece involving patriotic and revolutionary themes started a riot that led to the Belgian Revolution, ceding Belgium from The Netherlands.

Strauss based Salome on a play written by Oscar Wilde. For years, it couldn't be performed in London. Most notorious is the final portion of The Dance of the Seven Veils, where Salome kisses the severed head of John the Baptist.

This was the first of these that sounded familiar to me. It begins deceptively peacefully, but by 3:35, it takes a turn for the awesome. A name like "Rite of Spring" sounds so happy--Vivaldian, if you will. The premise of the play, however, is a young woman dancing herself to death, and the choreography and music reflect this.

During the premiere, the audience was split between loving the piece and hating it. Fist-fights started in the aisles, followed by a full on riot.

Monday, March 26, 2012

Word Tokenization

Word tokenization is an NLP task where one breaks a string of characters--letters and spaces--into words. In English and other words with spaces, this is pretty easy; it's virtually been done by the writers (with exceptions of sentence terminal periods, n't, and 's).

However, other languages, like Chinese, require a lot more work. Chinese doesn't put spaces between words.

Often, this is written about as a purely NLP task. This isn't quite correct. Spaces proper weren't invented until the middle ages. ASI'LLDEMONSTRATEHERE,YOUREALLYDON'TNEEDSPACES.ITMIGHTBEALITTLE HARDERTOREAD,BUTTHEANCIENTROMANSBUILTANEMPIREWRITINGTHISWAY. WORDTOKENIZATIONINTHEAUDITORYANDVISUALSENSEISEASILYPARTOFOUR LANGUAGEFACULTY.

Since we can do the task naturally, it's just as much a problem of linguistics as natural language processing.

Sunday, March 25, 2012

No Exceptions

I haven't kept up with politics lately. Watching a bunch of idiots run around and call one another even stupider names is entertaining, but I am preoccupied. To play catch-up, I was reading about that Santorum guy everyone is talking about, in particular his attention-seeking crusade against porn.

For a long time, I've tried to understand the conservative mindset, and while reading Santorum's opinions, I had a realization. Santorum spoke of pornography as if it angered God himself in direct opposition against the United States. I'd heard this perspective before, but for the first time, I thought of the story of Sodom and Gomorrah, where God sought to destroy the cities because they were full of sinners. It became clear that this is what hardcore conservatives actually think will happen to the United States if we don't fall in line with their image of what God wants.

This may not seem a novel concept, and it's really not. What I realized was that we--the further ends of the right and the left--aren't that different. Part of the reason I abandoned my faith was that I got tired of writing exceptions. The more I learned about the world, the more exceptions I had to creatively twist into place to include faith in my life; for example, "well, things were different in Bible times," "well, that line of scripture is archaic, they just didn't know any better." Fundamentally, I was lying to myself, as does anyone justifying something they know is wrong.

Instead, I put my faith in the capacity of rigorous observation to yield knowledge about the universe. The knowledge isn't purely faith per se, as it's constantly under scrutiny. What's really taken on faith is the method, though it does have results to show--the computer you're reading this on ought to suffice as a triumph of science.

In the end, I've put my faith in this group of people over the centuries. I've trusted them with the work of explaining the universe and their way of doing it. In the conservative mindset, they too have put their faith in a group of people, just a different one. Just as I could not allow exceptions to what I had learned, they do not allow exceptions either. They really think the return of God is at hand because that's what the Bible says. They really think that God tears down forsaken nations.

As much as I disagree with them, I respect their integrity. Perhaps I see a bit of myself in them; despite coming to different conclusions and even having different techniques for coming to those conclusions, we have some core value that is unwavering.

Sunday, November 27, 2011

Explaining What I Do

One of the first things you do when you meet someone is explain what you do. Often, not much explanation is required--"I am a nurse" is pretty straight-forward, for example. For a while, I told people, "I am physics major, and I do research in astronomy." That's pretty easy to explain. People know what physics is, and they know what astronomy is. Explaining my research was pretty straight-forward too, "Right now, I'm searching the literature for guesses of stellar ages" or later on, "I'm looking for binary stars; it's a subset of a bigger projecting looking for debris discs--dust and stuff that orbits around stars and could form planets."

That stuff is really tangible. People know what stars and dust are. Overtime, I got better at explaining it quickly and simply. I'd forgotten how much tweaking it took to get it to that point; now that I'm in a new field, I have no routine for explaining what I do, and that's very strange. I'm passionate about what I do, but it's hard to convey that when I'm fumbling with how to explain my research.

The shortest explanation is to say it flat out--"I'm a computational linguist, and I do research in gradable modal expressions"--but that usually leaves them with a blank stare. The structure of the sentence telling people formerly and presently what my research is is nearly identical, yet the present one leaves them dumbfounded. I can't blame them, most people have probably never heard a single content word in the latter sentence, except perhaps for "I," "research," and maybe "expressions."

At this point, I try to break it down, starting with "computational linguist." In all likelihood, they've never heard of linguistics, and I lose most people here. I tell them that it's the scientific study of language, and they tell me who their favorite poet is.

In fact, linguistics doesn't really have good PR. Few people have heard of the field, and without any exposure to it, it's really hard to explain what linguists do. Most often, people's concept of the study of language is in some classroom with a teacher who wants to "free their mind," not in a formal context where language is broken down rigorously and elegantly.

On the other hand, physicists and astronomers have great PR. Most major projects are multi-million dollar rocket launches and magnetic loops capable of observing or replicating the beginning of time.

In fact, astronomers have had excellent PR for years. From Sagan to deGrasse Tyson, charismatic figure heads have been directing the public's attention at colorful pictures for years. Linguists are stuck with, at best, Noam Chomsky, who is rarely talking about linguistics in public appearances, instead preferring to talk about the Military-Industrial Complex.

It's a damn shame, as people are more interested in language than they realize. Sometimes, when you do explain what linguistics is, the concept really clicks. You can tell they get it, and one of two things happens: either they become very interested and you introduce them to the idea of voiced vs unvoiced consonants or ungrammaticality, or they become very defensive, striking a nerve with regard to the legitimacy of Black Vernacular English or the concept of generative grammar. Inevitably, people are strongly invested in their understanding of language, but few realize that they can seek a deeper understanding of something they do so systematically yet so effortlessly.

So at this rate, you can see my dilemma. I've only thus far explained what a "linguist" is, and now I have to tie it to the word "computational." This one's a little easier, as I just give examples--"machine translation, Siri, getting Google to know what you meant by your search, and not just dig up the words--effectively taking all that linguists have discovered and implementing it on a computer." So if people got "linguist," then the "computational" bit is easy.

This leaves me with "semantics," "gradable," and "modal" to explain. In themselves, they are not hard to explain, semantics being the trickiest, but then they have to be tied together.

So usually, after a long set of explanations, I end up with a blank stare and a dead conversation, and that's never a good outcome. I'm not sure how else to explain it, beyond dodging the topic completely, or just restricting myself to linguistics. That's tough enough to convey to most folks. Maybe I could take the pretentious route and say, "ah, you wouldn't get my research, it's too deep for your plebeian brain, maybe when you're reincarnated with a better brain," but that's just rude.

Perhaps I should leave it in the shallow, "I'm a linguist, and I study how people express possibilities." When they ask, "What do you mean?" I could respond with, "Well, I could explain it to you, but that would take a while," and then use that as an example of a modal expression. Maybe that's too meta, though.

Monday, October 03, 2011

Tarski's World: When and Where Grade Grinder's Cheat Prevention Fails

For my semantics class, we have been using a "book" called Tarski's World to quickly learn, interactively, predicate logic. "Book" is in quotes because it's mostly a suite of software that is sold with the book for using predicate logic within a simplified world.

My feelings are mixed. Some of the exercises are interesting; others are tedious. What's come to bug me the most has been the grading software. It's very bad at giving decent advice, which, after banging your head against a computer keyboard for a while, is exactly what you need.

Sure, this process is frustrating, but in the end, I've learned a lot of predicate logic. On the contrary, what bothers me most is the false accusations the grading software generates--in particular, the claim that my solutions are "similar" to someone else's, effectively the suggestion that I'm cheating. As an academic, this is really insulting, and something up with which I will not put.

According to the link in the "you're a cheater" message, Tarski's World saves a 12-digit timestamp with every save. It claims the odds of two students saving a file at the same time is the same as winning the California lottery. This is accurate. When you upload a file, it looks at the other sets of timestamps that the file was saved with. If there are overlapping sets of timestamps at any point, the files are declared "similar."

However, the designers overlooked one thing. Some exercises require that you start with a particular world that Tarski's World has provided. Whoever wrote these files saved them at some point, and therefore, they are guaranteed to be similar by the above definition--the files originated at the same point in time and are therefore similar.

To verify this hypothesis, I opened up a Tarski's World world file. To my surprise, the file was nothing but plain text--no attempt of any kind to encrypt or obfuscate the file and timestamps. The dates immediately stood out as Unix time--that is, the number of 60ths of a second that have happened since January 1, 1970. However, using these whole numbers yields gigantic results--the standard time for one of the timestamps put me in the year 45000, which was clearly not the case.

I attempted to shorten the timestamps to find the Unix time within them; it's merely the first ten digits. The last two, I assume, are some kind of checksum. I tinkered with reverse engineering them, for fun, but I don't have that kind of time right now. More importantly, I knew where to find the evidence I was looking for and started piecing it together.

A "C" or a "D" precludes each timestamp. "C" stamps preclude "D" stamps. Sometimes, there are multiple instances of "D." What this looked like to me was "C" is some how a computer ID--maybe the time when someone installed Tarski's World on that particular computer. Checking one of my own C's, this turned out not to be the case, and it's probably the time when the file is opened. Either way, the precise meaning of the values is irrelevant. What matters is that I know the file was being tweaked around the time of that stamp.

I used Python's datetime module to handle the Unix times. The "D" and "C" values in the latter part of one of the files pointed at 2011. Checking out the "C" in one of the files, the Unix time portion of the stamp pointed right at 2004. This was a red flag and the cause of my commrades and I's woes.

So, to correct the Openproof Courseware website, it is not extremely unlikely that two files will be created at the same time. If those two files are meant to originate from the same file, they are guaranteed, by your definition, to be similar. Please rectify this, or at least mention the fact that "since some exercises were created by us you can relax blah blah blah..." instead of assuming that we're cheating because your work is sloppy. Then, I'll quit blaming you when my sentences are sloppy.

Also, you might want to look into not storing the timestamps in plain text. It would be incredibly easy to manipulate them, you could literally just... well, I won't get into that here. Someone who knows the files are plain text knows too much already.

Sunday, August 28, 2011

A Few Venus Jokes

Venus is likely the most inhospitable planet in the solar system. The greenhouse effect has driven surface temperatures are so high that they are warmer than Mercury, a planet closer to the sun. It is perpetually cloudy, rains sulfuric acid, and is absolutely bone dry; the greenhouse effect boiled all of the water off into space. The Russians sent few probes there, one sent back a picture of the surface.

If this looks crappy, bare in mind, it is the only picture we have of the surface of Venus, and it took 9 attempts to capture and transmit back to earth. In the test chambers they made for prototypes, they frequently would open the chamber after a test to find their work reduced to a puddle of molten metal.

Such a horrible environment yields some horrible humor:

On Venus, the sun rises in the West, but it's always too cloudy to see it.

On Venus, you could cry in the rain, but your face would get burned off.

Thursday, August 25, 2011

map() | filter() | reduce()

I've been learning Python slowly over the last two years. It's the first language I've used where I really have a chance to tinker with the tools of functional programming. At first, they appeared outright bizarre, but the pieces have finally fallen in place. A few weeks ago while running, I couldn't stop thinking about how awesome "map()" is. Hopefully, after reading this, you'll feel that way too.

Here's what map() does: it takes at least two arguments, a function f and n lists, where n is the number of parameters of f. Its output is a list where every entry is f(l_1[m], l_2[m],...,l_n[m])--that is, it takes every item in the list, puts it in f, then stores it in a new list and returns that list when it does.

Sounds kinda pointless, right? You could just use a loop to do that.

newList = []
for item in list: newList.append(f(item))

Map does this same thing more concisely:

newList = map(f, list)

Perhaps I haven't convinced you. Part of the value in map() is concision. It's clear, in the third piece of code, what you're doing--creating a new list by funneling list through f. Mentally, that is a simple procedure. To express it explicitly, with all its overhead, is more sophisticated. Someone reading the code would have to stop and think "ok, he's looping through all these entries, putting them in this array, then storing them in this array." All that overhead obfuscates; concision presents the operation with less mental overhead, allowing the reader--and the coder, for that matter--to focus less on the overhead and more on the algorithm at large.

Additionally, map() is optimized for its purpose--loops are not necessarily. As a consequence, you end up with faster runtime. Consider this script, where two sets of random numbers are funneled through testFunc:

Running on my crappy laptop, the loop took nearly three times longer to execute.

There are two other functions that are just as cool as map(): filter() and reduce(). They perform different, albeit valuable, tasks. Filter() doesn't accept just any function, but requires a boolean function;

filter(lambda x: x>2, lst)

would be acceptable. Filter(), like map(), returns a list, but it returns a list of values from lst where the provided function returns true.

Last of all is reduce(), which takes a function of at least two inputs. To start, it takes the first two values of a given list and puts them in the provided function. Then, it uses the previous result as the first parameter and the next entry of the list as the second parameter. So, a sum, for example, would be:

reduce(lambda x,y: x+y, lst)

The real power with these functions is that they return lists, so once they produce a result, it can be nested in another one of the set. As another example, this one-liner removes dead "twirps"--those without any calories left--from the testTwirp array:

map(testTwirp.remove, filter(lambda x: x.calories < 0, testTwirp))

The invocation of filter finds the twirps that are dead; the map of those twirps into
their original list's remove method takes them out of the picture. The resulting list isn't saved, as it's just a large list of "None's."

Saturday, July 30, 2011

Why People Haven't Adopted Dollar Coins

I've heard that dollar coins haven't been widely adopted because people hate them. That's a load of crap. Dollar coins are wonderful--it's nice not having to fumble with your wallet to use a vending machine or make another small purchase. If I could get dollar coins, I'd be happy to use them.

The problem with dollar coins is ATMs. Most people, when they receive currency to spend, it is through an ATM. ATMs dispense $20 bills and sometimes, if you're lucky, dispense $10 bills. I'd prefer to have 10 dollar coins, but instead, I have a 10 dollar bill that someone has to break.

That someone is generally a large retailer. In effect, large retailers are where most people get smaller bills. If they chose to deal in dollar coins, we'd have them circulating by now.

Sure, at first, people will hate it, but I'm sure they'll approve once you warm them up to the idea. Eventually, they'll wonder why they ever thought dollar bills were a good idea at all.

Thursday, June 30, 2011

Factorial Function One-Liner in Python

I recently got a copy of the Python Cookbook. This is the first programming book I've picked up that one would call "advanced." That is, it assumes you know what an if-statement does. As a result, the book is rather refreshing.

I picked this book up because I've been looking for a solid place to read code, something I've heard advocated frequently among more experienced hackers. The book is full of code examples and explanations, and seeing how other hackers solved particular problems makes it clear why reading code is so crucial to coding better. In nearly every piece of code I've read through, I've encountered something new. My favorite so far is 17.9: Computing Factorials with lambda:

f = lambda n: n-1 + abs(n-1) and f(n-1)*n or 1

So, this is the factorial function, contained entirely on a single line. A few subtleties of Python allow it to work, which the book explains quite well.

First of all, when a lambda form is defined, it isn't evaluated. This allows lambda forms to be defined recursively. Generally, lambda forms are not assigned names--they're "anonymous functions"--but they can be, as was done here.

The other trick--and the part that wasn't obvious to me--was the use of the ternary operator, which I'd never heard of before this. In C, there's a statement with the syntax:

condition?iftrue:iffalse

So, effectively, this can be thought of as "Is condition true? Do iftrue. If it is false, do iffalse." In Python, the syntax is:

condition and iftrue or iffalse

This allows you to write one line if statements. Combined with lambda, you can write one line recursive functions this way, where condition is your continue/escape condition.

Consider, also, the condition. It's not an explicit boolean statement. However, Python has implicit boolean evaluations. For example, an empty list "[]" evaluates as false. Similarly, "0" evaluates to false.

If you're doing anything more sophisticated, this is rather pointless. However, if you need merely choose between a base case or recurring, this is a simple, concise way to do it.

Tuesday, June 21, 2011

Natural Gas

A lot of fossil fuel companies have been pushing natural gas as the next big solution to our energy problems. This doesn't surprise me, and for the short term it's the way to go. However, we shouldn't stop developing alternatives.

First of all, there is more natural gas available than crude. This is because of what happens to fossil fuels as time progresses. They begin as peat, then are compressed into coal. After a few more million years, as they're buried deeper and deeper by the rock cycle, they're compressed into what's known as oil shale--the middle state between coal and oil.

With a little more heat and pressure, the oil shale "cracks" into crude. However, we can speed up this process a bit, which is what we do when we dig up oil shale. It's rather inefficient; the amount of energy we get out of the oil is drastically reduced when we have to force it out of the ground. When we first started digging up crude, it would literally gush out of the ground. Now-a-days, not so much.

Deeper still under greater heat and pressure, crude oil can be cracked further; this is when natural gas is formed. It is the end result of the chain; there is no other fossil fuel with a better energy yield for the minimal amount of carbon.

As a consequence of this, natural gas supplies are far greater than crude. For the most part, we can keep digging deeper for natural gas; for crude, there's a limit. With large supplies, we could move to a relatively stable natural gas economy for the 21st century.

Although with advantages, natural gas has its problems. First of all, it's still a fossil fuel, which means it exists in limited quantities. If we are idiotic, as history has demonstrated, we will repeat the problem we are experiencing with oil right now. This time, as we burn through our next energy source, we can hopefully master the technology to rely on completely renewable alternatives.

Also, being a fossil fuel, it still produces greenhouse gasses. In fact, natural gas is a greenhouse gas--methane is the most potent of them all. Combustion cannot completely burn off all of the methane, so using it as a fuel source would increase the amount in the atmosphere. Additionally, any form of leakage during use would release methane.

In fact, leakage is a subset of another problem with natural gas--transportation and storage. Unlike gasoline and crude oil, which stay where you put them, natural gas likes to mix and mingle with the atmosphere. As a result, the containers needed to store and transport it have to be heavier and sealed better than those with liquid fossil fuels. This means that there's more overhead when using natural gas as a fuel source--for example, your car would have to be heavier, so its efficiency would be worse or range would be reduced.

This also begs the question of a natural gas wreck. Gasoline was chosen as a fuel in part due to its relative stability. You've probably seen plenty of movies where cars' gas tanks explode. For the most part, that's exaggeration. In fact, gasoline is rather hard to blow up, at least compared to natural gas. Liquid gasoline itself does not burn--it must be vaporized to do so. When it bursts into flame, the heat sets off a chain reaction, vaporizing more gasoline, allowing more gasoline to burn. Only with that chain reaction can gasoline burn.

Natural gas, on the other hand, vaporizes under normal atmospheric conditions, ready to burn. This higher volatility translates into a much greater explosive tendency. In a bad wreck, if someone broke the seals to their gas lines, their car would be ready to explode on the spot. No one wants that to happen; generally, lag time before the car explodes is helpful.

Another problem with natural gas is the extent to which we are willing to push for it. A process called fracking has been drawing a lot of attention as of late where natural gas deposits are pressurized to release previously unreachable natural gas. This process sounds gentle enough--however, many of these deposits are located near the aquifer, the place in the ground from where people obtain well water. The pressure seems to diffuse natural gas into the surrounding aquifer, resulting in flammable, bubbling well water.

Despite the potential risks, natural gas can solve our energy problems in the short term better than any other source. Like any other fossil fuel, however, it exists in limited quantities and is bad for the environment. Nevertheless, it's the next step in our progression of energy sources and buys us more time to get to something fully renewable.

If you'd like to read more about fossil fuels and peak oil, I recommend this book.

Saturday, June 18, 2011

The Cost of Ads

Recently, I installed Adblock and Flashblock on Google Chrome. I hesitated for a while--after all, websites had to get revenue somehow, and if it involved nothing more than a few pictures in constant motion, I was willing to accept that.

Although weary for the survival of the internet, I broke down and installed it because ads can be more than annoying. At times, the downright hinder access to information, like the pop-up hell pages in days yonder gone. Sometimes, they're downright malicious.

I couldn't take it anymore; between the paranoia and the nuisance, internet advertising had lost my trust. I was surprised with the results:First of all, the internet was smoother. It was like the first time I used Chrome, all over again. No giant flash scripts to execute; no overloaded adserve servers to access.

More so, though, I was stunned how much cleaner everything is. Look at the website to the left--it's clear, for the first time, someone actually spent time designing it. The information is presented with out noise or irritation. It's quite incredible how much simplicity is lost when the advertising is there; the agitation that distraction causes detracts in a way that's hard to describe and costly in immeasurable ways.

After all, I don't want a free iPad. I know I'm not your "winner." I want to know the lyrics to this song, and I want to leave. Everything else is just noise. However, I'm surprised how annoying noise actually is. I thought I was a master at tuning it out, but now it's clear how exhausting tuning is.

Sunday, May 15, 2011

Google vs Facebook: What?

Articles have been floating around that suggest Google and Facebook are fighting one another. This always seemed bizarre, an apples-vs-oranges comparison.

Google is where I get information and check my e-mail. Facebook is where I make plans and look at funny pictures from the past weekend. These are completely separate domains. Occasionally, one company tries to bleed over into the role of the other (Buzz), and it has failed dramatically. They can't compete; they work in parallel.

Not only do the two work in separate domains, they work with completely different metrics. Google works to reduce user time; Facebook works to increase it. The longer users spend on Facebook, the more value it has. The less time a user spends on Google, the better Google has done as a search engine.

The fact of the matter is, if Facebook vanished tomorrow, I'd be sad about losing pictures posted from college and before. Then, I'd proceed with my life, increased productivity, and general sense of greater well-being.

If Google vanished tomorrow, my life would be in complete disarray. Over the years, I've migrated my e-mail, documents, and calendar to their services. Combine that with the fact that if I had to go back to Firefox, I'd be a cranky bastard.

Facebook is ineffectual. Sure, I use it a lot, because there's a lot of people there and its well-designed. On the other hand, my life is built around Google.

What are they supposed to be fighting over, exactly? The social graph? Ooh. Steve is friends with Joe. What does that even mean? They're probably not friends. In all likelihood, they're just acquaintances. What does that mean? Nothing.

How about advertisers? I don't care about advertising where ever I go. I never click it. Under most circumstances, it merely shrinks the content area of a site, making it harder to read.

Wednesday, April 27, 2011

Where's The State Certificate?

Now that Obama has released his birth certificate, I wonder how long it will take the birthers to begin questioning the Statehood of Hawaii. My guess: tomorrow, though we won't hear about it for a month, when their inane blathering reaches critical mass for news media.

Monday, April 25, 2011

Life has existed on Earth for more than a billion years. During that time, many life forms accumulated energy and died. As time went on, they were buried underground and compressed by the earth, forming, literally, organic energy sources, born straight from life itself. These Naturally Accumulated Biological Energy Repositories, or NABERs, are widespread, many remaining untapped throughout the world.

This sounds bizzare, but with a simple, exothermic oxidation process, energy can be extracted from NABERs. The results are nothing worse than what emerges from typical biological processes.

A NABER reactor is safer than a nuclear reactor, as it lacks the possibility of a meltdown. It is less tacky than a wind turbine and requires less space than solar power. Additionally, there are nearly 3 yottajoules of NABERs available worldwide--that is 3,000,000,000,000,000,000,000,000 joules, so we'll clearly never run out.

Saturday, April 16, 2011

IDLE is Awful

When I first started working in Python, I used the built-in interpreter on the Mac. I was working in an astronomy lab at the time as an undergrad. For editing, I used the built-in text editor, TexTedit or whatever, and would run the Python scripts in a terminal window. They ran smoothly, and all was well.

When I started using Python at home, I started using Python for Windows. With it comes "IDLE (Python GUI)." It seemed nice enough at first, and I used it for a while.

It's only in retrospect that I can see that it was downright awful. The interface felt buggy. It forced upon me that four space shit--I know it's the convention; I don't care. Tabbing in any other text editor produces a tab, not four spaces. As a result of the "convention," the four spaces locked me into IDLE and made transitioning to any other editor difficult.

I'd had enough when I started testing applications that used Pygame. Nearly everytime I ran them, the editor would freeze and crash. Having to restart IDLE everytime I wanted to test my code made me very diligent about debugging but grow very distasteful of Python.

What brought me back? I had an idea for something, didn't want to write it in Java, and, although Lisp curious, didn't want to start on a new language. I wanted to prototype this thing, quickly.

Without IDLE, I happily exist on a crossbreed between VIM and command prompt. I know I could probably run my scripts right out of VIM with some hacky scripting wizardry--I don't care. I like my "IDE." My console window is a real console. My editor is my editor. They don't need to touch.

IDLE's so bad, it hurts Python and programming in general. When the IDE goes bad, new programmers blame programming. Programmers new to Python blame Python, even if subconsciously. I was all about programming in Python--after fighting with IDLE for a month, I stopped the project I was on all together. With IDLE being the most easily available approach to programming in Python on a Windows PC, can't something better be made available?

Of course, to use something better than Windows would be the first step.

Saturday, April 02, 2011

Exceptionalism

As long as I can remember, and long before that, people have been pushing products to magically reduce people's weight. They come in all sorts of forms--tapeworms, pills, exercise gizmos. They all swear they'll make weight loss easy and flawless while rattling off a list of quasi-technical jargon to validate their claims.

People must buy these things; otherwise, no one would keep making new ones. Do these consumers ever step back, look at the whole set of them, and think "hmm, if this last claim to easy weight loss didn't work out, is there any particular reason for this one to be different?" Other than catching up with the latest fads in marketing and design, the new varies little from the old.

Maybe, people think they'll be the exception this time. "Sure, that last weight loss drug was potentially lethal; this one, I doubt it." In fact, many people seem to think that almost all the time, and not just when contemplating which fat burner to buy. "If I speed, I'll get away with it because I'm special." Then, it's the cop's fault when they end up with a ticket.

Everyone lives in the best country in the world. They also practice the best religion in the world, which is different from all the others because it is theirs, and their religion must be right because all the other religions are wrong. After all, when they read from the Holy Book, they have tears in their eyes. That other Holy Book is a bunch of choppy, poorly-translated joke language. If it were a good religion, it would have been translated well into--or written originally in--their language, the best language.

Of course, because I'm aware that I'm not an exception, that makes me an exception and better than all the people who aren't exceptions. The smugness I feel is legitimate, unlike the smugness of all those other people, which is just unexceptional smugness.

Monday, March 28, 2011

Origins of a Few Programming Language Names

In the Python documentation, it explicitly states that the name "Python" comes from "Monty Python's Flying Circus" and has nothing to do with snakes. This got me thinking about the origins of other programming languages' names. A few of the stories I know, but by no means do I know all of them. There's a lot of languages out there, so this will be nowhere near complete, but hopefully I'll cover the basics.

C++: In C, as well as many other languages now, adding "++" to the end of a variable increments it by one. Naturally, then, "C++" is C incremented by one. Originally, C++ was called "C with Classes" because that's effectively what C++ is.

COBOL: "COmmon Business Oriented Language." Naturally, it was created by a committee.

BASIC: "Beginners All-purpose Symbolic Instruction Code."

ALGOL: "ALGOrithmic Language."

Java: It was originally called "Oak," but there was problems with trademarking that name. Effectively, the developers locked themselves in a room, spit out random words, and sent a list to the trademark lawyers. "Java" was fourth on a list of twelve, and the first to pass the test.

JavaScript: It was orignally called "LiveScript." The name was changed, some believe, to exploit the buzz surrounding Java at the time of its release. The selection has, at least, resulted in plenty of confusion.

MATLAB: "MATrix LABratory."

Lisp: "LISt Processing," since the entire language is parenthesized lists.

Pascal: Named for Blaise Pascal.

Perl: Originally, Larry Wall named "Pearl" for the Parable of the Pearl in the Gospel of Matthew. He discovered there was another language called "PEARL," so he changed the name to "perl." Later, the Camel Book changed the name to "Perl" because it looks better capitalized.

PHP: Orignally stood for "personal home page," though it has since been changed to be a recursive initialism: "PHP: Hypertext Preprocessor."

Monday, February 28, 2011

Supermetapost: Drafts

I mentioned in my last post that my posting has been sparse lately. It's not that I haven't been writing; it's just that many posts never make it past drafting stage. Since September 2010, I have started 25 posts; I have published 8. For many periods, this is a common thread--lots of beginnings, no endings. I want to explore why, here.

2004 QualityYou should avoid the archives. I keep them up in a spirit of completeness and transparency; however, I do not advocate many of the views I held back then in ignorance, naivety, and angst.

However, the way I start writing a post is about the same; I think of an idea and execute its development. More often than not, I could sum up the point of a post in a sentence. Getting there and going where it takes me fill in the rest. Sometimes, this produces really angst posts or posts where the only funny part is that I used the word "fuck" a lot. I don't post those anymore.

I never start writing.Sometimes, I think of an idea for a post and then don't write a single word, or I'll write a few words, won't really see where it's going, and quit.

I get bored writing and stop.If I become bored with writing something, I will stop mid-sentence. More often than not, the post will remain open for a bit on my computer, but I'll end up with a blue screen or reboot in a day or so and never see it again.

I realize, in the process of developing my idea, that I am wrong.To support my points, I try to provide links, videos, and funny pictures. In the process of finding these things, if I find evidence contradictory to my point or lack of critical evidence, I abandon my post. This happened, for example, in a post I was writing about Senator Boehner's last name. Although I'm pretty sure his name should be pronounced "boner" in German, I couldn't dig up strong enough evidence for it.

I feel like I have to do it.Most of my posts I write spontaneously, and a lot of the time, I don't really know where I'm going with them. When I feel like I have to be spontaneous... well, that's Valentine's Day. This might be what caused my present posting burn-out--the Moon of the Month experiment. Something similar happened when I started the RIAA Terror in Brief series.

The process of writing, in some ways, acts as a filter for shitty ideas. If you can't write them down, then they're probably not worth publishing. Some of these drafts, though, might make good posts still. I've done a few resurrections, though they're rare. Perhaps time will tell.

Thursday, February 10, 2011

Hiatus

I know I haven't posted in... almost three months. It's ok; I'm not dead. I've been applying to grad schools, etc. That's all that's been on my mind, and it's not fun to read about. Maybe it's not. Either way, I'll get back around to posting again. I just gotta get some momentum.

Monday, November 08, 2010

Moon of the Month: Miranda

In astronomy, Uranus is perpetually the butt of jokes. The name is funny, but to compound this, the planet is made of methane, the primary substance of farts. Yes, Uranus really is a big, smelly, butt planet.

Astronomers don't feel much pity for the planet either. As Voyager 2 cruised through the solar system, scientists were delighted by beautiful images of Jupiter and Saturn--bands of color, complex ring systems. Then they arrive at Uranus to see this:

Sure it's serene and pretty, but there's no reason to take close-ups. However, the visit wasn't a complete disappointment; Uranus' saving grace is its moon system. It's got 27 of them, five of which are "major" moons. These were the first moons for whom the Greco-Roman naming trend was broken; they have the names of Shakespearean characters.

The first of Uranus' moons were discovered by astronomy's number one badass--William Herschel. He thought he'd discovered six moons, though only two of them bore properties that matched later observations. Miranda itself was discovered by Gerard P. Kuiper; he has the entire belt of debris in the outer solar system named after him.

Most of Uranus' moons are relatively plain looking--smooth balls with craters. Voyager 2 snapped a few pictures of them, and that's about it. That's all we know about them.

Then there's Miranda, the bad nut. Voyager snapped pictures of it too, revealing giant regions of scarps bisecting the moon's surface. Some of these scarps are estimated to be 3 miles high, such as Verona Rupes:

It's on the bottom left of the image, the lighter part. That is a vertical outcrop that ascends three miles. It sounds like a lovely place for basejumping, except that without an atmosphere, a parachute would be worthless.

Scarps are usually caused by some form of cooling. When most materials cool, they shrink. Because the inside of the body shrinks but the outside is already solid, the surface cracks and forms ridges.

This brings back a familiar question--where did the heat come from and why did it go away? It's suspected that Miranda used to be in an orbital resonance with another one of Uranus' moons--that is, they both interacted with each other gravitationally. This forced Miranda to have a more eccentric orbit than it presently does, inducing tidal heating.

Since then, Miranda lost its resonance. Its orbit became less eccentric, and without a source of heat, it cooled down, forming its present strange shape.

Other theories suggest that an earlier incarnation of Miranda was destroyed and reformed with its current shape. The truth may be some combination of both theories; such an impact may have heated Miranda as well.

As for knowing more, it will be quite some time. There are no plans in place to further explore Uranus. Although politicians and scientists may have a private desire to do so, there are places that are easier to reach and are arguably equally or more interesting. As a result, the Uranian system will remain unpenetrated for sometime more.

Friday, October 08, 2010

Remembering Prime Numbers Fast; Dividing with Less Guessing

Way back in high school, I thought I was a genius. In my naivety, I thought I could solve the great prime number problem--that is, to find a pattern in prime numbers that predicts them without having to check via factoring.

At the time, I knew very little about proofs or logic or induction. I did, however, know how to write programs in QBasic, so I wrote a factoring program. Then I wrote a program that generated lists of prime numbers, and I let one run for two days, giving me a data set containing all prime numbers through the 2 millions.

I tried different approaches to analysis. I arranged and displayed the numbers in different ways. I never found the pattern. If I had, I'd be a millionaire right now, and that would be pretty cool.

I'm not a millionaire though; I'm studying for the GRE--the general GRE. Now, you may scoff at that, and perhaps you're worthy of that great privilege. I'm not. I scoffed at the SATs, and that bit me in the ass. I doubt I did more than an hour of studying for them. I did fine--it got me into college--but I'm sure I could have nailed them with some more practice.

Lesson learned, here I am. After four years of Physics, I'm drilling basic algebra. Why? When you're doing a Physics problem, you have hours to do algebra. You can space out and happily meander through mathematical meadows. You re-derive all the theorems of algebra that you'd forgotten because you don't want to memorize a few formulae. When you're doing a GRE problem, you have two minutes flat to determine unwavering truth. The mindset's different; it takes a little practice and memorization to adapt.

Every practice test I've taken has turned up at least one problem where prime numbers are involved. The first few are easy to recall: 2, 3, 5, 7, 11, 13, 17, and 19. Those appear so frequently that it's hard to forget them. But what about the others? What about numbers that are far larger--say, 153--but not too big to be on the GRE?

I remembered one of the optimistic results I had during my prime number function hunting days. I'll first write it in the form I remember it in, then explain that:1|13792|393|17The left is the ten's column. The right contains entries from the ones columns that are, in fact, prime when combined with that tens column. So, the rows above say,11, 13, 17, 1923, 2931, 37

If we keep this going through one hundred, it looks something like this,4|1375|396|177|1398|399|7This looks discouraging--there's all those holes in the pattern!

Let's take a look at the exceptions:49 = 7 x 777 = 7 x 1191 = 7 x 13

In fact, what I'd developed was a sieve. It's an incomplete one, but a sieve nevertheless. It seems to eliminate all numbers that have factors of 2, 3, or 5; these three factors make the sieve loop every 30 integers. I haven't proven it rigorously, though I can make a few hand-wavy arguments.

By inspection, it obviously eliminates anything with a factor of two or five. Anything that's a multiple of two is even; its first digit is an even number, and there are none of those caught by the sieve. There's a similar argument for five; any multiple of five's first digit is 0 or 5, and none of those are present.

As far as threes go, in the first row of the sieve, all multiples of three are even or divisible by five--12, 15, 18--leaving all four possible first digits. In the second row, the multiples of three are 21, 24, and 27, so only 3 and 9 remain to be prime. On the third row, multiples of three actually begin with three--33, 36, 39--so 3 and 9 are dropped, leaving 1 and 7.

How is this useful if there are exceptions? There's not that many of them--only three less than 100, only one, 91, that made me double-take. Looking at whether or not a sieve catches a particular number gives you a lot of information and can take a lot of the guess work out of division.

In fact, it comes in really handy when factoring. Factoring by random guesswork is tedious, but this can cut your guess time down dramatically.

Take, for example, 153. The sieve doesn't cut it out, and it's not divisible two or five, so it's obviously divisible three--the only other factor the sieve eliminates. 150/3 = 50, and 3/3 = 1, so its factors are 3 and 51. 51 is not blocked out by the sieve and not a multiple of 2 or 5, so it too is divisible by three. 51 = 30 + 21, so 51/3 = 30/3 + 21/3 = 17. So the factors of 153 are 3, 3, and 17.

Being able to factor speeds up any type of division. It eliminates a lot of the guess work, saving time. Saved time on the GRE effectively means a higher score because it leaves you more time to think.

That, and I really hate doing guess work. When I was in fifth grade, I remember being taught to "guess and check," and I thought it was the biggest waste of time. I still think that, because if I wanted to guess and check, I'd make a computer do it for me. Division, though, remains a guess and check problem, and on a test where I can't use a calculator, I'll take all the help I can get.

Wednesday, October 06, 2010

Browser Diversity: The Internet's Condom

It's about time. The browser doesn't fully comply with W3C standards that say what an internet browser ought to do. I don't think it ever has, and they didn't try that hard to do so because they, at one point, controlled 95% of the market share. Why comply with standards when your browser is the standard?

This ends up being a huge pain in the ass for web designers. Take, for example, this game I've been developing. The part of the interface I've developed so far draws a map using 5x5 icons. Each of the icons is absolutely positioned using CSS. In Firefox and Chrome, the map renders properly:

This is what happens in IE:IE, in one form or another, ignores the style sheets. It's rather insulting, really.

Once the Internet at large had enough, Firefox liberated us. It was the first browser capable of putting a significant punch into IE's market share, and more importantly, it introduced the idea that the browser you use is a choice. People using Windows had stuck with the default browser, but Firefox presented--for the first time--a viable option to switch to. Having changed before, users become slightly bolder to change again; the idea of changing browsers was no longer foreign.

I was a Firefox fan for a long time. Yesterday, I switched to Chrome. Why? I'd tinkered with it briefly and saw it going good places. Google is right about the speed too--it does things faster. I felt a little guilty about leaving my liberator and hero, but I realized it wasn't such a bad thing. As more people move on or move around, it'll make us all safer.

This seems a little counterintuitive--that as people spread out across multiple browsers, it will make everyone safer. After all, having one browser with all of the security flaws worked out sounds safer than many browsers with smaller teams working on the same problems, leaving potentially more flaws out in the open.

No matter how hard a team of developers works, every browser has security flaws. Sure, updates bring the number closer to zero, but they can never quite reach it. There will always be holes. If there's one browser, then that flaw leaves room for more damage--at IE's peak, 95% of users were at risk.

A lot of the exploitation of browsers flaws comes from the fact that it can be profitable. Let's say an unscrupulous developer decides to write a script that forwards a user to a crappy search engine. The script makes it appear that the user clicked an advertising link for that search engine, and the unscrupulous developer gets paid for it.

In browser hegemony, it becomes very profitable for the unscrupulous developers to look for as many flaws as possible in those browsers. The resulting rate of return is very high, so even if those holes are hard to find, the yield makes them worth searching for.

On an Internet with browser diversity--the one we've started transitioning to--exploiting a single security flaw has a much lower rate of return, and doing so for profit is much more difficult. As a result, it's plausible that the business of exploiting browsers for profit could diminish. I don't think it will go away, but the increased difficulty will make it subside. Finding a security flaw in Firefox, at this point, gives you a 30% share of the market; IE, only 49%.

That's a much smaller incentive and, in the long run, makes things safer for everyone.

Monday, October 04, 2010

Moon of the Month: Enceladus

Saturn has a lot of moons. About two-hundred have been observed, and it's suspected there are more. Most of these are tiny and orbit on very irregular orbits; astronomers only consider twenty-four of them regular satellites. Those we know much about are fascinating--each in a different way. Very little was known about any of them until the Voyager probes looked at them close-up in the early 1980's.

Before then, Saturn's moons were just dots. William Herschel--the same guy who discovered Uranus--first spotted Enceladus in 1789. Enceladus was the second moon in Saturnian system discovered despite only being the sixth-largest. Part of this was because William Herschel was a badass--he was, after all, the first guy to discover a planet that wasn't visible to the naked eye. On the other hand, Herschel had a little help from Enceladus and its albedo.

No, that has nothing to do with libido--unless you have an albino fetish. Albedo--particularly, Bond albedo--is the measure of "whiteness" of something, coming from the Latin "alba," meaning "white." Effectively, Bond albedo measures how much light a body reflects back into space divided by the amount it receives. Earth has an albedo of 0.29--that is, it reflects 29% of the light it receives back into outer space. Dark colored oceans, asphalt, and other things absorb the remaining 71%, which lingers as heat.

Most solar system objects are about where earth is, plus or minus 5%. Mars reflects about 25%; Saturn about 34%. Venus--with its notoriously thick sky that lights up evening and morning skies on Earth when its visible--reflects 75%.

Enceladus reflects 99%--nearly all light that hits it bounces off. The surface is pure white, covered completely in relatively new surface ice, laid down by active ice volcanoes--that's right, volcanoes that spray ice into space. Scientists were stunned when these were discovered, just as they were when Io's volcanoes were discovered. When Mars was found geologically dead, it was suspected most of the outer solar system was as well. Io came as a surprise; Enceladus, even more so. Io was much easier to explain; it's close to Jupiter and experiences tidal heating. Enceladus, on the other hand, was more difficult.What fuels the volcanoes? Something has to keep the ice under Enceladus' surface a liquid. So, to look at the question differently, what is heating Enceladus? Enceladus reflects nearly all of the light that hits it back out into space, so clearly, the sun is not warming Enceladus. Tidal heating is suspected, but Enceladus' neighbors that are closer to Saturn are more geologically dead than Enceladus, so that's not the whole answer.

To make up the difference, It's suspected that the other portion of Enceladus' heat comes from one of the same sources as Earth--radioactive decay. Like on Earth, radioactive elements deep inside Enceladus break down slowly over time. These breakdowns release energy that warms Enceladus, eventually warming the thick layer of ice on surface, melting it, increasing its pressure, and forcing it to erupt. These "cryo-volcanoes" result.

The effects of Enceladus' volcanoes aren't just local. It's suspected--in conjunction with meteorite impacts--that they replenish Saturn's large, diffuse E-ring. Calculations have shown that particles in the E-ring ought to dissipate after millions of years--assuredly a long time, but short on the scale of the solar system. If they'd been around at the beginning of the solar system and not been replenished, they would have assuredly disappeared. Enceladus' eruptions--perpetually pumping particles into space--explain the continued existence of the ring.

Wednesday, September 22, 2010

Separating Spiritual and Supernatural

A long time ago, someone created religion. I doubt that they sat down with their friends and said, "alright guys, we're starting a religion." That would require them to know what religion was--there would have to have been one for them to have a name for it. Instead, I'm sure their newfangled hominid brains meandered a bit--pondering questions about life with this newfangled language thing--finally concluding with, "I bet all these questions I can't stop asking have a common answer."

Among these questions were things like:"How did we get to be this way?" "What's it mean to be?""What happens when people die, and why am I sad when they do?""What will happen to the world?" "Why is there weather, day, and night?" "What is right?"To explain these, they personified and discussed through metaphor. These metaphors were incorporated into supernatural beings, and those were--in most cases, after thousands of years--incorporated into one being.

In due time, though, when people looked really close, the questions weren't answered completely. "Ok, so the all-gerunding being makes the planets go around the earth, but why do they go backwards?" People started looking deeper at questions, abandoning the simple explanations found in religious and classical texts, and reaching for deeper ones.

This process resulted--along with high standards in rigor and definition--in what we now call science. This is also the origin between the conflict between science and religion. Religion presents protoscience--hypotheses to explain the world without the scientific method--incorporated into its texts. Science demonstrates that protoscience is false, but because one is an organ of religion, the two butt heads.

One way to abate the conflict temporarily was "to leave room for the creator." Newton did this--the mathematics backing his theory of gravity couldn't explain why the planets didn't throw each other out of orbit over long periods of time. Newton answered this question with the Hand of God.

Neil Degrasse Tyson discusses this "Hand of God" gap-filler in his essay The Perimeter of Ignorance, and he concludes that the belief in the supernatural acts as a crutch, stunting continued exploration in science. Sometime after Newton, Laplace discovered the mathematics to replace Newton's Hand of God. According to Tyson,Laplace gave a copy of Mécanique Céleste to his physics-literate friend Napoleon Bonaparte, Napoleon asked him what role God played in the construction and regulation of the heavens. "Sire," Laplace replied, "I have no need of that hypothesis."

It's an elegant statement, and I wonder if it's one that can be applied not only in science, but to the realm of the spiritual--the essence of being. From the birth of religion, humanity used religion to satisfy its spiritual needs--ones that, even in an atheistic context, do not recede. There's no reason to bind the spiritual to the supernatural. They remain inseparable because the entire discussion of spirituality for the whole of history has taken place in a supernatural context, but there's no reason this has to continue.

What makes this difficult--and why I haven't heard of anyone who's done it yet--is that I don't know where to restart the discussion. I don't think anyone does. Just as gods were necessary for humans to discuss the cosmos, people utilized gods to discuss the core of our being and purpose. We're surrounded by a metaphor gone mad.

There's no reason but tradition for which this has to continue. It's true that science can't answer all questions, but it's false to say that questions outside of science require supernatural explanations. Using them may be simple or satisfying--providing an answer to many of these questions--but that doesn't mean that they're right. They are merely pleasing--like a cigarette to the smoker. They provide temporary relief, but the addiction continues. A long struggle--quitting--offers the most viable long-term solution. In the short-term, it is difficult, but in the long-term, it will bear greater fruit than any ever-lasting life the smoker is pleased to contemplate.

This "short-term" may be a thousand years. The spiritual struggle remains unanswered from ancient times, and I'm sure a solution won't come quickly. The path beckons us, though; imaginary satisfaction dulls our hearts to the call, but on occasion, the question asks itself loud enough to feel again. When they hear it, people pander from the horror of ignorance to the supernatural explanations into which they were raised--the easy road.