Skip to content

Commit

Permalink
Merge pull request #500 from tajjankovic/master
Browse files Browse the repository at this point in the history
Fixes #498
  • Loading branch information
danieljprice committed Feb 9, 2024
2 parents 3b7e53f + 1e740d1 commit 10811d3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/main/units.f90
Original file line number Diff line number Diff line change
Expand Up @@ -100,13 +100,13 @@ subroutine set_units(dist,mass,time,G,c)
utime = sqrt(udist**3/(gg*umass))
if (present(time)) print "(a)",' WARNING: over-riding time unit with G=1 assumption'
elseif (present(dist) .and. present(time)) then
umass = udist**2/(gg*utime**2)
umass = udist**3/(gg*utime**2)
if (present(mass)) print "(a)",' WARNING: over-riding mass unit with G=1 assumption'
elseif (present(mass) .and. present(time)) then
udist = (utime**2*(gg*umass))**(1.d0/3.d0)
if (present(dist)) print "(a)",' WARNING: over-riding length unit with G=1 assumption'
elseif (present(time)) then
umass = udist**2/(gg*utime**2) ! udist is 1
umass = udist**3/(gg*utime**2) ! udist is 1
else
utime = sqrt(udist**3/(gg*umass)) ! udist and umass are 1
endif
Expand Down

0 comments on commit 10811d3

Please sign in to comment.