Commit 129ca58d authored by Zoheyr Doctor's avatar Zoheyr Doctor 🔭
Browse files

added inspiral video

parent cd51cd3b
......@@ -10,7 +10,7 @@ import sys
plt.style.use('dark_background')
fig,ax = plt.subplots()
fps = 30.
omega0 = 100.
omega0 = 20.
m1 = 30.,
m2 = 30.,
......@@ -25,8 +25,8 @@ binary = InspiralingBinary(
print('tc:',binary.tc)
print('omegamax',binary.omegamax)
sys.exit(0)
binary.inspiral()
print('t:',binary.t)
pos1 = binary.pos1_projected
pos2 = binary.pos2_projected
print('pos shape:',pos1.shape)
......
......@@ -43,6 +43,7 @@ class Binary:
self._pos1_projected = []
self._pos2_projected = []
self._r = 1.
@property
def r(self):
......@@ -182,8 +183,8 @@ class InspiralingBinary(Binary):
return (self.G*(self.m1+self.m2)/(self.omega**2))**(1./3)
def inspiral(self):
print('r,rmax types:',type(self.r),type(self.rmax))
while self.r > self.rmax:
print('r,rmax:',self.r,self.rmax)
self.t.append(self.t[-1]+(1./self.frame_rate))
self.orbit()
if isinstance(self.r,complex):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment