diff options
-rw-r--r-- | param.ccl | 51 | ||||
-rw-r--r-- | schedule.ccl | 131 |
2 files changed, 125 insertions, 57 deletions
@@ -51,6 +51,23 @@ int find_every "how often should we try to find apparent horizons?" 1:* :: "any integer >= 1" } 1 +# +# These parameters control which schedule bin (or even bins, if you +# want) AHFinderDirect runs in. Historically, AHFinderDirect has run +# at CCTK_ANALYSIS. However, for some purposes it's more convenient +# to run at CCTK_POSTSTEP. +# +Boolean run_at_CCTK_ANALYSIS "should we run in CCTK_ANALYSIS schedule bin?" +{ +} "true" +Boolean run_at_CCTK_POSTSTEP "should we run in CCTK_POSTSTEP schedule bin?" +{ +} "false" + +# +# unless you're trying to debug AHFinderDirect, you should leave +# at its default value +# keyword method "what should this thorn do for each apparent horizon?" { # these options are mostly for testing/debugging @@ -145,7 +162,7 @@ keyword verbose_level \ } "algorithm highlights" # n.b. printing timing stats is independent of verbose_level -boolean print_timing_stats \ +Boolean print_timing_stats \ "should we print timing stats for the whole apparent-horizon-finding process?" { } "false" @@ -311,7 +328,7 @@ real initial_guess__coord_ellipsoid__z_radius[101] "z radius of ellipsoid" # - each line contains various tab-separated fields, as described by # the header comment # -boolean output_BH_diagnostics \ +Boolean output_BH_diagnostics \ "should we output BH diagnostics to a data file for each AH found?" { } "true" @@ -383,7 +400,7 @@ keyword horizon_file_format \ # n.b. this refers to the patch system (angular) interpatch ghost zones, # *not* the Cactus interprocessor ghost zones -boolean output_ghost_zones_for_h \ +Boolean output_ghost_zones_for_h \ "should we include the patch system (angular) interpatch ghost zones \ in h data files?" { @@ -453,7 +470,7 @@ string Delta_h_base_file_name \ # - the %d is the apparent horizon number # - the third %s is the file name extension OpenDX_control_file_name_extension # -boolean output_OpenDX_control_files \ +Boolean output_OpenDX_control_files \ "should we output OpenDX control files to allow reading of AHFinderDirect \ 'ASCII (gnuplot)' format data files?" { @@ -471,7 +488,7 @@ string OpenDX_control_file_name_extension \ # # this is mainly useful for debugging purposes -boolean output_initial_guess \ +Boolean output_initial_guess \ "should we output the initial guess back to the h data file?" { } "false" @@ -479,7 +496,7 @@ boolean output_initial_guess \ # for debugging convergence failures, we can optionally output # h, Theta, and delta_h at each Newton iteration # (the file names are the usual ones with ".it%d" appended) -boolean debugging_output_at_each_Newton_iteration \ +Boolean debugging_output_at_each_Newton_iteration \ "should we output {h, Theta, delta_h} at each Newton iteration?" { } "false" @@ -496,12 +513,12 @@ string Jacobian_base_file_name "base file name for Jacobian output file(s)" # ***** based on each apparent horizon shape ***** # -boolean set_mask_for_all_horizons \ +Boolean set_mask_for_all_horizons \ "should we set a mask grid function (or functions) for all horizons?" { } "false" -boolean set_mask_for_individual_horizon[101] \ +Boolean set_mask_for_individual_horizon[101] \ "should we set a mask grid function (or functions) for *this* horizon?" { } "false" @@ -551,7 +568,7 @@ real mask_buffer_thickness \ # values independently at each time step, so all three regions can grow # or shrink depending on the horizon positions/shapes. # -boolean mask_is_noshrink \ +Boolean mask_is_noshrink \ "should we prevent the inside & buffer regions from ever shrinking?" { } "true" @@ -600,11 +617,11 @@ real min_horizon_radius_points_for_mask \ # does horizon finding.] # You can choose to set either (or even both!) of these. # -boolean set_old_style_mask \ +Boolean set_old_style_mask \ "if we're setting a mask, should we set an old-style (CCTK_REAL) mask gridfn?" { } "true" -boolean set_new_style_mask \ +Boolean set_new_style_mask \ "if we're setting a mask, should we set an new-style (CCTK_INT) mask gridfn?" { } "false" @@ -1005,7 +1022,7 @@ real ILUCG__error_tolerance "error tolerance for conjugate gradient iteration" (0.0:*) :: \ "positive ==> error tolerance" } 1.0e-10 -boolean ILUCG__limit_CG_iterations \ +Boolean ILUCG__limit_CG_iterations \ "should we limit the maximum number of conjugate gradient iterations allowed?" { "false" :: "no limit on CG iterations" @@ -1047,7 +1064,7 @@ real Jacobian_perturbation_amplitude \ # if AHFinderDirect::method = "test Jacobian", should we test all # known methods for computing the Jacobian, or just the numerical perturbation # method (the latter may be useful of some other methods are broken) -boolean test_all_Jacobian_compute_methods \ +Boolean test_all_Jacobian_compute_methods \ "should we test all Jacobian computation methods, or just NP?" { } "true" @@ -1111,7 +1128,7 @@ string geometry_interpolator_pars \ # from the Cactus grid, we can instead hardwire it to an Eddington-Finkelstein # slice of Schwarzschild spacetime # -boolean hardwire_Schwarzschild_EF_geometry \ +Boolean hardwire_Schwarzschild_EF_geometry \ "should we hard-wire the geometry to Schwarzschild/EF instead of \ interpolating from the Cactus grid?" { @@ -1172,11 +1189,11 @@ real geometry__Schwarzschild_EF__Delta_xyz \ # useful in catching assorted wierdness, so it's probably worth leaving # them enabled unless you're trying to squeeze every last nanosecond... # -boolean check_that_h_is_finite \ +Boolean check_that_h_is_finite \ "should we check that horizon shape function h is finite?" { } "true" -boolean check_that_geometry_is_finite \ +Boolean check_that_geometry_is_finite \ "should we check the interpolated geometry variables are finite?" { } "true" @@ -1302,7 +1319,7 @@ keyword integral_method "how do we compute integrals over the horizon?" ### true ==> gives a more thorough test of the Jacobian, ### but makes the test run much slower ### false ==> gives a slightly less thorough test, but runs faster -##boolean NP_Jacobian__perturb_all_y_patch_points \ +##Boolean NP_Jacobian__perturb_all_y_patch_points \ ## "should we perturb at *all* points in the y patch, or just those with the \ ## iperp which is (supposedly) involved in the interpatch interpolation?" ##{ diff --git a/schedule.ccl b/schedule.ccl index bf0675e..2365116 100644 --- a/schedule.ccl +++ b/schedule.ccl @@ -1,70 +1,121 @@ # Schedule definitions for thorn AHFinderDirect # $Header$ -schedule AHFinderDirect_setup at CCTK_BASEGRID after SpatialCoordinates +# +# setup +# +schedule AHFinderDirect_setup at CCTK_BASEGRID \ +after SpatialCoordinates { lang: C options: global } "setup data structures" -if (find_every != 0) +# +# find horizons +# +if (run_at_CCTK_ANALYSIS != 0) { schedule AHFinderDirect_find_horizons at CCTK_ANALYSIS { lang: C options: global } "maybe find apparent horizon(s) after this time step" + } +if (run_at_CCTK_POSTSTEP != 0) + { + schedule AHFinderDirect_find_horizons at CCTK_POSTSTEP + { + lang: C + options: global + } "maybe find apparent horizon(s) after this time step" + } + +# +# announce horizon positions to other thorns +# +if (run_at_CCTK_ANALYSIS != 0) + { + schedule AHFinderDirect_announce at CCTK_ANALYSIS \ + before DriftCorrect \ + after AHFinderDirect_find_horizons + { + lang: C + } "maybe announce horizon position(s) to other thorns" + } +if (run_at_CCTK_POSTSTEP != 0) + { + schedule AHFinderDirect_announce at CCTK_POSTSTEP \ + before DriftCorrect \ + after AHFinderDirect_find_horizons + { + lang: C + } "maybe announce horizon position(s) to other thorns" + } - if (which_horizon_to_announce_centroid != 0) - { - schedule AHFinderDirect_announce at CCTK_ANALYSIS \ - before DriftCorrect \ - after AHFinderDirect_find_horizons - { - lang: C - } "maybe announce horizon position(s) to other thorns" - } - schedule AHFinderDirect_store_SS_info at CCTK_ANALYSIS \ - after AHFinderDirect_find_horizons +# +# store horizon info in SphericalSurface variables +# +if (run_at_CCTK_ANALYSIS != 0) + { + schedule AHFinderDirect_store_SS_info at CCTK_ANALYSIS \ + after AHFinderDirect_find_horizons + { + lang: C + options: global + } "maybe store horizon info in SphericalSurface variables" + } +if (run_at_CCTK_POSTSTEP != 0) + { + schedule AHFinderDirect_store_SS_info at CCTK_POSTSTEP \ + after AHFinderDirect_find_horizons { lang: C options: global } "maybe store horizon info in SphericalSurface variables" + } - # - # *** KLUDGE *** - # - # We would really like to give this routine the - # options:global - # attribute, so it only runs on those time levels where - # we've found (or at least tried to find) horizons. But - # this doesn't work, because we need a GH -- and the other - # thorns' routines we call need valid grid variables in - # it -- in the announcing code, and options:global - # routines don't have a "normal" GH, but instead a special - # one without usual grid variables defined in the usual - # manner. - # - # So, what to do? The present kludge is to have this - # routine called on every grid, then have it explicitly - # test if it's at a horizon-finding time and on a base - # grid. - # - schedule AHFinderDirect_maybe_do_masks at CCTK_ANALYSIS \ - after AHFinderDirect_find_horizons +# +# set excision mask +# +# *** KLUDGE *** +# +# We would really like to give this routine the +# options:global +# attribute, so it only runs on those time levels where we've found +# (or at least tried to find) horizons. But this doesn't work, because +# we need a GH -- and the other thorns' routines we call need valid +# grid variables in it -- in the announcing code, and options:global +# routines don't have a "normal" GH, but instead a special one without +# usual grid variables defined in the usual manner. +# +# So, what to do? The present kludge is to have this routine called +# on every grid, then have it explicitly test if it's at a horizon-finding +# time and on a base grid. +# +if (run_at_CCTK_ANALYSIS != 0) + { + schedule AHFinderDirect_maybe_do_masks at CCTK_ANALYSIS \ + after AHFinderDirect_find_horizons { lang: C } "maybe set mask(s) based on apparent horizon position(s)" - - # if using mesh refinement, reset the mask after regridding - # if not using mesh refinement, POSTREGRID is ignored so this is a no-op - schedule AHFinderDirect_maybe_do_masks at POSTREGRID \ - after (MaskOne MaskZero) + } +if (run_at_CCTK_POSTSTEP != 0) + { + schedule AHFinderDirect_maybe_do_masks at CCTK_POSTSTEP \ + after AHFinderDirect_find_horizons { lang: C } "maybe set mask(s) based on apparent horizon position(s)" - } +# if using mesh refinement, reset the mask after regridding +# if not using mesh refinement, POSTREGRID is ignored so this is a no-op +schedule AHFinderDirect_maybe_do_masks at POSTREGRID \ +after (MaskOne MaskZero) + { + lang: C + } "regrid ==> maybe reset mask(s) based on apparent horizon position(s)" ######################################## |