Skip to content
master
Switch branches/tags
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
doc
 
 
 
 
src
 
 
 
 
 
 
 
 
Hat Trick Nbody Simulator
By William Olson and Jason Dittmann
Version 1.0
Copyright 2010 - GNU General Public License v3
http://code.google.com/p/hattrick-nbody/

TO COMPILE:
	Simply type 'make'.
	This uses gcc by default.  To change
	Edit GCC in the Makefile.
	
REQUIREMENTS:
	GNU Scientific Library:  Routines for integration of ODEs.  On
	Ubuntu/Debian install with:
		sudo apt-get install libgsl0-dev

TO RUN:
	Input format:
		./hattrick baseSys
		./hattrick baseSys n m1 r1 ... mn rn

	Where:
		baseSys: Name of the file specifying the base system.
		n (optional): Number of perturbing bodies.
		mn (optional): Mass of the nth perturbing body.
		rn (optional): Radius of the nth perturbing body.

	Base system file format:
		n t0 t1 h0 h1 accr printSkip stepType
		m1 x1 y1 z1 vx1 vy1 vz1
		m2 x2 y2 z2 vx2 vy2 vz2
			...
		mn xn yn zn vxn vyn vzn


	Where:
		n: Number of bodies in the base system.
		t0: Initial system time.
		t1: Final system time.
		hmin: Minimum time step.
		hmax: Max time step.  Also the initial step size.
		accr: Accuracy paramater.
		skipPrint:
			>0 to specify the time skipped between prints.
			=0 to print on orbits only.
			<0 to print just the closest orbit time.
		stepType: 0 for rk45, 1 for rk8pd, 2 for bsimp.


Examples:
	./hattrick
		Prints the help shown above.
		
	./hattrick sunearth.dat
		This will run a integration of the Sun and Earth.	
	
	./hattrick sunearth.dat 1 9.5492E-4 5.204267 > out.txt
		This will run a integration of the Sun, Earth and a circularized
		Jupiter and direct the ouput into 'out.txt'.

About

Simple but accurate N-Body integrator.

Resources

Releases

No releases published

Packages

No packages published