Last login: Tue Oct 6 15:07:13 2009 from maccullagh.math Copyright (c) 1980, 1983, 1986, 1988, 1990, 1991, 1993, 1994 The Regents of the University of California. All rights reserved. FreeBSD 4.11-STABLE (BOOLE) #1: Sat Oct 3 11:38:25 BST 2009 Welcome to the School of Maths Unix system. Type 'hogs' to see who is using disk space, or 'faq' for a list of questions and answers. *** boole ~$ cd MA3469 boole ~/MA3469$ # Two new compiler options: -O3 turns on a pretty aggressive boole ~/MA3469$ # optimisation (more conservative optimisation modes like -O boole ~/MA3469$ # or -O2 will produce slightly slower code), while -lm enables boole ~/MA3469$ # calls to cmath library /usr/lib/libm.so : boole ~/MA3469$ boole ~/MA3469$ g++ -O3 -lm -o kepler2d kepler2d.cpp boole ~/MA3469$ boole ~/MA3469$ # Please note a couple of tricks in making plots below! boole ~/MA3469$ gnuplot G N U P L O T Version 3.7 patchlevel 3 last modified Thu Dec 12 13:00:00 GMT 2002 System: FreeBSD 4.11-STABLE Copyright(C) 1986 - 1993, 1998 - 2002 Thomas Williams, Colin Kelley and many others Type `help` to access the on-line reference manual The gnuplot FAQ is available from http://www.gnuplot.info/gnuplot-faq.html Send comments and requests for help to Send bugs, suggestions and mods to Terminal type set to 'x11' gnuplot> # Since we want the trajectories being plotted without distortion gnuplot> # (so that circles do not turn into ellipses and vice versa), gnuplot> # the scales of y- and x- axes must be forced to equal each other: gnuplot> gnuplot> set size ratio -1 gnuplot> gnuplot> # To plot a bare trajectory, just proceed as usual: gnuplot> gnuplot> plot "< ./kepler2d" using 2:3 with lines gnuplot> gnuplot> # To get add a cross at the origin (the centre of attraction), use gnuplot> # a simple trick: gnuplot> gnuplot> plot "< ./kepler2d" using 2:3 with lines, "< echo 0 0" notitle with points pointtype 2 gnuplot> gnuplot> # (check what happens if notitle is omitted or different pointtype is chosen). gnuplot> boole ~/MA3469$