Skip to content

Commit

Permalink
[indent-bot] standardised indentation
Browse files Browse the repository at this point in the history
  • Loading branch information
danieljprice committed Jul 15, 2020
1 parent 242f8a9 commit 211baa0
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 24 deletions.
14 changes: 7 additions & 7 deletions src/main/utils_binary.f90
Original file line number Diff line number Diff line change
Expand Up @@ -51,13 +51,13 @@ subroutine get_E(period,ecc,deltat,E)
M_guess = M_ref - 2.*tol

do while (abs(M_ref - M_guess) > tol)
M_guess = E_guess - ecc*sin(E_guess)
if (M_guess > M_ref) then
E_right = E_guess
else
E_left = E_guess
endif
E_guess = 0.5*(E_left + E_right)
M_guess = E_guess - ecc*sin(E_guess)
if (M_guess > M_ref) then
E_right = E_guess
else
E_left = E_guess
endif
E_guess = 0.5*(E_left + E_right)
enddo

E = E_guess
Expand Down
34 changes: 17 additions & 17 deletions src/setup/setup_asteroidwind.f90
Original file line number Diff line number Diff line change
Expand Up @@ -157,23 +157,23 @@ subroutine setpart(id,npart,npartoftype,xyzh,massoftype,vxyzu,polyk,gamma,hfact,

else

!
!--Set the asteroid on orbit around the fixed potential
!
mass1 = m1
accradius1 = hacc1
iexternalforce = 11
blackhole_spin = 0.
call update_externalforce(iexternalforce,time,0.)

! Orbit and position
nptmass = 1
xyzmh_ptmass(1:3,1) = (/semia*(1. + ecc),0.,0./)
vxyz_ptmass(1:3,1) = (/0.,sqrt(semia*(1.-ecc**2)*(m1+m2))/xyzmh_ptmass(1,1),0./)

xyzmh_ptmass(4,1) = m2
xyzmh_ptmass(ihacc,1) = hacc2 ! asteroid should not accrete
xyzmh_ptmass(ihsoft,1) = rasteroid ! asteroid radius softening
!
!--Set the asteroid on orbit around the fixed potential
!
mass1 = m1
accradius1 = hacc1
iexternalforce = 11
blackhole_spin = 0.
call update_externalforce(iexternalforce,time,0.)

! Orbit and position
nptmass = 1
xyzmh_ptmass(1:3,1) = (/semia*(1. + ecc),0.,0./)
vxyz_ptmass(1:3,1) = (/0.,sqrt(semia*(1.-ecc**2)*(m1+m2))/xyzmh_ptmass(1,1),0./)

xyzmh_ptmass(4,1) = m2
xyzmh_ptmass(ihacc,1) = hacc2 ! asteroid should not accrete
xyzmh_ptmass(ihsoft,1) = rasteroid ! asteroid radius softening
endif

! both of these are reset in the first call to inject_particles
Expand Down

0 comments on commit 211baa0

Please sign in to comment.