Pages

Sunday, November 17, 2013

History of computer science: hardware driven to software driven



Computer science (abbreviated as CS) is the scientific and practical approach to computation and its applications. The history of computer science is the best example of innovation. Based on my knowledge, the history of CS can be divided into two stages, the hardware driven stage and the software driven stage.


In the first stage of computer science, the hardware played a central role in its development. Abacus is the first kind of computing machine which helped human to perform simple mathematical computation in an efficient way. However, the abacus can’t automatically work and the usage is very limited. With the introduction of the punched card system in 1843, the first programmable computer is built by mechanical techniques. Although the way to use it is still very clumsy, many people are attracted to find out many novel ways to use it in different fields. The basic idea of the program is developed in that time. With the innovation in electronic industry, the punched card systems were quickly replaced by electronic circuits in the 1940s. The modern computer with Von Neumann architecture provided a powerful computing platform, which can’t only perform all kinds of computations but also can store inputs and results in memory. 


The second stage of computer science is driven by software. After the invention of the modern computer, the structure is kept unchanged for many years, which provided a very stable platform for the development of software. More and more applications are found out based on this platform and implemented as software in various programming languages. And requests from applications also drove the progress of hardware for faster computing speed and bigger memory size. The most recent progress as cloud computing has finally emancipated software from limitation of hardware. Hardware such as the central computing unit (CPU) and memory is abstracted to be computing resource and storage resource. Therefore, complex software can be run almost anywhere, even on a glass with a very tiny client-side computing unit, since most heavy-duty computing is performed in cloud side. This really brings computer science a brand new era with foreseeable big progress.

Tuesday, November 12, 2013

File sharing: a novel way for people's cooperation

Files, as the basic storage unit in computer, can record text, photo, audio, video and many other kinds of information in electronic way. File sharing means more than one user can obtain the access right to a file. Based on the different sharing rules, users can only read the file, or write to the file or keep a local copy and so on. File sharing is one of the most important techniques in computer science to enable the computer system with multiple users. And in today’s social network platform, file sharing is creating a novel way for people to better cooperating with each other.  

 Google document is one of the best examples which employed file sharing technique to help people work together. Many people in publishing house or news agency find it is very convenient to use Google doc for writing a paper with many people’s contributions. With Google doc, multiple people can share a file with not only read right, but also editing right the same time. This is a very convenient and evolutionary function for people’s cooperation. However, this kind of file sharing will always meet with problems as conflicts. For example, if two people are editing the different paragraphs of an article and then when they want to save the file the same time, conflict happens since what they want to save are different?  Google document use a version control system to handle this scenario, which means each people will keep a local version of the file and when multiple user want to save the file at the same time, Google document will perform a “merge” operation to combine various version to be a new version in common. If the same part of the article is editing by more than one people in different ways simultaneously, then there will be an unresolved conflict which might lead to a meaningful discussion between writers.


from www.wikipedia.org
Wikipedia is another good example, which employs file sharing to well organize people’s wisdom across the world. It is just like a very huge dictionary, while the content is dynamically updated. When there is a new term being added, a new file is created and shared to all other visitors. People with good knowledge of the term can enrich the content and all other readers will benefit from it. No one can be expert in every side of life, while Wikipedia brings all experts’ specific knowledge together and shares to the whole community for free.  However, how to determine the quality of the contents will be a much more complex problem than the conflicts as we discussed above in Google doc, since there might not be a unique “merged” result for some term. Today’s Wikipedia will depend on a committee with several specialists to determine which editing is good and which are not. It is not yet an idea solution due to many limitations, such as how to find a good committee and how to handle mass information efficiently. However, after years of year’s accumulation, the content will be tuned to be more and more near to the reality or the consensus of most people.

To summary in brief, file sharing can not only be used for handling sharing requirement in a multiple user computer system, but also can be used to provide an convenient platform for people’s better working with each other.

Websites mentioned in the blog
1. docs.google.com
2. www.wikipedia.org

Sunday, November 3, 2013

Date Structure: foundation of Computer Science



Data structure is the fundamental and core course in the Department of Computer Science. Any student who wants to study programming, database, artificial intelligence, and machine learning must learn data structure as the prerequisites. Since I am interested in data analysis, knowledge on database and programming skills are important for me. I took a study about courses offered by the Department of Computer Science at SJSU (San Jose State University) and created the following diagram. From this graph, we can find that data structure is undoubtedly the core course, which every CS student should begin from.


We have known the importance of data structure. The next question is that what data structure is or what content data structure includes. Narrowly speaking, data structure is a particular way of storing and organizing data in a computer so that it can be used efficiently [1]. Opening any data structure books, we can find different kinds of data types and structures which use to deal with different types of data and its application. Broadly speaking, data structure is a subject that studies the operation and the relation of objects which computer performs on. The research area of data structure covers software, hardware, and mathematics.

Finally, I want to share a very interesting data structure application example [2]. In a five-way intersection as following figure (a), C and E are both one-way streets. There are totally 13 available ways. Some of them can go through at the same time such as A to B and E to C. But some of them can’t go through simultaneously such as E to B and A to D. How can we design the traffic lights to control vehicles to let them safely pass the crossing without collision? Figure (b) provides an abstract view of the original problem, which looks complicated but completely modeled the problem with a classic data structure named as “undirected graph”. Each node in the graph represents a possible path while the connecting edge between two nodes indicates the two paths can’t be presented at the same time. Then a “vertex coloring” algorithm on the graph can be used to solve the problem on such an abstract data model. In Figure (b), the same number on the node indicates they are assigned the same color. For me, I enjoy extracting data structures and models from realistic problems. Hope you also like this example.


Reference
[2] Yan Weiming, “Data Structure In C”, Tsinghua University Press, 2009, 3rd Version

Sunday, October 27, 2013

Hacking: a dangerous double-sword


In computer science, hacking is a behavior to gain unauthorized access to data or system which is help by another people or organization. And hacker is the name for these people who are good at hacking. Sometimes hackers are esteemed as fighter to challenge monopoly while sometimes they are accused of crime. In my opinion, hacking is a double-sword; it could be used as a workaround for solving some problems, while many hacking behaviors are dangerous or even illegal, and should not be encouraged.

Many computer geeks are keen on hiking and take it as a spirit to challenge monopoly. One example is the popular “jailbreak” kits for Apple’s mobile operation system iOS. Since Apple’s iOS restrict iPad and iPhone users to use APP only bought from Apple’s store, many people don’t like this monopolistic like behavior and some of them took great efforts to hack the iOS system and developed a more open software environment freely for other users to let them download App not only from Apple store, but also from some unauthorized sources. After long term lawsuit, this hacking behavior is now taken to be legal in U.S.A. and has benefited many people. However, it might not be taken as a standard way to solve such kind of problems. Jailbreak iOS did give user more freedom while also brought with security issues and service issues. More malwares are easily to be installed on these jailbreak devices since they are not authorized by Apple. And Apple will not provide service to the problems caused by jailbreak. 


Hacking also has its dark side. Hacking bank’s computer systems and use other people’s credit card information stored in bank server to make personal benefit is the same as robbing a bank. Many people are doing similar hacking to illegally obtain other people’s private information due to profit purpose. These hacking behaviors should be accused of crime and will not be permitted. Even the purpose of hacking behaviors is not for personal profit, releasing private data of other people or organization to public without authorization could be a very dangerous behavior. A tragedy happened to Aaron Swartz is a warning for all of these hackers. Based on the purpose to make knowledge freely open to public, Swartz hacked MIT network in 2010 and downloaded nearly 5 million articles from JSTOR, one of famous digital archives of scholarly journals in the world and then put all these paper online for public free access. Many people adore him as a fighter to knowledge monopoly while the lawsuits against him finally pushed Swartz to commit suicide. Although I highly respect Aaron’s good wish, I don’t think such kind of hacking should be encouraged anymore. We should find a better way to achieve the same purpose without hacking.

Monday, October 14, 2013

Open Source: free but might not be high quality

What follows is a general definition of open source given by Wikipedia, a compute program in which the source code is available to the general public for use and modification from its original design. The open mind of open source stimulates the rapid development and spread use of software, as well as brings quality and maintenance problems.

Open is the key feature of open source. First, it is free to use. Nowadays, we can easily find many free software, such as Linux, R (a statistical computing software), both of which have been used by many people. More importantly, many expert users are becoming contributors for bug fixing, or new feature development because these software are also open to modify.  People get benefit by using these tools and then contribute their own effort to make it better. The open mind is the soul of open source software.


 Reference from http://www.r-project.org/

Of course, open source software has its own disadvantage. The quality and maintenance of open source software can’t be guaranteed. Because open source software developers do not need to make a strict commitment about functionality and quality to the users, while commercial companies such as Microsoft, Oracle will be required to pay more responsibility for their software products. Sometimes open source software can’t maintain consistency and coherence. For example, Android OS has too many different versions released by its principal contributor Google and some smart phone or pad manufacturers, such as Samsung, Amazon. This messy leads to a difficult problem for App developers on Android platform. They have to develop different versions of the same App for different cell phones. In addition, mistakes in open source software might be hard to solve. I have found a mistake in a mathematical package of R, which makes it can only be installed in Linux but not MAC OS. The worse thing is that there is no way to report the mistake and get the support to solve the problem because the original developer has stopped maintenance several years before.


  



Sunday, October 6, 2013

AGILE: advantage and disadvantage are equally obvious

Before discussing advantage and disadvantage of Agile, we need to know what is Agile. Based on definition from Wikipedia, Agile is a software development model that promotes adaptive planning, evolutionary development and delivery, adopts iterative approach, and encourages rapid and flexible response to change. The greatest feature of Agile is rapid.

A classic Agile development process is dividing project into small incremental releases. The cycle time of each release shortens from months to weeks. In addition, Agile focuses on communication between developer and customer. Through face to face conversation, developer can meet the dynamic change of customer.  


However, Agile also has some disadvantages. For large project, it is very difficult to assess the effort required at the beginning of the software development life cycle. Moreover, in order to improve the speed, Agile partly ignore documenting and designing which may cause the future problems when the program becomes larger and larger.  Also, project based on Agile might deviate from the track if customer is not clear with the target and always change mind, because Agile emphasize connection with customer and rapid response to customer.

Obviously, we can’t simply say that Agile is good or bad. The reasonable way is that we should make decision whether Agile is suitable for our project before adopting it.