From charlesreid1

Domain1D class cantera/src/interfaces/python/Cantera/OneD/onedim.py

One-dimensional domains can be stacked together into Stack objects.

Each one-dimensional domain has some number of points associated with it. In each cell, it contains a set of components, and solves a set of equations.

One-dimensional domains have a Jacobian associated with them, which is used to advance the domain in time.

(Grid refiner object Refiner is used to change the number of grid points in a domain, based on criteria about magnitudes of variable value and derivative changes.)


Physics

(The equations being solved)

In src/src/oneD/OneDim.cpp, in the solve method, you can see how the domain is solved: a Jacobian is computed and evaluated, and the transient solution is updated

Numerics

Tolerances and bounds for each variable can be set using the setBounds and setTolerances methods.

The grid itself can be initialized by specifying locations of particular points, using the setupGrid method:

d.setupGrid([0.0, 0.1, 0.2, 0.3, 0.4, 0.5])

The one-dimensional domain's grid, name, and a description can be set using the set method.

Linking Domains Together

Domains are linked together into Stacks, using the linkLeft and linkRight methods.

Boundaries

Boundaries are themselves 1D objects, with temperatures and compositions. They can have a specified mass flowrate.

Surfaces

Surfaces are boundaries that have kinetics and kinetic equations associated with them. You can turn the kinetics on or off.

Misc.

Question: if you have a Domain1D object with a bunch of points, and you stack it with another Boundary Domain1D object, is the boundary object a single cell?

Answer: Yes. See cantera/src/src/oneD/boundaries1D.cpp and cantera/src/include/cantera/oneD/Domain1D.h, which contains the following code:

// A boundary object contains only one grid point
resize(n,1);

The boundary is initialized like this:

Bdry1D::Bdry1D() : Domain1D(1, 1, 0.0),

which means, according to the constructor, there is only one variable and one point in the domain.

Flags