Closed eschnett closed 12 years ago
Yes, I think that not transforming them is the correct thing to do. There is also the issue of what to do with the upwinding direction in any advection derivatives (for McLachlan, at least). Also, since the Courant limit is typically inversely proportional to the maximum characteristic speed, which will transform by being multiplied by the (spatially-varying) determinant of the Jacobian from global to local, the Courant limit probably also transforms in this way. So the local Courant factor should be bounded by this if we want the system to be stable.
Maybe we want to allow "tags" or "options" for derivative operators, similar to "prolongation = none" for grid functions in Cactus. i.e. we could have "JacobianTransformation -> None" for dissipation operators. At some point, dissipation operators could be provided by default in Kranc, once we figure out how to do them efficiently.
I apply dissipation in a calculation on its own. A tag for calculations would work just as fine.
Instead of tags, there could also be special names for derivative operators, allowing me to access the un-jacobianised derivatives.
I have now a situation where applying Jacobians to dissipation makes a simulation unstable. Since this is a multi-block simulation, I have to manually change the generated source code, setting use_dissipation to 0.
I should add that this simulation also uses ZeroDimensions = {3}. It seems the Jacobian mixes in this third dimension, which is probably the cause for the instability.
I have committed code implementing this to the branch eschnett/vector-optimisations. Please review.
Applied.
Kranc applies the Jacobian transformation even to dissipation operators. However, it seems to transform these in the same way as first derivatives, not the N-th derivatives they are.
I find that transforming the dissipation terms as first derivatives is unstable, while not transforming them leads to stable evolutions.