Archive for July, 2009

cmalabs turns 1 – a reflection

July 28th, 2009

It was this month last year that I decided to start this web blog. A year has passed and it’s time to reflect.

cmalabs symbolizes a change in my online behaviour. It was a move away from personal blogging because I became more self conscious about privacy.

It’s a place for me to discover my true interests by writing about them. A place to experiment with different styles of writing. A public diary, not a personal diary, but a diary of things I’ve thought about or found interesting. A diary addressed to my future self about ureka moments I’ve had, and about how naive those urekas will seem when I read it again in the future.

It was going to be a central place where I store all my interesting projects, none of which I’ve started.

Today, it is a place for me to experiment with writing. I was hoping that the topics I write about would converge, and through that I could discover what my true interests are. I consider something a true interest if you can talk or write on and on about without getting bored. Until today blog.cmalabs.com is still filled with completely unrelated topics. So I’m far from reaching my goal. The origin of the name “mustard and orange peel” reflects that. “Charles’s blog” sounds too boring, but it’s impossible to categorize what was going to write about because the topics will be too random.

This website might be a year old, but it’s only been active for two month. That is its true age. Hopefully after a year of activity, I’ll be just a little closer to my goal.

The Structure Of Fundemental Human Needs

July 26th, 2009

Anthony Robbins evangelized the six primal human needs as

  1. Certainty – the need for certainty of having food and shelter. This encompasses the physical needs that a human needs to survive.
  2. Variety – the need to change ones state of existence away from a state of restlessness.
  3. Significance – the need to feel special and recognized.
  4. Connection/Love – the need for interaction with other people. Depression is a symptom of the lack of 3 and 4.
  5. Growth – the need to grow with knowledge, experience, age, and wisdom. Everyone is either growing or dying. This is different from variety in that this is the spiritual need for positive change.
  6. Contribution – the need to give back to others, the satisfaction of feeling you’ve helped someone or you mean to something to someone else.

Anthony ordered these needs from physical to spiritual. As one slowly fulfill the physical needs, there is a greater desire for fulfillment. Interestingly, those living in poverty can still fulfill some of the spiritual needs without fulfilling the physical ones. This gives them the will to survive and grow. There is meaning in this ordering of needs, but it’s not a strict hierarchy.

Abraham Maslow has a different view of the fundamental human needs in which needs are arranged in a pyramid much like the food pyramid.
» Read more: The Structure Of Fundemental Human Needs

Russian Peasant Multiplication

July 26th, 2009

Interesting way to multiply numbers by hand.

This is a simple python program that takes 2 arguments and shows the steps of this multiplication technique.

#!/usr/bin/python
from os import sys
def russianPeasant(num1, num2, cache):
   cache[num1] = num2
   if num1 == 1:
      return
   return russianPeasant(num1>>1, num2<<1, cache)

def printResult(cache):
   sum = 0
   for key in reversed(sorted(cache.keys())):
      if key%2 == 1:
         sum += cache[key]
         print(str(key) + ': ' + str(cache[key]))
      else:
         print('' + str(key) + ' ' + str(cache[key]) + '')
   print("------------\n" + str(sum))

cache = {}
russianPeasant(int(sys.argv[1]), int(sys.argv[2]), cache)
printResult(cache)

Javascript Slow on Firefox 3, Switch To Chromium!

July 25th, 2009

Every popular website today uses a tremendous amount of javascript for both ajax and UI effects, this is bad news for firefox 3 users on linux because javascript is incredibly slow on linux versions of firefox. Firefox has been the dominant browser on linux and comes with most major distributions, and there aren’t many good alternatives. This issue is so bad that on slightly older computers, typing in a javascript wysiwyg text box is unbearably slow.

The solution? Switch to Opera or Chromium. Google’s chrome browser has one of the fastest Javascript engines around (next to safari’s), and although it’s still ‘unstable’, it’s quite usable for most people’s browsing needs.
Opera is available here, while chromium is available from google’s developer channel here.

Why Your Business Name is Important for Google

July 24th, 2009

Google has trillions of web pages in it’s indices, how are your customers going to find your website out of the hundreds of competitors out there?

When you’re picking a name, run it past Google. If you see a website url or website title that matches that name, then you already have stiff competition because someone else has already established a top position for that key word. Even if the top websites that come up aren’t competing businesses, the fact that they come up first when you search for them means that you’ll have to compete with them for that key word.

Here are some tips for picking Google friendly business names:

  1. Don’t pick names or phrases with ambiguous meanings or results. “Candy Shop” is a horrible name for a business even if you’re in the confectionery industry because it’s a song by 50cents. Not only will you be competing against other confectionery companies, but you’ll be competing against 50cents and you’re almost guaranteed to loose.
  2. Pick a name that currently has no Google ads appearing in search results. Google Adwords operate on a keyword based auction system, so if you want to advertise your business with Google ads, it’s much cheaper for you to be the first ad that comes up. If there is no competition, then you’ve already won the advertising war. Furthermore, having high ranking ads is a quick way to gain page rank if people find you to be more relevant.
  3. Don’t pick names where someone else has already established a dominant search position. ‘watch it’ is a bad name because a Canadian watch company is the obvious first result that comes up.
  4. The easiest way to win is to be the only one competing. This tip speaks for itself and generalizes the three points above.

All these tips tell you to avoid competition if you can, which is especially relevant if you’re a niche business. They’re not as relevant if you’re trying to take over the top position for a key word. That’s much harder to do and much more expensive. If you’re just starting out (the picking a name stage generally counts as “starting out”), then you want to avoid that until you have the resources to do so.

You don’t need the most relevant key word to your business, because the most relevant keyword for you maybe the most relevant keyword for a lot of other people and you’ll end up sharing that “relevance” if you’re competing against them. Think of a niche name for your business, so when people search for you, that’s the first thing that comes up because no one else has tried to use that name before.

I don’t mean to pick names that are completely meaningless one word utterances like a lot of “web2.0″ companies are doing because they’re hard to remember and it’s easy for a customer to forget what services you actually provide. For that to work, you have to wow your customers to make sure the remember you and make them keep coming back. That in itself is hard enough. Instead pick a name that’s relevant to your business, so you’ll be remembered. If they can remember your name, then they will be able to search for you. The most searched term on Google in the last few month has been “facebook”. People will search your name on Google even if the URL is obvious!

To recap. Pick a business name that
1) is relevant to what you do – because you want to be remembered
2) avoids search keyword competition – why make it harder on yourself when you don’t have to?

Modesty And Its Advantages

July 24th, 2009

Modesty is the opposite of arrogance, it’s the act of having done something impressive, kind, or astonishing, and then taking no credit for it or playing it down without gloating. It’s a sign of selflessness, and it’s a win-win scenario whether others know that you’re being modest or not.

If you’re friends or peers know that you’re modest, then they’ll want to be with you more. You’re enemies might be jealous of you, but who cares what they think?

If you’re modest with a stranger, he will have lower expectations for you, but it’s a chance to pleasantly surprise him. It’s better than the alternative of being disappointed if you don’t meet his expectations.

If you’re modest to a competitor, you can make yourself the underdog. Your competition won’t see you coming, maybe until it’s too late.

Faking modesty has the opposite effect.

Nothing is more amiable than true modesty, and nothing more contemptible than the false – Joseph Addison

It is a form of indirect gloating, it’s easy to tell when someone is pretending to be modest and fishing for compliments.

If you’re going to be modest, be genuinely modest.

Choose A Job You Love, Don’t Do What You Love As A Job

July 21st, 2009

Ever heard the saying “choose a job you love and you’ll never have to work a day in  your life”? That’s good advise if you can find a job that you love, but don’t take it to mean make what you love into your job.

Just because you love doing something doesn’t mean you’ll love doing it as a job. If you like golf, you may not like competitive golf. If you like writing, you may not like the strict styles and deadlines of a journalist.

If you can turn doing what you love into a career and still love it, then congradulations, you’re one of the 1-3% of people in the world who will be truly happy with life. If not, don’t force it and ruin what you loved doing. Keep your career separate from your passion unless the combination makes you happy.

Quay

July 21st, 2009

Whenever I see this word, my mental voice says ‘kway’. Why is it pronounced ‘key’? Words should be spelled the way they are pronounced, and words should be pronounced the way they are spelled. English is complexed enough as it is, why make it more complex than necessary? Language is a medium of communication, so it should be only as complex as necessary to convey ideas. It can have some extra features like synonyms because they help distinguish subtle differences in meaning and allow alternatives for creative expression, but features like arbitrary pronounciation rules add no value to a language.

If you designed a language today with a goal of efficiency in mind, I wonder what it would be like. Mathematics is an efficient language, but it’s a language for logic, not natural expression. In fact, it’s a horrible language for natural expression. It needs more ambiguity. A little bit of ambiguity is good in a language because it allows you to be creative, make puns, double entendres, and metaphors. Theres little room for that in mathematics.

An efficient natural language should allow anyone to express what they are feeling, their ideas, a set of instructions, an argument, and any form of verbal communication as easily as possible, but it needs to be flexible enough for a poet, a novelist, and any creative linguist to create verbal art like ones we have today, or better yet, allow poems to be even easier to write. Imagine a language that makes writing palindromes easy? Or a language where all words ends with similar sounds which make rhyming easy. What about a language where the accent on a vowel convey an emotion?

There are countless interesting features this language could have, the trick is finding a set of features that work well together. Whatever language features it has, let’s not have spelling “exceptions” that make English such a horrible second language to learn. When you are spending more time learning about spelling exceptions and silent letters than learning to communicate with that language, there’s something wrong. If you’re not a native speaker who grew up with these arbitrary rules, you’ll notice them. If you speak another language such as Spanish where pronounciation is almost never a problem, you’ll notice.

This is one of my pet peeves, unfortunately, there’s little I can do about it, but it does make me want to learn more languages!