ASTR327 -- HW #2

Parts 1 & 2: Due February 22, 2000
Parts 3 & 4: Due March 2, 2000

Making a ring galaxy.

You are going to create a simulation of a ring galaxy. To do this, you will write a simulation code which follows orbits in a spherical Hernquist potential. You will then make an N-body model of a disk galaxy, generating initial conditions for a rotating disk of particles inside the analytic potential. Finally, you will smash a smaller galaxy through the center of your model to create a ring galaxy.
  1. Write a program which integrates orbits in an analytic Hernquist potential. The parameters of the Hernquist model should be mass M=1 and scale radius a=1. Make sure it works. Plot a a few orbits, and demonstrate that the code is working properly.
  2. Write a program which generates initial conditions for an exponential disk inside that Hernquist potential. Initialize the velocities so that they are in circular motion inside the potential. Then give them some velocity dispersion. The model should have an exponential scale length of h=1, and should have 10,000 particles in it. Demonstrate that the model does have the correct exponential distribution of mass, and that it follows the proper rotation curve.
  3. Use your code to evolve the model for 5 rotation periods of the disk. Show snapshots of your model at several times during the run, demonstrating that the model is in equilibrium. Show also how well energy and angular momentum are conserved.
  4. Now adjust your code so that it can handle two potentials. The stars should feel both potentials, and move accordingly. Each potential should feel the other, and move accordingly. Make the second potential another Hernquist potential with total mass M=0.3 and a=0.7. (Don't bother populating the second model with stars...) Put the two model galaxies on a radial orbit, moving along the z-axis such that the two galaxies will collide in one disk rotation period. Show snapshots of what happens.

Useful References:

Computational Tools

Notes, hints, etc