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

Commit

Permalink
Fixed issue where the rotation of impactors was not being saved properly
Browse files Browse the repository at this point in the history
  • Loading branch information
daminton committed Jan 18, 2023
1 parent ba3dbc9 commit 34ec164
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/collision/collision_resolve.f90
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,10 @@ module subroutine collision_resolve_consolidate_impactors(self, nbody_system, pa
end if
density(j) = impactors%mass(j) / volume(j)
impactors%radius(j) = (3 * volume(j) / (4 * PI))**(1.0_DP / 3.0_DP)
if (param%lrotation) impactors%Ip(:, j) = impactors%Ip(:, j) / impactors%mass(j)
if (param%lrotation) then
impactors%Ip(:, j) = impactors%Ip(:, j) / impactors%mass(j)
impactors%rot(:,j) = impactors%L_spin(:, j) / (impactors%Ip(3,j) * impactors%mass(j) * impactors%radius(j)**2)
end if
end do
lflag = .true.

Expand Down

0 comments on commit 34ec164

Please sign in to comment.