#2491: VolumeIntegrals_vacuum inherits directly from ML_BSSN
Reporter:Roland Haas
Status:new
Milestone:
Version:development version
Type:bug
Priority:major
Component:

Comment (by Zach Etienne):

Hey @Leonardo Werneck . I chatted with Roland about this. He says

The code itself is actually nice to read, just the method is not going to be quite what we want (and I *like* the fact that he reports with VError that he received unexpected input!).

The above code has a couple problems. First, if the gridfunction name changes in any of the above thorns, then we’ll end up getting errors. Second, the gridfunction names themselves must be “fully qualified”, meaning “ham” → “LeanBSSNMoL::ham”, etc.

Roland suggests that we instead require the users to pass the names of gridfunctions through the parameter interface; e.g.,

H_gf   = (CCTK_REAL*)(CCTK_VarDataPtr(cctkGH,timelevel, HamiltonianVarString)); // HamiltonianVarString is defined in param.ccl
if(!H_gf) {
  CCTK_VError (__LINE__, __FILE__, CCTK_THORNSTRING, "Couldn't get data pointer of input array variable '%s' ", HamiltonianVarString);
}

… and similarly for momentum constraints. I’d put in ML_BSSN variable strings as default in the param.ccl; e.g., HamiltonianVarString = “ML_BSSN::H” as default

--
Ticket URL: https://bitbucket.org/einsteintoolkit/tickets/issues/2491/volumeintegrals_vacuum-inherits-directly