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

Commit

Permalink
i to j in symba_frag_pos
Browse files Browse the repository at this point in the history
  • Loading branch information
cwishard committed May 12, 2021
1 parent 8336612 commit c4b528f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/symba/symba_frag_pos.f90
Original file line number Diff line number Diff line change
Expand Up @@ -391,7 +391,7 @@ subroutine symba_frag_pos_fragment_velocity(m_frag, x_frag, v_r_unit, Lambda, v_
real(DP), dimension(:), intent(out) :: v_r_mag !! Radial velocity magnitude (the intial guess values for i=1:4, and the final values for i=5:nfrag)
real(DP), dimension(NDIM) :: Tau !! Sum of the tangential momentum vector of all fragments
! Internals
integer(I4B) :: i, j, k, nfrag
integer(I4B) :: i, j, nfrag
real(DP), dimension(NDIM) :: Gam !! Sum of the radial momentum vector of i>4 fragments
real(DP) :: Beta !! Sum of the radial kinetic energy of i>4 fragments
real(DP), dimension(4) :: v_r_mag_01, v_r_mag_02 !! Two initial value guesses for the radial velocity magnitude of the first four fragments
Expand Down Expand Up @@ -452,7 +452,7 @@ subroutine symba_frag_pos_fragment_velocity(m_frag, x_frag, v_r_unit, Lambda, v_

KE_after = 0.0_DP

do i = 1, 4
do j = 1, 4
v_r_mag(i) = v_r_mag_02(i) - f_vec_02(i) * (v_r_mag_02(i) - v_r_mag_01(i)) / (f_vec_02(i) - f_vec_01(i))
KE_after = KE_after + 0.5_DP * m_frag(i) * v_r_mag(i)**2
end do
Expand Down

0 comments on commit c4b528f

Please sign in to comment.