Archive for December, 2006

Nonlinear Physics

Posted in Physics 5 years, 5 months ago

A course I much enjoyed this semester was on the equations of mathematical physics (PHYS384 for those at SFU.) We learnt a whole bunch of methods to solve and analyze equations that fit into the Sturm-Liouville framework of linear partial differential equations. The natural next step is to extend this body of knowledge to non-linear equations of mathematical physics. That is exactly what I’m doing next term.

We have a whole bunch of methods to analyze and predict the performance of linear systems, but systems in nature aren’t always that idealistic. The classic example is that of a frictionless pendulum with the equation of motion:

\ddot{\theta} + \omega_0^2 \sin(\theta) = 0

where \omega_0 = \sqrt{(g/l)}, g is the acceleration due to gravity and l is the length of the pendulum. The sine function being non-linear is often linearized to just \theta for small angles. This is the standard harmonic oscillator equation.

The real challenge is in analyzing the original non-linear equation. The difficulty in solving this equation is readily seen in the following Maxima session, where it isn’t smart enough to recognize the Jacobian elliptical integral.

Maxima session

The only course I’m taking next term is titled “Instabilities, Chaos and Turbulence in non-linear and complex systems” numbered PHYS484. We’ll explore a lot of these concepts. I’m really looking forward to it. Also check out this really cool experiment with a liquid:

YouTube video

Turbulent Winds

Posted in Misc 5 years, 5 months ago

The winds around the Burnaby mountain area were so bad yesterday. First, I was kept awake until 3 by the constant howling. When I finally fell asleep, I was abruptly woken up at 6am when my feet froze up. The winds had taken a bunch of power lines down and my building and the entire locality around the Lougheed Town Center was out of power.

Civilization just comes to a halt with a blackout. I couldn’t shower (electric heater) or groom myself, couldn’t make breakfast or lunch (electric cookers) or even see myself (sun rises at 9am and sets at 4pm). All of the stores around my place were closed. Just think of the lost opportunities.

Stanley park is in a state of chaos. There are fallen trees everywhere with power lines below them. There’s no power yet, so the place is pitch dark. A dangerous place to be.

Apparently, even MSFT [[check out their new spiffy homepage]] was shut down today due to winds in the Redmond area.

My LaTeX template

Posted in Computing 5 years, 5 months ago

After about four or five years, I’ve become quite proficient at writing reports and documents with LaTeX. I’ve recently been asked by a couple of friends to send them a sample document which could be used as a reference.

The basics

You’ll be writing (or typesetting) plain text to a file. This file, usually with the extension .tex, is the source code or markup that’ll be compiled. On compilation, you’ll get a DeVice Independent (.dvi) file. This is an intermediate file format that can be converted into a variety of suitable formats by driver programs. You can have a PostScript driver, a PDF driver, a PNG driver or a driver for displaying the file on screen.

Programs

You’ll need the programs latex, dvips, gv, and pdflatex. These programs usually come in a package called tetex-base on Linux. You’ll also find it handy to use the DVI viewer xdvi. On windows, MikTeX provides the above tools. The DVI viewer is called yap (included with MikTeX.)

Our first document

LaTeX “markup” is a lot like XHTML. You can group a block of text with the \begin and \end tags (like div or a in XHTML):

\begin{document}
...
\end{document}

You can issue commands that do not need a closing tag (like img):

\newpage{}
\section{Introduction}

You can find numerous tutorials on the web about the syntax, so I won’t go into that. Our first complete document would be:

%% first.tex : Our first document
\documentclass{article}
\begin{document}
    Hello World
\end{document}

To get a PDF of the document, issue the following commands [[you can also call pdflatex or dvipdf to skip intermediate steps]]:

latex first.tex
dvips first.dvi -o first.ps
ps2pdf first.ps first.pdf

It’s really that simple. The major drawback of this is that you need to key in these commands every time you want to view you document, which gets very tiring in a short while.

Samples

I never start a document from scratch. I’ve posted my template document that I’ve built over the years. Feel free to use and share it with your friends.