2009-PHYS-339 Introduction to Programming

From McGill University Physics Department Technical Services Wiki

Synopsis

  • Equipment available: Tuesday January 6th through Thursday January 15th 2009.
  • Report due: Monday January 19th 2009.

Introduction

This is a two week exercise designed to get you up to speed with using the computer.

Do not overlook this step. Several of the programs you will need to write for the exercise can be used in later experiments. Write code that you can understand next month when you will not have time to reinvent the wheel.

This page should have a great deal more content!

Tutorial

The following links will take you to a tutorial section.

  • Help - This is a brief introduction to this help system
  • Login - How a login should work
  • X Desktop - How to interact with the desktop manager
  • Emacs - How to use my favorite editor

Resources for the exercise

Right click on these links to save them to disk.

  • intro.pdf (http://www.ugrad.physics.mcgill.ca/resources/339/intro/intro.pdf) - PDF version of document handed out in class
  • exercise.pdf (http://www.ugrad.physics.mcgill.ca/resources/339/intro/exercise.pdf) - PDF version of document handed out in class
  • sinusoid.data (http://www.ugrad.physics.mcgill.ca/resources/339/intro/sinusoid.data) - Data to be used for exercise
  • gaussian.data (http://www.ugrad.physics.mcgill.ca/resources/339/intro/gaussian.data) - Data used in examples, may be useful for testing programs.
  • stub.c (http://www.ugrad.physics.mcgill.ca/resources/339/intro/stub.c) - A sample of code which could be extended to manipulate the data.
  • LaTeX Template - this page documents the LaTeX template mentioned in the exercise handout.

Printing

If you wish to print a text file, use the command enscript.

kukucan:~# enscript window.c
[ 2 pages * 1 copy ] sent to printer

\begin{sarcasm}
For a slightly more in depth treatment of this topic, follow the link printing.
\end{sarcasm}

Links

Previous Versions