Twitter Weekly Digest for 2009-09-04

by Twitter on Sep 4, 2009

Powered by Twitter Tools.

Monte Carlo Simulation: What Is It?

by Hans F. on Sep 3, 2009

Sometimes engineers and scientists are faced with a problem that is not easily solvable with an algorithm that leads to a definite answer. Perhaps the problem is very complex and has many components to it, or the inputs to the problem are not constant and could vary. When faced with a situation like this, Monte Carlo simulation is the way to go.

The basic gist of how Monte Carlo simulations work is that you randomly select inputs, perform calculations on the randomly-selected inputs, and collect the outputs. This process is repeated several times (perhaps thousands, tens of thousands, or even more! As with any statistical sample, the more, the better), and in the end, all the outputs are gathered together and analyzed. To randomly select inputs, you’ll need to specify boundaries for which inputs can be selected from. A statistical model can help with this, such as a Gaussian distribution, which is a fancy term for the familiar “bell curve.” As for the aggregated outputs, statistical analysis would make sense in order to make sense of thousands of data sets. Basically, statistics is a useful tool that compliments the Monte Carlo technique. Also, generally computers are used to perform a Monte Carlo simulation due to the large number of repetitive calculations required.

This is what a bell curve looks like.

This is what a bell curve looks like.

Monte Carlo simulations can be used in space sciences. For example, if one wants to analyze the risk of failure of a spacecraft in orbit, one can perform a Monte Carlo simulation with random inputs for how the spacecraft begins its orbit (speed, physical orientation, etc.), since that state cannot be predetermined accurately and instead can be modeled statistically. Then, the laws of orbital mechanics can be applied to the inputs to produce outputs that can be analyzed later. A more simple example of where the Monte Carlo method is used is the classic game of Battleship. Initially, a player would randomly guess locations for where a battleship is located. After the player scores a hit, the player would follow an algorithm (guess points that are in line with the hit) to sink the battleship (the outcome).

(Image from Wikipedia)

“Earth Engineering”

by Kevin C. on Sep 1, 2009

A BBC article today, “Engineering Earth ‘is feasible’,” highlights the possibility of successfully mitigating further climate change by removing carbon dioxide (the primary greenhouse gas) or by preventing the Sun’s rays from even reaching Earth. A UK Royal Society study finds that these tactics are “technically possible,” even though they may be practically infeasible.

The study stressed that engineering approaches would only have a limited impact, and that efforts should continue to be focused on reducing CO2 emissions.

“(Governments) should make increased efforts toward mitigating and adapting to climate change and in particular agreeing to global emissions reductions of at least 50% on 1990 levels by 2050 and more thereafter,” the authors wrote.

But, they continued, there should be “further research and development” into geo-engineering options “to investigate whether low-risk methods can be made available if it becomes necessary to reduce the rate of warming this century”.

Injecting sea salt into the clouds could cool the planetOf the two basic geo-engineering approaches, the report concluded that those involving the removal of carbon dioxide were preferable, as they effectively return the climate system closer to its pre-industrial state.

But the authors found that many of these options were currently too expensive to implement widely.

This included “carbon capture and storage” methods, which require CO2 be captured directly from power plants and stored under the Earth’s surface.
Current proposed methods also work very slowly, taking many decades to remove enough carbon dioxide to significantly reduce the rate of temperature rise.

Of the carbon removal techniques assessed, three were considered to have most potential:
1. CO2 capture from ambient air: This would be the preferred method, as it effectively reverses the cause of climate change.
2. Enhanced weathering: This aims to enhance natural reactions of CO2 from the air with rocks and minerals. It was identified as a prospective longer-term option.
3. Land use and afforestation: The report found that land-use management could and should play a small but significant role in reducing the growth of atmospheric CO2 concentrations.

Read more about it here.

Twitter Weekly Digest for 2009-08-28

by Twitter on Aug 28, 2009
  • In our future: BENDY DISPLAYS! What do you think this means for our living room? Or even Times Square?!? http://bit.ly/105N5q #
  • Ever hear the line, "We've been walking around in circles"? There's good news. Now you can blame science: http://bit.ly/aWZl3 #
  • Remember the scare with the Hadron Collider and black holes? Apparently, we just can't get enough of them (Black Holes!) http://bit.ly/PFqjA #
  • First Internet addict rehab center opens in America! Check it: http://bit.ly/NaXbs. Reminds me of this from The Onion: http://bit.ly/15sjIS #
  • Back to school season isn't fun… #
  • Apparently the best way to decrease disease is to build better toildets. But at $1 a month to use the facilities? http://bit.ly/3X3yNU #
  • Got in a political discussion with a few people and missed the 9:00 am deadline. Sorry! :-( #
  • Testing TweetDeck span. #
  • Testing TweetDeck spanning. #
  • Testing a second post. Today is the first day of class. #
  • Nuclear Engineering class is pretty fun already! #

Powered by Twitter Tools.

Managing Large Software Projects

by Hans F. on Aug 27, 2009

Have you ever wondered how teams of computer programmers create large-scale programs successfully without hindering other people’s work? There are rather simple tools that keep track of versions of code being developed. This is known as version control, and one popular version control software is Subversion. There are several features in version control software that help keep track of changes as code evolves, as well as instances where more than one person works on a particular component of a project.

There are three main components to version control: branches, tags, and the trunk. The trunk can be thought of the main sector of a software project: most of the development work stems from the trunk. Tags are for special milestones in a project. Branches are what they sound like: they branch off from the trunk like a tree. All versions of each file in the project, old and new, are stored in what is known as a repository, with version numbers denoting how old a particular revision is.

There are many ways to utilize the branch-tag-trunk combination, but here’s an example. Say you have a team of software engineers working on a project. The trunk would be where known good code lives – code that isn’t broken nor has bugs. When someone wants to modify the code in the trunk (perhaps to make enhancements or add features), they would create a branch in the project and do their work in the branch. After they are done making code modifications in their branch, they would merge their branch back into the trunk. Most of the time, version control software is smart enough to figure out which parts of a particular file were modified, and incorporate those changes when two versions of the same file are merged together. Merging can also occur when two or more people modify one file at the same time, and later on decide to commit their individual changes to the repository. This way, you can have teams of more than one person working on particular parts of a project without the hassle of figuring out who changed what when combining everyone’s contributions into one – that’s what the version control software is there for.

A simple diagram showing how version control works.

A simple diagram showing how version control works.

Continuing with the above example, let’s imagine a major milestone for the project has been attained (perhaps Version 1.0 of the software is complete and ready for release). The code would then be tagged as a tag, and would sit as that particular tagged version in the repository. This is an example of how all three components of version control software is used, and hopefully this article sheds some light onto the underworkings of large-scale software projects.

(Image from Wikipedia)