diff options
author | allen <allen@5633253d-7678-4964-a54d-f87795f8ee59> | 2002-03-15 09:14:47 +0000 |
---|---|---|
committer | allen <allen@5633253d-7678-4964-a54d-f87795f8ee59> | 2002-03-15 09:14:47 +0000 |
commit | 94e1485b6b94cb5ac55bc91a2a7a0510f555a039 (patch) | |
tree | c790bf0c2ea799215050f1cfaf8d47351589567f | |
parent | 72f7dc2e7248eead5293ccbafe81fa9e63a3675b (diff) |
Fixed courant timestep based on wavespeed
(thanks to Christian Ott)
git-svn-id: http://svn.cactuscode.org/arrangements/CactusBase/Time/trunk@46 5633253d-7678-4964-a54d-f87795f8ee59
-rw-r--r-- | src/Courant.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Courant.c b/src/Courant.c index 9687f7b..ade4e53 100644 --- a/src/Courant.c +++ b/src/Courant.c @@ -55,7 +55,8 @@ void Time_Courant(CCTK_ARGUMENTS) } else if (CCTK_Equals(timestep_method,"courant_speed")) { - *courant_dt = courant_fac/(*courant_wave_speed)/sqrt((double) cctk_dim); + *courant_dt = courant_fac*min_spacing/ + (*courant_wave_speed)/sqrt((double) cctk_dim); } /* Set the Cactus timestep */ |