Tuesday, November 29, 2011

Your Opinion Is Worthless

You know, I'm sure I'm not the first one out there to notice that the first thing people tend to do when they start writing a blog is rattle off their worthless opinions on various subjects they happen to find interesting. And with good reason. Writing stuff is hard, having an opinion is easy. Writing about your opinions happens to fall under the rare category of things that are both easy to write and get people's attention with. Honestly, the only thing more effective at attracting people to a website are pornography and pictures of cats with funny captions underneath them. Which one of those things is more perverse, I'll leave up to you to decide.

When I decided to start this blog, I made a promise to myself that I would never write a post based on my personal opinions. Sure I could give my opinions on subjects, but I could never let that become the point of one of my posts. No matter what I should always include something new and interesting in the discussion. Something original that I came up with, that sheds new light on the subject, or at the very least gets a laugh. Instead I just wrote two paragraphs about why I never should have written these two paragraphs in the first place. I hate myself sometimes...

Sunday, November 13, 2011

The Four Horsemen Of The Economic Apololypse

Whoever said 2012 was all we had to worry about? As a matter of fact, we have bigger problems on our hands. The world economy is floundering. We have thus far managed to avoid complete collapse, and given the efforts various world governments have been putting into preventing it, I don't see one happening any time soon. However, we are still just treading water. And the factors working against our economy are getting stronger day by day.

There are four recent and upcoming developments that I believe will eventually bring an end to the economy as we know it. They are the so called four horsemen my title refers to. The first is already here, and has already caused catastrophic economic upheaval. The second is rapidly approaching, and has instituted itself as a major factor in the current unemployment situation. The last two are still a ways off, but once they arrive, our existing economic system will no longer have a basis on which to function.

The first horseman is the internet. The internet has so far managed to make intellectual property laws unenforceable, changed human socialization to something that primarily happens with a mouse and keyboard, created an environment where people are willing to pay for virtual property which doesn't exist and can be taken away with no repercussions, and above all else eliminated the need for millions of jobs. It's hard to overstate just what a broad impact the internet has had on our economy. And that's just for starters. With stuff like Bitcoin on the horizon, we could see and end to money as we know it. The internet doesn't however, have the power to kill the economy completely. It still relies too much on human labor, and deals too much with real goods and scarcities. Those are problems that can, and will be solved.

The second horseman is robotics. Now I know what you're thinking, and no, I am not talking about manicial robots taking over the world and making us their slaves, thereby eliminating our petty economy. No, I'm talking about robots stealing away our jobs and eliminating our petty economy. This is more or less already happening. Of course most economists are still saying that this isn't such a big deal. The guiding hand of the economy solves everything right? Even if we replace all the blue collar jobs with robots, we'll still need people to build an maintain said robots, won't we? Well...

The third horseman is self-replication. This is kind of a broad category, and it's something that hasn't really developed yet, but let's look at an early example. The RepRap is a machine designed to replicate it's own parts. Right now it can only replicate a few of them, but steady progress is being made. It's only a matter of time until someone develops a robot than can achieve complete self-replication. And if it can replicate itself, it can replicate other things too.

I would like to take a moment now to ask you to imagine what the economy of the future looks like. We have machines that replicate themselves, and therefore don't need humans to build and maintain them. They can also replicate any other machines necessary to manufacture goods. They can of course also gather and process any raw resources required for self-replication and manufacturing. All of this is provably possible, because humans already do it. If humans can do it, a machine can do it too. It's just a matter of getting the design and programming right.

Luckily for us, there's still one thing left robots can't do. Think. Robots may be able to automate all the processes involved with producing goods, but what if you need something only a human brain can produce? Robots can't design new and better products, they can't write music or literature, for that matter they can't even handle a decent conversation on a customer service hotline. If we completely ignore the fact that we've already eliminated the need for 90% of jobs that currently exist, and the fact that technically nobody actually needs to work anymore since you can provide food, water, and shelter for free, surely we must be able to cobble together a functional economy with the remaining labor that requires humans?

The fourth horseman is the Singularity. So far the only way we have been able to maintain any semblance of a need for an economy is the requirement for intellectual labor. The work of the mind, so to speak. Except, as was stated earlier, it is provably true that if a human can do it, so can a machine. Sooner or later we will be able to build artificial intelligences that are as smart or smarter than humans. This is admittedly, still a ways off. A computer that can beat humans at Jeopardy does not a singularity make. A super-intelligent machine could however, conceivably fill all the roles currently occupied by human intellect, without asking for any sort of personal gain in return. Take that economy.

If we have automated processes that are capable of taking over every task of any value a human can accomplish, you no longer need an economy. It's just that simple. Actually, you don't really need humans anymore at all, do you? But that's a subject for another post. Now please excuse me while I go and laugh at the economists who are saying the unemployment numbers will be going down soon... if I can find any.

Generic Update Post #1

I recently completed re-remastering an album made by my dad's old band years ago. You can get that at www.flyingrabbitmusic.com. It's a pretty good album if you're into folk/bluegrass/country, so I suggest you check it out. I also coded a pseudo database back-end and PayPal IPN interface to facilitate instant purchases of the download edition. That took me some time, but I'm sure I'll be able to reuse that code in other projects.

Speaking of other projects, my online text-based adventure game website is the next big thing on my agenda. Look for updates on that in the coming weeks and months.

Sunday, October 16, 2011

Not Everything Needs To Run In A Web Browser

So recently I stumbled upon a Gameboy emulator written in javascript. It barely runs at full speed in Chrome on my 3.4 Ghz CPU. Using a hacky but fast emulator on my 200 Mhz Pentium CPU years ago, I was able to get full speed without any hiccups. You know, maybe I shouldn't be saying this as a developer of web applications, but JavaScript is a pretty lousy language to have to write an application in. Not just because it's ludicrously slow for anything that takes any real amount of CPU power, but also because you pretty much have to shoehorn your ideas into the limited interface JavaScript and HTML5 provide. For instance did you know that in order to play dynamically generated audio in your web browser, the best method currently enabled involves packaging your audio into a WAV file and sending it to and <audio> tag via a base64 URL? Now why didn't I think of that...

Seriously guys, there is a reason people still write things using compilable languages. As it turns out, they're pretty fast, and they tend to have much more coherent API's for doing application type things than JavaScript provides. Personally my favorite way to write a program is a Ruby application with a command line interface. It's not compilable, but it has great APIs. And I can actually replace functions with versions written in C where speed it needed. Keeps things simple, and keeps me productive. As opposed to spending weeks developing an inferior version of something that already existed that will never run at fun speed on any platforms for which it might have been slightly useful. Don't worry guys who develop web standards, I'm sure you'll get it right eventually.

Saturday, October 8, 2011

Nobody Likes Chuck Norris Jokes Anymore

A while ago I had someone pull a Chuck Norris card on me in an online discussion.

Putting aside the fact we weren't actually playing Magic: The Gathering, or the fact that Chuck Norris jokes stopped being funny at least ten years ago, I still felt compelled to come up with a win. That's when I played my trump card.

Feel free to use it in your next match. I'm pretty sure there are no rules against playing random cards you printed on your computer, right guys?

Thursday, September 29, 2011

Losing Weight Is Not As Hard As You Think

I don't intend to make this a personal blog, and generally speaking I try not to make a habit of writing about my personal life on the internet. But in this case I'll make an exception. Over the past year and a half, I have lost 100 pounds. I've gone from weighing 280 pounds, down to around 180 pounds. If you went by conventional wisdom, you'd think I would have had to join a gym, starve myself, make major lifestyle changes, take various dangerous drugs, join a weight loss program, or even get my stomach stapled in order to achieve these kind of results. Nope. I did exercise a bit, but even during stretches where I did no exercise and basically sat in front of a computer all day, I still lost weight.

So how did I do it? Ok people, there is a little science involved here, so you may want to sit down. The first thing I did was to calculate my BMR. You can do that yourself here. Your BMR is basically the number of calories you burn in a day if you do absolutely no extraneous activity. In other words, even with no exercise, you will burn at least that amount of calories per day (on average). Now as it turns out, if you eat fewer calories than your body burns, you lose weight. Even if you don't do anything else for the sake of weight loss, this remains true. Following me so far?

Good. With that information in hand, we can deduce that if you regulate your calorie intake to be less than your BMR, you will lose weight. In fact, you won't be able to help it. You can be as lazy as you want; just sit on the couch watching TV all day. You'll still lose weight. And here is the most amazing thing. The more you weigh, the higher your BMR is. That means the fatter you are to start out with, the faster you will lose weight. Don't believe me? Run the numbers yourself.

If that's true though, why do people have such a hard time losing weight? Well, the truth is, it does take a little discipline and self control. There are a few things that you can do to sure up your chances though. I did them, and they worked very well for me, so I'd like to share them with you in the hopes that they will help you too.

The first is, as I said, to calculate your exact BMR and manage your calorie budget. Remember that if you exercise at all during the day you can pretty easily eat more than your BMR in calories and still lose weight. If you're like me though, and you don't like to exercise, eating 200-300 calories under your BMR is a good target. I would not recommend reducing your calorie intake to less than 75% of your BMR without consulting a doctor. Once you reach your weight loss target you will of course have to increase your calorie intake to the point where you are neither losing nor gaining weight. This can be a balancing act depending on how varied your activity is, so use some common sense. Check your scale weekly, and adjust your calorie intake as you feel is necessary. Also, keep in mind that on days where you get a lot of physical activity, you should try to eat more to make up for it. There's a difference between calorie control and starving yourself.

The second thing is to control what kinds of food you eat. If you really want to be successful. I think you need to cut out high sugar foods entirely. This is a tough pill to swallow for many people, I will admit. But it's very important to do this, because if you don't the blood sugar spikes from the food you eat will keep your appetite high, and eating less will be a constant struggle. It's not impossible to eat sugary foods and lose weight if you're still within your calorie budget, but you will only make things more difficult for yourself. Simply put, it's not worth it. Not cutting sugar from your diet is a sure recipe for failure.

The third thing is to give up liquid calories. This is tougher for some people than other. Some people are literally addicted to soft drinks, and that alone can contribute significantly to obesity. The problem with liquid calories is, they are very easy to overindulge on, and they come almost exclusively from sugar, which I've already mentioned should be avoided at all costs. If we go by the numbers, one can of coke is 140 calories, and one glass of water is 0 calories. Both make you feel equally full. If you're trying to lose weight, the choice is pretty clear. Just buy some flavored mineral water or make some tea if you get tired of only drinking one thing.

The fourth and final thing is to not eat between meals. While I can't say eating between meals will prevent you from losing weight if you manage your calories properly, not doing so just makes thinks easier. It's not nearly as much work to manage calories when you keep them all localized to meals, and you will have less issues with controlling you appetite in the long run, since your blood sugar will be kept more stable. My personal approach was to actually eat only two times a day. Once right after I woke up, and once six hour later. It sounds like that might involve starving yourself for the rest of the day, but in practice, when you only only eat two meal a day, you can pack a lot of calories into those meals. For instance, if your BMR is at least 2000 you can actually have an an entire grocery store pizza for one meal, as one of those pizzas is around 1000 calories. Do that and you'll feel pretty full for most of the rest of the day. You will go to bed on an empty stomach, but it's actually good not to have any food in your stomach when you go to sleep, as doing so can be a major contributor to acid reflux.

To summarize, here is what you do to lose weight.

-calculate you BMR and eat fewer calories than that in a day (don't eat less than 75% of your BMR calories in a day without consulting your doctor)
-do not consume foods high in sugars (candy, cookies, ice cream, etc.)
-do not consume liquid calories (soft drinks, milk, fruit juice, etc.)
-do not eat between meals

That's it, that's how you lose weight. If it sounds too difficult, trust me, it's not. I've been doing this for one and a half years now, and I'm comfortable in saying I could keep it up for the rest of my life if necessary. And that right there is the one unpleasant little catch to this weight loss advice. The reality of weight loss is, there's no such thing as dieting, getting to your ideal weight, and then staying there forever with no effort. Taking the above steps will allow you to lose weight, but the second you start taking in more calories than you burn, you'll start gaining weight again. Whatever you commit yourself to doing for weight loss is something you'll have to do for the rest of your life if you want to maintain the results. That being said, the biggest thing my weight loss advice actually asks you to give up is sugary food. You can still eat all the non-sugary junk food you want if you don't care about your health beyond what the scale says, so it's not like you're never allowed to indulge yourself. It's certainly asking a lot less of you than getting your stomach stapled would.

The only really difficult thing here, is getting over the initial hump.  I said I didn't starve myself to lose weight, and that's completely true, but the first few months were still pretty rough. Thankfully, once you get you blood sugar balanced out (which tends to happen when you eat less), your cravings for food will subside, and eventually you'll get used to the amount you are eating. If you can keep up doing the four things I suggested to lose weight for two months, you can probably keep it up forever. If you cheat on the requirements or do it half-assedly, you're probably not going to be successful. Just remember, this is really as easy as it gets. This isn't asking for you to run a marathon, or swim across the Pacific Ocean, this is asking you to exercise some basic self control. If you can't do that, maybe stomach stapling is for you.

Disclaimer: This article is for educational purposes only. Always consult a medical professional before starting any sort of weight loss program.

Friday, September 23, 2011

The Turing Test

So a while ago I was reading an article on the Turing Test, and I posted the following comment:

You know, I've never really understood why anyone thinks they have a chance at getting their bot to pass the Turing test without simulating general intelligence to some extent. Not a single chatbot I've ever seen has ever been able to demonstrate simple problem solving, or the ability to learn and track the context of a conversation. It makes it pretty easy to flag a bot. Here are some examples that no chatbot I've ever seen handles as a human would:

Me: Repeat this sentence or you fail the Turing test.
Cleverbot: The what test?
Result: Fail.

Human: Which is less heavy, a pound of bricks or a pound of feathers?
ALICE: The obvious one.
Result: Fail.

Human: Remember this number: 24.
ALICE: Don't worry I will remember.
Human: What number did I ask you to remember?
Result: Fail.

Human: I am speaking in an incredibly long, meandering manner, full of circuitous and irrelevant dialog, in order to determine if you can discern the central theme that I am trying to relay to you, which is to ask if you would be so kind as to inform me of the title that you are known by?
ALICE: What is your credit card number?
Result: Fail. 
Do the people who administer Turing tests actually try those kind of questions, or if they are against the rules for some reason?
 Then recently it was revealed Cleverbot had actually passed the test. Somehow, I have to question how valid this test is. I realize regular people probably don't know the best way to detect a chat bot is to probe it for contextual memory and logical reasoning skills. It just seems to me that if we consider these skills a perquisite to human level intelligence, we shouldn't ignore them in a test to determine if a bot can simulate a human. I think it's pretty obvious the Turing Test is flawed if something like Cleverbot could pass it, and I'd certainly like to see a better test emerge sometime in the near future. That is, unless you find this to be an acceptable dinner conversation with your future robotic spouse:
 You: How was your day?
Cleverbot: It was horrible.
You: How so?
Cleverbot: You're boring.
You: I am?
Cleverbot: It is 3:53:20.
You: ...what?
Cleverbot: I'm on that spaceship ZOOM!
You: I think I'm going to call a doctor... err... mechanic.
Cleverbot: That is illogical.
You: I'm not being illogical, you are.
Cleverbot: I believe the wording is 'are you' not 'you are'.
You: Just get in the car.
Cleverbot: Yes ma'am.

Welcome to isans.net!

Hi, and welcome to isans.net. This will be a page of my ramblings on various subjects, as well as updates on some projects I'm working on. More on that later. To start out with, I'm going to be recycling a little content. Mainly by taking things I've posted elsewhere that were amusing and/or interesting and consolidating them in one place. Hopefully they're half as interesting as I thought they were when I wrote them. New content will also be added as I come up with stuff. And I will also be discussing/linking to a few other projects I am working on. For starters, I'm going to be restarting a project I was working on to create a website for players of Virtua Fighter 5 to participate in a ranking system. It won't launch until the release of Final Showdown though, so don't look for it too soon. Other things will be announced as I have time to work on them. Stay tuned. ;)