Skip to content
This repository was archived by the owner on Aug 28, 2024. It is now read-only.

Commit

Permalink
Added the central body's contribution to orbital pre-collision angula…
Browse files Browse the repository at this point in the history
…r momentum to the post-collision spin.
  • Loading branch information
daminton committed Mar 20, 2023
1 parent 2739286 commit e5b28e4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/symba/symba_discard.f90
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ subroutine symba_discard_conserve_energy_and_momentum(pl, nbody_system, param, i
becb1 = -(3 * cb%Gmass * cb%mass) / (5 * cb%radius)

! Add planet angular momentum to central body accumulator
cb%dL(:) = Lpl(:) + cb%dL(:)
cb%dL(:) = Lpl(:) + cb%dL(:) + Lcb(:)
! Update rotation of central body to by consistent with its angular momentum
if (param%lrotation) then
drot0(:) = cb%L0(:)/ (cb%Ip(3) * cb%mass * cb%radius**2)
Expand Down

0 comments on commit e5b28e4

Please sign in to comment.