test run
This commit is contained in:
@@ -14,9 +14,9 @@ from lib.units import *
|
||||
def main():
|
||||
#initialisation
|
||||
m = np.array([1., 1., 1e-1],dtype=np.longdouble)*Ms/Ms # Masses in Solar mass
|
||||
a = np.array([1., 1., 5.],dtype=np.longdouble)*au/au # Semi-major axis in astronomical units
|
||||
e = np.array([0., 0., 0.],dtype=np.longdouble) # Eccentricity
|
||||
psi = np.array([0., 0., 0.],dtype=np.longdouble)*np.pi/180. # Inclination of the orbital plane in degrees
|
||||
a = np.array([1., 1., 5.],dtype=np.longdouble)/2.*au/au # Semi-major axis in astronomical units
|
||||
e = np.array([0., 0., 1./4.],dtype=np.longdouble) # Eccentricity
|
||||
psi = np.array([0., 0., 45.],dtype=np.longdouble)*np.pi/180. # Inclination of the orbital plane in degrees
|
||||
|
||||
x1 = np.array([0., -1., 0.],dtype=np.longdouble)*a[0]*(1.+e[0])
|
||||
x2 = np.array([0., 1., 0.],dtype=np.longdouble)*a[1]*(1.+e[1])
|
||||
@@ -29,19 +29,20 @@ def main():
|
||||
v = np.array([v1, v2, v3],dtype=np.longdouble)
|
||||
|
||||
#integration parameters
|
||||
duration, step = 100*yr, np.array([1./(365.25*24.), 12./(365.25*24.), 24./(365.25*24.)],dtype=np.longdouble)*yr #integration time and step in seconds
|
||||
duration, step = 5000.*yr, np.array([10./(365.25)],dtype=np.longdouble)*yr #integration time and step in seconds
|
||||
step = np.sort(step)[::-1]
|
||||
integrator = "leapfrog"
|
||||
n_bodies = 3
|
||||
display = False
|
||||
savename = "{0:d}bodies_conc_{1:s}".format(n_bodies, integrator)
|
||||
savename = "{0:d}bodies_psi45_{1:s}".format(n_bodies, integrator)
|
||||
|
||||
bodies, bodysyst = [],[]
|
||||
for j in range(n_bodies):
|
||||
bodies.append(Body(m[j], q[j], v[j]))
|
||||
bin_syst = System(bodies[0:2])
|
||||
dyn_syst = System(bodies, main=True)
|
||||
bodysyst = [[deepcopy(bin_syst), deepcopy(dyn_syst)] for _ in range(n_bodies)]
|
||||
bodysyst = [[deepcopy(bin_syst), deepcopy(dyn_syst)] for _ in range(len(step))]
|
||||
|
||||
#simulation start
|
||||
exe = ProcessPoolExecutor()
|
||||
future_ELae = []
|
||||
|
||||
Reference in New Issue
Block a user