**Quote from abyssoft on 05/14/07 at 22:25:21:**Tony Since you are a master of sim building I have one that relates to this thread I would like to see.

Star =1.45 Msol

6 planets=0.5Mjup

Placement of planets such that

#1 @ 2.6 AU Base planet

#2 @ LG1 of Star and #1

#3 @ LG2 of Star and #1

#4 @ LG3 of Star and #1

#5 @ LG4 of Star and #1

#6 @ LG5 of Star and #1

All Should be in 1:1 resonance with #1

Just to see what happens.

Gravity Simulator does not provide an easy way to do this. So this is a good simulation to practice your algegra and trig. Start with a drawing of your system:

Now all you need to do is compute the x,y positions (call them r), and the x,y velocities (call them v).

Given is that m1 is 2.6 AU from the star. m3, m4, and m5 are the same distance too:

The distance from the star to m1 and m2 can be computed by adding and subtracting the m0's Hill Sphere radius:

Now we need to break these distances up into their x and y components. This is easy for 0, 1, 2, & 3 as they lie on the x-axis. Just pay attention to the diagram to make sure you get your signs correct:

This requires a little bit of 4th grade trig for objects 4 & 5:

Now we need the velocities. Objects 0, 3, 4, & 5 can be computed using the circular velocity formula:

Now we need to break these velocities up into their x and y components. This is easy for 0 & 3 as they lie on the x-axis:

And requires a little bit of trig for 4 & 5:

Now we need the velocities of objects 1 & 2. The circular velocity formula won't work here as object 1 will travel a little slower than normal since it is in the L1 point and must have the same period as object 0. And object 2 will travel a little faster than normal since it is in the L2 point and must have the same period as object 0. So we can get its velocity by dividing distance travelled by its period. Its distance travelled is simply its distance from the star times 2 pi:

Now we need to break the velocities into their x and y components. Since they lie on the x-axis, this is easy:

This gives us everything we need to start plugging in the numbers:

r1=388954463796.6-388954463796.6*(9.49304340314795E+26/(3*2.88392952200079E+30))

^(1/3)=370333651756.755

r2=388954463796.6+388954463796.6*(9.49304340314795E+26/(3*2.88392952200079E+30))

^(1/3)=407575275836.445

r4x=388954463796.6*cos(60)=194477231898.3

r4y=388954463796.6*sin(60)=336844446563.21

v0=v3=v4=v5=sqr((G*(9.49304340314795E+26+2.88392952200079E+30))/ 388954463796.6)=22245.5130780415

v4x=-v5x=22245.5130780415*sin(60)=19265.1794458029

v4y=v5y=22245.5130780415*cos(60)=11122.7565390208

v1=370333651756.755/sqr(388954463796.6^3/(G*(9.49304340314795E+26+2.883929522000

79E+30)))=21180.5310394943

v2=407575275836.445/sqr(388954463796.6^3/(G*(9.49304340314795E+26+2.883929522000

79E+30)))=23310.4951165886

Now make a table of each objects position and velocity vectors:

rx(0)=388954463796.6

ry(0)=0

vx(0)=0

vy(0)=22245.5130780415

rx(1)=370333651756.755

ry(1)=0

vx(1)=0

vy(1)=21180.5310394943

rx(2)=407575275836.445

ry(2)=0

vx(2)=0

vy(2)=23310.4951165886

rx(3)=-388954463796.6

ry(3)=0

vx(3)=0

vy(3)=-22245.5130780415

rx(4)=194477231898.3

ry(4)=336844446563.21

vx(4)=-19265.1794458029

vy(4)=11122.7565390208

rx(5)=194477231898.3

ry(5)=-336844446563.21

vx(5)=19265.1794458029

vy(5)=11122.7565390208

Open Gravity Simulator, create a system with a star 1.45 solar masses, place 6 objects, each 0.5 Jupiter masses in orbit around it, and use Objects > Edit Objects to enter the position and velocity vectors.

You will end up with

http://orbitsimulator.com/gravity/simulations/lagrange5.gsim Before you run it, take your best guess as to what will happen. I took my best guess, and I was correct

Gravity Simulator uses the programming convention that down is positive in the y-axis, while my diagram above used the standard math notation that up is positive in the y-axis, hence this diagram is inverted.