Friday, 28 August 2015

Book Review - The Martian by Andy Weir

Fantasy books were my gateway drug into the world of reading. Starting with Harry Potter, The Inheritance Cycle and the Lord of the Rings, fantasy was a staple of the steady diet of books. Then I discovered Famous Five, Secret Seven and other children's adventure novels. I started reading science fiction quite late into my life. Although I read a few books here and there I didn't really get deep into the genre until I read Douglas Adams' "The Hitchhiker's Guide to the Galaxy". Nowadays I tend to prefer science fiction over other genres. So when I found out the the upcoming movie "The Martian" was based on a novel by the same name, I immediately hunted down the book so I could read it before the movie came out. Turns out the book was pretty short and I finished it by reading on and off during my free time over the past couple of days. So here are my thoughts on the book.

Mark Watney is an astronaut on the third manned mission to Mars. Due to an unfortunate and unexpectedly strong dust storm five days into the mission, NASA had to abort. When the crew was making an emergency evacuation from the artificial habitat, the dust storm blows a piece of debris into Mark Watney, impaling him with a piece of metal and taking out the electronics that monitored his vital signs. With no vital signs from Mark's suit and the storm threatening to tip over the vehicle that they needed to lift off from the martian surface, the crew had no choice but to leave his (supposedly) dead body behind. Mark wakes up on Mars after the storm with a slightly leaky suit and the stark realization that he is now stranded on an alien planet. He needs to use his knowledge and resourcefulness to survive on a dusty red wasteland till someone can send help from Earth. 

The first thing I noticed about the book was how realistic a lot of the mission terms and procedures seemed to be. The actual structure of the Mars Mission had a lot of the idiosyncrasies of a real mission. The science presented in it appeared to be accurate as well. I decided to look up the author after finishing the novel. It turns out the that the author is a computer programmer who put quite a lot of effort into making sure that the science in the book was reasonably accurate. From his pictures on Wikipedia I think he probably hung around NASA a lot and learned as much as he could about the procedures they follow and how they handle communication with the media and the general public before writing in those parts of the book. The book really gave me an insight into how difficult it can be to communicate science and technology effectively with the public and  how important it is to do it right. 

As I was reading the book it struck me that Matt Damon is the perfect person to play Mark Watney. With the incessant swearing and wisecracking, it was almost as though the character of Mark Watney was written with Matt Damon in mind. Of course, this is probably confirmation bias on my part but that's what was going through my mind as I read the book.

The Martian is also in the Goldilocks Zone with regards to the level of technical detail that the author decided to add in - not too much to turn away a general audience and just enough juicy detail to draw in the science nerds. Being a science nerd myself, I thought the density of science was ideal. 

A lot of the story was written from the perspective of Mark Watney as excerpts from his log. The reader is for the most part experiencing the story from the point of view of the man stuck on Mars. This made the novel feel very personal and all the more thrilling. Those brief moments where the writing switched to third person were absolutely spine chilling because in general, the book followed the pattern of switching to third person when things are about to go south. 

'The Martian' is an optimistic and very heartwarming exploration of what humans can do together if they really put their minds to it. A lot of people sacrificed a lot of things and a lot of money so that one man could come back to earth from Mars. Rivalries were set aside when the life of another human being was at stake. Would the events have played out similarly in real life? I don't know. But I believe - as the author probably did - that most humans are good at heart. So if asked about the most important thing I learned from the book, I'd say it is the maxim: "Be excellent to each other!". :D

Thursday, 20 August 2015

My Thoughts on the Ashley Madison Hack

The Ashley Madison website was hacked about a month ago and hackers stole gigabytes of user data including their full names, addresses and credit card data. On August 18, the hackers released all this data on the web. Now all this sounds really bad until you find out what Ashley Madison actually does. It's a website for men and women in a committed relationship to find other men and women in a committed relationship and have an affair. So while many disagree with the amount of information that the hackers actually released, I'm sure that a lot of people around the world are secretly happy that the data was stolen.

Infidelity is a despicable thing. I know how incredibly hurt and betrayed I would feel if I found out that my partner was cheating on me. The people who run the site are not doing anything illegal but they are complete assholes. Yes, it's true that the activities of the company are completely legal (as their public statements keep reminding us) but I think that in a way, this hack is the internet's way of telling Ashley Madison what gigantic dickheads they are for providing a platform for people to break promises.

However, despite the obvious reprehensibility of the target of the hack I don't condone the actions of its perpetrators. In fact, I would say that stealing personal information and violating the privacy of thousands of people is just as bad - if not worse. Releasing personal information on the internet often leads to online mobs carrying out witchhunts similar to what happened on reddit in the aftermath of the Boston Bombing incident. Two wrongs don't make a right.

Freedom of speech is a wonderful thing. But it doesn't protect you from criticism. In fact when you're doing appalling things, people around you have a right to call you out on it. The idea that I'm trying to explain is beautifully conveyed by this xkcd comic.

Alt text: I can't remember where I heard this, but someone once said that defending a position by citing free speech is sort of the ultimate concession; you're saying that the most compelling thing you can say for your position is that it's not literally illegal to express.

So the people at Ashley Madison should take this as a hint. No, what you're doing is not illegal but a lot of people (even some evil people) think it's contemptible. And they're showing you the door.

Tuesday, 18 August 2015

Dung Beetles are Extremely Cool

I've noticed little bugs scurry across the road quite a lot during my time at this college. Most of the time I've been too busy to actually go down and examine these bugs. Today, when I saw one of these critters crawling beside the road I decided to take a closer look.

What I found was the Dung Beetle in the process of rolling a ball of dung and trying to find a nest. Dung beetles are extremely cool creatures. From Wikipedia:

The "rollers" roll and bury a dung ball either for food storage or for making a brooding ball. In the latter case, two beetles, one male and one female, stay around the dung ball during the rolling process. Usually it is the male that rolls the ball, while the female hitch-hikes or simply follows behind. In some cases, the male and the female roll together. When a spot with soft soil is found, they stop and bury the ball, then mate underground. After the mating, both or one of them prepares the brooding ball. When the ball is finished, the female lays eggs inside it, a form of mass provisioning. Some species do not leave after this stage, but remain to safeguard their offspring. The dung beetle goes through a complete metamorphosis. The larvae live in brood balls made with dung prepared by their parents. During the larval stage, the beetle feeds on the dung surrounding it.

Here's a video from National Geographic that shows what the Dung beetles do.

Tuesday, 28 July 2015

Creating a Simple Bot using the Telegram Bot API

So Telegram recently released an API for creating bots on Telegram! It's quite cool. Already, people have released nice Python libraries for it. For this bot I'm using one of them.

I decided to create a simple Telegram bot that I can use to control the music on my laptop. It's a testament to the power and simplicity of Python and the convenience of the linux terminal that it only took me an hour to develop this. Head over to my repo at gihub if you want to look at the code!

Here's a video of it working!

Movie Review - Whiplash

Note: This post may contain spoilers.

I used to watch sci-fi and animated films exclusively but now every once in a while I watch a random movie just for the fun of it. Yesterday that random movie turned out to be Whiplash - a movie about an aspiring drummer and his well intentioned but abusive mentor.

I loved the movie but I disagree with the opinions of Terence Fletcher. There is a scene in the movie where he is asked if there is a line. If there is a limit which if he crosses he might actually discourage his student from becoming the next great musician that the world loves. And he replies that there is no such limit because the next great won't be discouraged. While that's a cute sentiment, I think he's wrong. The world isn't divided into 'The Greats' and talentless people. There are plenty of people who fall in between the spectrum. And I think that by not caring about those who are not destined to be 'Great' and even actively doing things that could damage them mentally he is doing more harm than good. Additionally, I think that there are a lot of people who respond much better to constructive criticism and positive reinforcement than to abuse hurled at them. For every person with a story about an abusive mentor who made them who they are, I think there are a few dozen people with stories about how their incredibly supportive and positive mentor inspired them to be their best.

So while the story was inspiring, I really hope that people don't use Terence as an inspiration. 

Saturday, 18 July 2015

Maker Faire Singapore

The day before yesterday I found out that there was a Maker Faire going on in Singapore this weekend! I immediately scrapped all my other plans for the weekend to get there. It was definitely worth it. I owe a lot to the maker movement. It's what got me interested in engineering and I think it's a big part of the reason I am the person I am today!

The highlight of the Maker Faire was definitely the whole hall dedicated to Intel Edison projects! There were so many cool things in that hall! I have to admit that I only had a vague idea of what the Intel Edison did before saw all those demos. It's a pretty capable SoC. My favorite demo were these dancing hexapods. They were really cool to watch. The second best demo was the robot with omni directional wheels.

The Dancing Hexapods

There was also quite an impressive display of 3D printing at the Faire. There were so many exhibits related to them! Apart from the conventional designs using steppers to move the extruder in the X-Y plane I also saw a 3D printer based on a delta robot.

Saw this 3D printer that could print huge parts

The delta robot 3D printer

Why Self-Driving Cars are the Future of Personal Transport

So Google's self driving cars are getting really good at self driving. A lot of people I know are skeptical about self driving cars. Some say that they will never use them because they just love to drive. I think that once self driving cars are actually on the road, they won't have a choice.

From everything the the testing of the self driving cars have shown so far, they seem to be much safer than human drivers. They don't get tired and they never break the rules. Human drivers on the other hand, cause millions of deaths every year due to carelessness and driving while sleepy, drunk or under the influence of drugs. Even if self driving cars only cut down the number of car accidents by half we have a moral obligation to switch over. By making the choice to continue driving manually we are making the choice for millions of deaths to continue happening every year.

I think that sometime in the distant future people will talk with horror about the time that people were allowed to drive their own cars. Just like we now talk with horror about the horrifying state of medical practices before we knew about germs and how exactly the human body worked.

Friday, 3 July 2015

Terminator Genisys – Review

I watched the movie a few days ago. And I thought I’d write down some thoughts I had about the movie.
First of all, I have to admit that although I roughly know what happens in the earlier movies I have only watched one of the previous three movies.So this is the first Terminator film the I’ve watched fully.

For me, the movie was just OK. Nothing spectacular. Visual effects were nice and that was probably the best part of the movie.

Apart from the fact that the movie uses a completely overused plot of using time travel to reset what happened in the earlier movies, my main complaint about the film is the portrayal of the new enhanced symbiote John Connor as evil. By merging with the machines, John Connor has finally solved two of humanity’s greatest problems: aging and disease! Why does the movie portray that as bad?
In fact, one of the most most interesting thing researchers in medicine are working on right now is using nanobots for targeted drug delivery. Imagine having an army of nanobots inside you making sure you don’t age and never get any disease.

If everyone were to merge with the machines like John Connor did there would actually be peace again and human civilization would have taken the next logical step of using their now immortal bodies to explore the vastness of interstellar space!

For once the AI in the movie has a goal to work together with humans and they just had to portray that as evil. I’d love to see a Terminator film where the humans and the AI (it’s supposed to be super intelligent!) finally realize that the best thing to do is cooperate.