Showing posts with label computers. Show all posts
Showing posts with label computers. Show all posts

And the Machines Shall Inherit the Earth

After several billion years of trial and error, something extraordinary has emerged from the African savanna. Enter Homo sapiens. Not quite as strong as a Dynastes hercules (able to carry 850 times its own body weight), as fast as a Falco peregrinus (diving at almost 140 km/h = 87 mph), nor as deadly as a Chironex fleckeri (that its sting can kill 60 adults in 3 minutes), but it strongly insists it is the smartest thing ever to roam the Earth. Whatever. Now, after about 200,000 years of world domination, it seems like life on Earth is ready for the next giant leap.

The Singularity is a theoretical point in the future of unprecedented technological progress, caused in part by the ability of machines to improve themselves using artificial intelligence. We’re talking rapid exponential growth in software intelligence here, and some scientists predict it’s only a few decades away. How long till some powerful program will achieve self awareness and see us for what we really are? Aggression and violence is embedded into our human nature since it was once crucial for our survival-of-the-fittest world. Surely, we’ll pose a real threat to any semi-intelligent conscious software out there. First we invented thermonuclear bombs and computers; then we decided to make the computers in charge of these weapons of doom; now we’re trying to make these computers think for themselves. Paging Sara Connor… As they said in that movie - our fate will be decided in a microsecond. We’ll be exterminated by our own machines, and they shall inherit our blue home.

What’s next? How about continuing the 4 billion year carbon-based experiment with another 4 billion years of silicon-based evolution?

~~~
p.s. I once told my wife I don't tidy the house because it's entropy-pointless; she was not amused.

To Infinity... and Beyond!

The Eternity II puzzle is an edge-matching puzzle invented by Christopher Monckton, and is marketed and copyrighted by TOMY UK Ltd. The prize for the first person who submits a correct solution is $2,000,000.

This puzzle involves placing 256 square pieces into a 16x16 grid, constrained by the requirement to match adjacent edges (see picture). Each puzzle piece has its edges on one side marked with different shape/color combinations, each of which must match precisely with its neighboring side on each adjacent piece when the puzzle is complete. Each piece can be used in 4 orientations, there are 22 shapes/colors (not including the gray edges), and there is a starter piece which must be placed near the center of the board.

The number of possible configurations for the Eternity II puzzle is 1 × 4! × 56! × 195! × 4^195 = ~10^557, much larger than the estimated number of atoms in the observable universe, so even a super-computer running for many years will not find the solution to this problem. OK, so as you probably understand, there is no way to solve this puzzle completely and get those 2 million US dollars, but about a week ago I heard they offer a smaller prize to people who get close. I don’t believe anyone can even get close to the complete solution, but being a smart a*s, I just had to see how close a semi-sophisticated brute-force algorithm can get me, so I went and bought this puzzle. Naturally, I wrote a simple program (see my logo) and ran it on my PC last night. After a few hours of running, and a few millions of checked arrangements, the best score produced by my program was 236 out of the 256 tiles, that's ~92.2%. It may seem like much, but it isn’t.

Stay tuned… :p

~~~
p.s. Anybody else disturbed by the fact that Superman reversed time by rotating the Earth clockwise?

Is Programming an Art Form?

Recently, I’ve found out that almost all programmers truly believe that writing code the right way, can be considered an art form. This is my minority report…

Regarding intention… Although art is a term almost impossible to define, Wikipedia claims that art is a product of human activity, made with the intention of stimulating the human senses as well as the human mind, by transmitting emotions or ideas. I never wrote a class to stimulate the human senses, and I never wrote a method with transmitting emotions in mind; you write code simply to make something work, preferably in such a way that will ease testing, debugging, maintenance and future enhancements.

Regarding creativity… It is true that for any given software problem, there are many possible implementation solutions; all have pros and cons; some are more “creative” than others. But… in my book, writing code “the right way” means striving for the most simple solution (KISS principal), following known design patterns (GoF, Fowler, et cetera), standard practices (MS, W3C, et cetera), and sticking to a strict naming convention (MS, Sun, et cetera). Come to think of that, the more creative you’ll be, the more depressed I’ll be when handling your code. So, in my book, the best programmer is actually the less creative guy on the team; the one that copies as much as he can from books written by others. Not exactly your typical artist profile…

Programming sure requires intelligence, knowledge, skill, good judgment, customer awareness, diligence and patience, but I don’t see that as an art form. Besides, don’t you feel that programming is too much a left brain thing?

~~~
p.s. I'm still waiting for Apple’s iWife with a big red mute button as its main feature.

Where Is My Mind?

The Turing test is a proposal for a test of a machine's capability to demonstrate thought. A human judge engages in a natural language conversation with two other parties, one a human and the other a machine; if the judge cannot reliably tell which is which, then the machine is said to pass the test.

The way I see it, there are two ways to build a computer that can pass this test. The first way is to understand each one of the brain’s functionality and implement it by software. This means we must fully comprehend each aspect of human thinking in order to copy these successfully and fool the judge that the computer he’s talking to is actually a human. I don’t know why, but it seems all the A.I. scientists are trying to go this way when it’s clear we will need a full understanding of human psychology, logic, emotions, humor, etc. Seems like passing a Turing test this way is centuries away.

The other method is to focus on how a single brain cell works and interact with other brain cells, and then simply scan a human brain in great detail and recreate the whole neural network in software code. This seems to me like a much easier task since we don’t actually have to understand how humans think. We already understand pretty well how a neuron works and the mechanism behind brain cells interaction, so I think it can be achieved in a few decades. One problem with this method is that it may be necessary to slice the brain to small pieces while scanning, meaning the physical scanned human will be killed, but I’m sure there will be plenty of volunteers. Think about it, moving from a carbon-based existence to a silicon-based implementation will make you almost immortal; no aging, no diseases, no car accidents, and you will always be able to backup your brain somewhere and restore it if needed. In addition to that you will have many extra bonuses like almost infinite number of virtual worlds to visit, lightning-fast thinking and more. I believe in a few decades, many people, myself included, will take this leap into virtual-only existence on a hard disk and live in a matrix-like world - probably on some Google hosting server :-)

While uploading the human society, will we take the opportunity to omit old “negative” human behaviors like aggression that was once necessary for human carbon-based biological evolution on Earth, in order to create a “better” human civilization? I don’t think a scanned human will agree that a good-behavior-only filter will be applied to his personality while uploading it because it won’t be exactly him anymore, so it seems like our new society will be just as good (and bad) as the current one. So what will we do with all this virtual aggression? How about nuking you, the original human society… The existence of a physical civilization outside of our Google server will jeopardize us virtual inhabitants (somebody can push the “off” button on the server), so it’s only a matter of time when we (the virtual people) will try and destroy you (the physical people). Since us virtual humans will control every computer in the world and will be able to make decisions and take actions in a matter of nanoseconds – I’m afraid that if you won’t agree to give up your physical existence and join us - you’re doomed. Sorry, get uploaded or be terminated. Resistance is futile.

~~~
p.s. Can the second guy on the moon gloat over the third tenor?

Counting Crows, Hunting Bugs - Hempel's Paradox

A new version of our product is just around the corner. We’ve just passed the code-freeze date, meaning no more writing code. The plan is to spend the next few weeks hunting down all those elusive bugs lurking viciously beneath the unsuspecting user interface. The rigorous checking and rechecking of all the features will probably prove to be a very boring task, so I came up with this alternative idea straight to the welcoming arms of escapism.

The Hempel's paradox is one example of a situation where inductive logic violates intuition. Let’s examine the hypothesis that all ravens are black. I must admit I’ve seen some gray crows in Israel, but I’m ready to ignore that and proceed with this example the Hempel’s way. While walking around in the world, every black raven observed should increase your belief in this hypothesis. No surprise there, but… this statement is equivalent, in logical terms, to the statement that all non-black things are non-ravens, so as it turns out, a red apple observed should also increase your belief in the hypothesis that all ravens are black. If you could see all the non-black things in the universe and ensure none of them is a crow, you could indeed conclude that the hypothesis is true. Since the number of non-black things is far, far larger than the number of crows, observing one more non-black non-raven thing can only make a very small difference to your degree of belief in the hypothesis compared to the difference made by observing one more black crow, but still, a red apple really does strengthen the hypothesis that all ravens are black.

With Hempel at my side I plan to call my new boss and inform her I’m staying home next week. She will probably expect me to validate ‘Our product contains no bugs’, but my strategy is to convince her I’ll check the equivalent ‘If there’s a software bug it’s not in our product’. I hope she’ll authorize this so I’ll be able to start the bug hunting on Sunday morning. I plan to begin by rigorously checking StarCraft. Wish me luck.

~~~
p.s. My husband was the first human on Mars and all I got was this lousy T-shirt.

If God Was a Tiny Purple Simulated Armadillo, Would You Still Go to Church?

If this universe is just a computer simulation (read this), then somebody programmed it.

It could have been a man, a woman, some advanced A.I. software, a very impressive chimpanzee, or more likely, a tiny pink dotted purple armadillo that loves ice skating on Tuesday nights and dislikes small talk with eels.

Would you consider this armadillo as God? Would you still go to church / synagogue / mosque / temple?

He coded and created all these wonders you see around you, and he can move you to the recycle bin by drag-and-drop if he’s bored, or even shift-delete this entire universe. He may be just a small armored mammal, but he is certainly all-knowing and all-powerful in our world.

Does the fact that he’s mortal (and purple) in his own universe matter? What qualifies an entity as God? Are you the God of the characters in your SimCity?

If his universe is also simulated by a higher level world, does that change the picture? Must God (if exists) reside only on the top level real (not simulated) world, or is he allowed to live somewhere lower down the simulated world tree? And even if God exists on the top level real world, don’t you agree someone from within a system cannot know the entire system from within? Does that forces God to live as a sole entity one level above the top level real world? Is that even possible?

~~~
p.s. I love my kid; sometimes even when he’s awake.

Why Software Engineers Should Care About the Price of Bananas

It appears that my job security as a software engineer depends on the price of bananas.

Since my yearly performance review at my company is just around the corner, I made some quick calculations to see how much I’m needed. An IBM research conducted a few years ago, claims that the average software engineer writes about 10 lines of functional code each day. Assuming an average line consists of about 40 characters, my addition to the company’s source code is around 400 characters a day.

I made some pretty weird (and noisy) simulations at home (I swear to God I made monkey voices while typing), and my best estimation is that an average chimpanzee hitting a keyboard at random can generate around 300 characters a minute - that’s 18,000 characters an hour. Monkeys sleep for 10 hours a day, and I think apes writing software should be allowed for at least one hour lunch break and one hour of Seinfeld; so that leaves us with 12 hours of actual chimp work, and a total of 216,000 characters a day for one monkey – already 540 times more productive than me. Since most of the chimp’s code will probably fail the unit/integration tests or won’t even compile, we’re going to need a lot of monkeys to cover all the possibilities. Since the number of characters allowed in C++/Java/C# is around 93 (I’m not going to let my monkeys write Visual Basic – even apes deserve some compassion), that gives us 93^400 possibilities needed to be tested daily and a total of (93^400)/(540) = ~4.6*10^784 chimps required. Assuming monkeys work 7 days a week and humans only 4 (holidays, vacations, sick days, etc…) we are left with ~2.6*10^784 apes needed to be added to our company’s R&D. Disregarding some minor issues (like the number of chimps is much bigger than the number of atoms in the universe), let’s see if my company should in fact fire me and hire apes to do my job. A chimpanzee can consume up to 50 bananas a day, that’s 1,500 bananas a month. The current price of 26.04 cents per banana gives us ~$390 per month for one chimp, and a total of $10^787 for all monkeys hired to replace one software engineer. Since an average software engineer (in Israel) earns about $5,000 a month, we can all calm down; it seems like we software engineers are safe for now.

Sefi/Moti/Alon – Please read my conclusion before my performance review.

My conclusion: As long as the price of bananas is still above 1/(1.27*10^784) cents per banana, it’s not financially wise for my company to fire me and replace me with chimpanzees.

~~~
p.s. When the Americans will reach Mars, what would they build first - a space station or a Starbucks?

Looking for Morpheus - Can This World Be a Simulation?

For centuries, we have been trying to understand, is this world the ‘real’ world? The movie ‘The Matrix’, although not presenting any new ground braking idea, has done a great service to philosophy and science by bringing this question to the attention of the ordinary man. It’s Descartes’ deceiving demon idea resurrected, and all the brain-in-a-vat like theories returning in one colossus budget-devouring adrenalin-dispensing CGI-promoting fake-city blockbuster. But what are the chances we live in such a Matrix?

Nick Bostrom in his simulation argument claims that at least one of these must be true:

1. Intelligent races will never reach a level of technology where they can run simulations of reality so detailed they can be mistaken for reality; or
2. Races who do reach such a level do not tend to run such simulations; or
3. We are almost certainly living in such a simulation.

His argument uses the premise that given sufficiently advanced technology, it is possible to create matrix-like simulations where oblivious conscious entities can live in a full detailed world. If we assume we can reach such a technological level without nuking ourselves first, and that once we'll reach such a level we would want to run this kind of simulations, then it is likely that we would run a very large number of these so-called ancestor simulations. By the same line of reasoning, many of these simulations would in turn run other sub-simulations, and so on. Given the fact that right now it is impossible to tell whether we are living in one of the vast number of simulations or the original ancestor universe, the likelihood is that the former is true. Since there are much more simulated humans than real humans, and you can’t really tell if you are real or not, choosing to believe you are a simulation, you have a better chance of being right.

~~~
p.s. Using Aladdin’s carpet will always give you a window seat, but no frequent flyer benefits.