ADMBase, HydroBase, etc should not set up initial data
Issue #2628
new
Just throwing this into the wind, as I’m pretty confident it’ll be marked WONTFIX. But it is a major longstanding annoyance of mine.
I love the *Base thorns, as they enforce consistent interfaces between thorns. And we rightfully brag about this.
However, giving them authority to do anything except declare gridfunctions and set the number of timelevels for each is a step too far in my opinion.
Setting initial values of *Base variables should be the purview of thorns that set up initial data, and that’s it. For example, if one wishes to set Minkowski for certain variables, that should be the purview of a Minkowski ID thorn.
Yup, WONTFIX. The *Base variables also declare the parameters that control what is set as ID an those parameter have to have value. Someone then has to act on that parameter value and it the thorn that introduced the value is (naturally) the only one guaranteed to be around.
The other issue is that the *Base thorns not setting ID can lead to situations of not setting ID at all (namely if no ID thorn is activated). Really the ID thorns are the ones that must look at the
intiail_foo
parameters and then set their ID. The *Base thorns already do look at those parameters and only set the data to vacuum / Minkowski if the parameter values tell them to do so.How many timelevels are needed for a variable is actually something that is usually determined by a combination of the evolution thorn, Carpet and the time stepper. Keep in mind that multiple
STORAGE: foo[n]
statements for the samefoo
in mulitple thorns is valid, the largestn
is what gets used. NamelySTORAGE
allocates at leastn
levels of storage, not exactly.