As variable names are ``more local'' than subroutine or module names and the naming conventions vary even more, depending on author and date.
Mathematical conventions should be used as guide lines
gamma for or
Gamma1 for ).
CamelCase and/or underscores can be used to make variable names easier to read.
Variable names in often used structues (e.g., the
box structure) should
be used as guide for further names
(see, e.g., Sect. 8.1 and Sect. 8.3).
The individual components of vector quantities
(axes, velocities, magnetic-field components) don't get individual
letters but indices 1, 2, 3 for the respective spatial dimension.
So far, these stand for the , , and direction.
But these names should be avoided, leaving the possibility of - for instance -
spherical coordinates open.
Names of basic quantities are, e.g.,
for density ,
velocity in direction,
and internal energy per mass unit.
The centering of variables can be indicated by
c for cell-centered quantities
b for boundary-centered quantities
As cell centering is the default the
c is often omitted
Names of quantities that are simple combinations of existing quantities
are often constructed as combinations,
rhov1 for the momentum
of inventing an entirely unrelated name (as, e.g.,
The name of an energy tells abouts its components, e.g.,
eikg = ei + ek + eg (sum of internal, kinetic, and potential energy per mass unit).
rhoeikg = rhoei + rhoek + rhoeg (sum of internal, kinetic, and potential energy per volume).
The convention of combining names obviously has limits for more complex functions (as, e.g., fluxes).
Due to the lack of a sufficient number of letters in the alphabet
loop indices don't all get their individual letters, either.
Instead, they look like
The lower grid index is
m, the upper is
So, cell-centered quantities (in the absence of ghost cells) go
whereas boundary-centered quantities go