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

Commit

Permalink
Fixed array bounds bug
Browse files Browse the repository at this point in the history
  • Loading branch information
daminton committed Jan 13, 2023
1 parent 945cf00 commit 57b79a6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/fraggle/fraggle_generate.f90
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ module subroutine fraggle_generate_pos_vec(collider)
! Later, velocities will be scaled such that the farther away a fragment is placed from the impact point, the higher will its velocity be.
call random_number(mass_rscale)
mass_rscale(:) = (mass_rscale(:) + 1.0_DP) / 2
mass_rscale(:) = mass_rscale(:) * (fragments%mtot / fragments%mass(:))**(0.125_DP) ! The power is arbitrary. It just gives the velocity a small mass dependence
mass_rscale(:) = mass_rscale(:) * (fragments%mtot / fragments%mass(1:nfrag))**(0.125_DP) ! The power is arbitrary. It just gives the velocity a small mass dependence
mass_rscale(:) = mass_rscale(:) / maxval(mass_rscale(:))

do loop = 1, MAXLOOP
Expand Down

0 comments on commit 57b79a6

Please sign in to comment.