a computer scientist’s thoughts
RSS icon Email icon Home icon
  • On the pass of house Health Care Bill

    I am happy to see that the house health care gets passed.

    Although I am not a citizen and don’t have right to vote on this issue, I really want to make some comments.

    During this year-long debate, I am sure about one thing: those conservatives have no fair mind. Their belief system is heavily distorted by so call…ed conservative leaders ( Fox, Rush, etc.). They develop a so-called “theory” to link health care bill with verses from Bible or budget deficit without any rational basis. Health care reform is such a complicated issue that we might have to wait a decade to see the true impact of this bill. However, we only see “clever” comments about how terrible this reform is without any justification.

    For people who have no health care and don’t want health care, I would suggest you to try living in a country like China for a year. When you have to pay every doctor visit and can’t get you bill paid because of the pre-existing condition, you will get the idea.

    Universal health care won’t necessarily make this country socialism ( or like Canada). Labeling is a basic form of logic fallacy. An educated person with fair mind and basic critical thinking skill won’t use it in debating. Some conservative leaders really don’t know it is a fallacy and use is as an “argument” everywhere.

    Despite all those disappointments towards conservatives in this debate, I won’t suggest those people to move to other countries with no universal health care. The greatest thing about this country’s democracy and freedom of speech is that everyone can speak and gets his/her idea expressed in the final resolution. This is an everlasting national treasure our founding fathers gave us. I do get a lot of thought-provoking arguments from the conservative group, and I think some of the issues they raise are very valuable ( e.g., how to handle deficit).

    Here is my last piece of philosophical thought. Scientific revolution, rationalism and all other distinguished thinkers in the 18th century all showed us one thing: this mundane world is not perfect, however, we human as a race can make it better via collective intelligence, via the power of reasoning. I personally will exclude God from any mundane argument, but the precondition is we have a solid ethic common ground (what is good, what is bad). Currently we are not there yet, so God ( and other ideological, religious beliefs), pre-existed in some people’s brain, will still jump to mundane debates. I accept this because I accept evolution, as I know the “belief” system is planted in out brain a gift, a result and a legacy of evolution.

  • On Google’s quitting China

    Maybe I should say something on this issue since I have done a lot of thinking about Google’s strategy in China since the first time they entered China. I have to make a disclaimer that I am Chinese, and I don’t agree with Google’s self-censorship in the first place.

    To make long story short, let me briefly review how the censorship works in China. For every website that offers services in China, a so-called “ISP license” is required. However, the government will revoke your license if it thinks that you are not so “manageable”, and therefore you have to shutdown your website (or they will block you if your servers are abroad). When Google first entered China, Chinese gov didn’t give it a license, and banned the access to Google.com from China since its search result was uncensored. To make the service available to Internet users in China, four years ago, Google started to filter the search results and provided them via Google.cn. Google.cn is a domain name registered in China. Google is just one example among many Internet service providers that do self-censorship.

    Every website in China, if their servers are in China, do self-censorship. Otherwise, secret-police will unplug your server cable and put you to jail if necessary.  As you can see, by restricting the service provider’s license and setting up the Great Firewall to restrict the access of Internet users, Chinese government literally set up a panopticon so that the prisoners (users and service providers) can watch each other and have to do self-censorship to survive.

    However, Chinese government was still not satisfied with what Google had done. They want to have full control of Google. During these years, say, pretty much once every year, Chinese government and the state controlled media would criticize Google for something that “is not legal according to local laws” and would suggest a solution with no surprise: tighter self-censorship. For instance, last year, they tried to flood Google.cn with some obscene keywords so that those keywords would be high frequent enough to enter auto-completion system. Then, they made a TV program showing that when you type in “son”, Google search box would hint you with “son and milf”. On that program, they were criticizing Google for “helping distributing pornography”. In one word, Google has been under a very high pressure doing business in China. Chinese government
    always wants Google to be its homeboy, which we obviously know Google’s response: No, simple and straight.

    I do agree that Google’s market share in China is not good enough, so I don’t think Google will lose any revenue substantially by quitting China’s market. China now is different than 10 years ago. Even it looks very nice from the outside now, it is extremely corrupted inside. Maybe I am making an oversimplified statement, but the truth is that no private business, not a single one, with proper moral standard, can make money in China. The reason is fairly simple: it is a government controlled market instead of a free market.

    Essentially, the market is controlled by the government and you have to “pay” for “using” the market. It sounds crazy since according to Adam Smith, nobody can really control market, the hidden hand. But currently, seriously, Chinese government, with a huge visible hand, is able to. Being a country with very high tax rate and secret police everywhere, the government has a much higher controlling power than that we would
    normally think of over the domestic market. It can simply kick the player out, or arrest the player, if that player doesn’t obey those so-called rules. Google is one of the victims.

    As a totalitarian state, it naturally needs some common bonds to control people’s mind. In China, insofar, the best mind weapon is called nationalism. Chinese government, intentionally or unintentionally, make some netizens believe that Baidu is a local company and it is a good kid, while Google is controlled by “westerners” and also is a bad kid.

    I am not concerned about Google’s losing money in China. In modern society,  some business might be able to earn money in a country without free speech, free market and democracy; some business might be able to earn money under a big government. However, in a country when tyranny is combined with big government, which we usually call totalitarian state, no private-owned company can make any profit if
    its moral standard is not compromised. The history in the last half century has provided so many examples.

    Also, I am very optimistic about the future of Google’s business in China. Again, i
    I strongly believe that Google will return to China on the day that China becomes a democratic nation where all citizens enjoy proper human right protection. Then Google will dominate China’s market, since it is really a superior service and there will be fair competitions.

  • Fix Latex-beamer

    A recent upgrade of latex on my Debian/Ubuntu caused some problem on compiling my latex-beamer slides. Latex reported that

    l.17 \pgfdeclareimage[
    width=14pt,height=12pt]{beamericonbook}{beamericonbook}
    You're in trouble here.  Try typing  <return>  to proceed.
    If that doesn't work, type  X <return>  to quit.

    According to some posts on the forum, it is because the latest version of latex put pgf package to core. Thus, the original pgf package become obsoleted.

    To fix this, you can just go to your latex directory and remove the whole pgf directory. On my machine by default, it’s

    /usr/share/texmf-texlive/tex/latex/pgf

    remove this and the problem solved.

    I wrote this because I found no explicit solution on the Internet. I tried a couple of times removing different pgf packages (they are scattered in more than one places) and finally found this solution.

    Happy hacking.

  • [Rant] Springer sucks

    First, LNCS is a place where 90% of the papers are not worth publishing. They are just the enemy of trees and the first cause of global warming in academia.

    Second, it does not support the bibtex format exporting. Who the hell wants your RIS format citation?

    For every citation from Springer, I have to spend 3 minutes in reformatting everything to a bibtex format. For those terrible papers I have to cite (some of the reviewers are so stupid, they force us to read a paper in LNCS, saying that our work would be complete without noticing some “significant” work published in a workshop held in the middle of no where in Europe by a group of unknown people. Come on, if you have some self-respect, you won’t want people to cite your own f* work published in a f* bad conference talking about a f* terrible idea without any intellectual merit], I have to write a script to change it from RIA format to bibtex. What should I waste time on these stupid things. All other publisher like ACM and IEEE (even Citeseer) supports the bibtex format.

    Shame on you, Springer, your LNCS sucks!

  • An incomplete idea on Linux–stdctrl

    Linux command line tools connected by pipes are cool. However, everything disappear on the X11 environment.

    We should have a stdin-like file descriptor for each X11 application such that we can pipe control operations to them. In this case, we can automate firefox or other stuff all in a transparent and de-coupled way. For instance, to visit google, we can pipe

    Ctrl L

    www.google.com

    Enter

    to firefox’s stdctl, and firefox will visit google.

    There are some command line tools like “expect” that can send applications input, but it is not general.

    On MacOS, applescript can sort of accomplish the same goal.

    My idea is to redesign the shell such that it supports the stdctrl syntax. The shell will create the process using popen and then send control signal to them. (replace expect). Hopefully we can finally control firefox without using any firefox API, we can just send Firefox X11 level control sequences.

  • Towards beautiful LaTeX

    (I will collect my random pieces of latex tricks here)

    Several hidden tricks in LaTeX.
    1. Text after italic text has a smaller blank space. To adjust that, you use \/ after {\it} group

    2. Always use ~\cite{} instead of  ” cite{}” because the tilde symbol will prevent latex to have a line break here.

    3. When you end a sentence with capitalized word, for example, if you want to say “I am a fan of NASA.” You should type
    I am a fan of NASA\@.

    Otherwise the . will be considered as part of NASA acronym.

    4. A tool called lacheck can help you find a lot of these common “uglies”.

  • Better than helloworld

    I saw that on reddit:

    while (1) if (1 != 1) printf(“cosmic ray detected\n”);

    Obviously it doesn’t make sense in the first version, because a modern C compiler will usually optimize the code such that the printf part is not in the executable code.

    However, here are some wonderful programs in the comment:

    volatile int x = 0;
    volatile int y = 0;
    while (1) if (x != y) {
    printf("Cosmic ray detected\n");
    y = x;
    }

    OK, I have to say that this is a better version. And here is a geedy comment about this:

    What if the cosmic ray comes during the execution of printf?

    Concurrency issues, man. You’ll need a cosmic ray detector inside your printf statement there, which puts you dangerously into yo dogg territory.

    LOL, I mean, seriously.

    Some other funny comments:

    The SETI source code has been leaked.

    And,

    I had a student in a class I graded for once write the following:
    if(x)
    ....
    else if(!x)
    ....
    else
    printf("Something is really messed up!\n");

    My personal favorite is of course this:


    while(!asleep()) sheep++;

  • The very first post

    This is a very short FAQ about this blog.

    Who is the host of this blog?

    I am Eric, a graduate student majoring in Computer Science at Washington University. I will share my life and views with others here.  I have to mention that I am Chinese and am not a native speaker. Bear with me if I MAKES some funny EngRish mistakes.  Hopefully, I can improve my writing by writing often.

    Why is this blog  called “Peaceful Revolution”?

    Because I had a Chinese blog, and got accused of “advocating a peaceful revolution” by some Chinese readers. I am also too lazy to argue with those readers in Chinese. Thus, I decided to divide my blog articles into two categories. The first category contains all articles about my life in the US and my thoughts, which will be in English. The second category is about computer science and other related things, which will have nothing to do with “advocating peaceful revolution” and therefore can be written in Chinese (I will post them on both my Chinese and English blogs).

    Well, I have to confess that the name is more than a rant. This name has more insights. I will explain this thoroughly later.

    What will the articles on this blog be like?
    My personal life, computer science, Linux, Mac, geeky things, funny things, etc.. Oh, don’t forget “peaceful revolution materials”, of course :) .

    (Caution: Chinese patriotic people who love Communism or China’s Communist Party, this blog is not for you. On the upper left/right side of your browser, there is an X symbol. Click it to close this window, so that your brain won’t suffer a “peaceful revolution” caused by this blog.)

    -EOF-