where δ X (with X = FG, CG or SG) is equal to d X /L z in slab geometry or to d X /L in spherical geometry. This functional form is selected to provide a smooth transition in the SG region (continuously differentiable at the boundaries). The gradient of the scaling function can be formulated based on Eqs. 12 and 13 using the chain rule, namely