Diffusion
FLOODS writes the diffusion equation using the grad() operator. Do this for each material you want diffusion in, and for each species that is diffusing. The example below is for the diffusion of molecular hydrogen (H2) in silicon dioxide (Oxide).
Set error tolerances
pdbSetDouble Oxide H2 Abs. Error 1.0e-5 pdbSetDouble Oxide H2 Rel. Error 1.0e-2
Define diffusion and other constants
set D 1.0e-9;# diffusivity
Store the transport equation in the pdb
set eqnD "ddt(H2)-$D*grad(H2)" pdbSetString Oxide H2 Equation $eqn;#store the transport equation in the pdb