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

Commit

Permalink
Added back the fragmentation regime and involved bodies report from t…
Browse files Browse the repository at this point in the history
…he Fragmentation branch
  • Loading branch information
daminton committed Aug 11, 2021
1 parent 1f9d3c2 commit 22c327e
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/symba/symba_fragmentation.f90
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,9 @@ module function symba_fragmentation_casedisruption(system, param, family, x, v,
real(DP), dimension(:), allocatable :: m_frag, rad_frag
integer(I4B), dimension(:), allocatable :: id_frag
logical :: lfailure


write(*, '("Disruption between bodies ",I8,99(:,",",I8))') system%pl%id(family(:))

! Collisional fragments will be uniformly distributed around the pre-impact barycenter
nfrag = NFRAG_DISRUPT
allocate(m_frag(nfrag))
Expand Down Expand Up @@ -117,6 +119,8 @@ module function symba_fragmentation_casehitandrun(system, param, family, x, v, m
logical :: lpure
logical, dimension(system%pl%nbody) :: lmask

write(*, '("Hit and run between bodies ",I8,99(:,",",I8))') system%pl%id(family(:))

mtot = sum(mass(:))
xcom(:) = (mass(1) * x(:,1) + mass(2) * x(:,2)) / mtot
vcom(:) = (mass(1) * v(:,1) + mass(2) * v(:,2)) / mtot
Expand Down Expand Up @@ -217,7 +221,7 @@ module function symba_fragmentation_casemerge(system, param, family, x, v, mass,

select type(pl => system%pl)
class is (symba_pl)
write(*, '("Merging bodies ",99(I8,",",:))') pl%id(family(:))
write(*, '("Merging bodies ",I8,99(:,",",I8))') pl%id(family(:))

ibiggest = maxloc(pl%Gmass(family(:)), dim=1)
id_frag(1) = pl%id(family(ibiggest))
Expand Down Expand Up @@ -304,6 +308,8 @@ module function symba_fragmentation_casesupercatastrophic(system, param, family,
logical :: lfailure
logical, dimension(system%pl%nbody) :: lmask

write(*, '("Supercatastrophic disruption between bodies ",I8,99(:,",",I8))') system%pl%id(family(:))

! Collisional fragments will be uniformly distributed around the pre-impact barycenter
nfrag = NFRAG_SUPERCAT
allocate(m_frag(nfrag))
Expand Down

0 comments on commit 22c327e

Please sign in to comment.