def __init__(self, nx, ng=1, xmin=0.0, xmax=1.0):
    '\n        The class constructor function.\n\n        The only data that we require is the number of points that\n        make up the mesh.\n\n        We optionally take the extrema of the domain, number of ghost\n        cells (assume 1)\n        '
    self.nx = nx
    self.ng = ng
    self.qx = ((2 * ng) + nx)
    self.xmin = xmin
    self.xmax = xmax
    self.ilo = ng
    self.ihi = ((ng + nx) - 1)
    self.dx = ((xmax - xmin) / nx)
    self.xl = (((numpy.arange((nx + (2 * ng))) - ng) * self.dx) + xmin)
    self.xr = ((((numpy.arange((nx + (2 * ng))) + 1.0) - ng) * self.dx) + xmin)
    self.x = (0.5 * (self.xl + self.xr))
The class constructor function.

The only data that we require is the number of points that
make up the mesh.

We optionally take the extrema of the domain, number of ghost
cells (assume 1)
def __init__(self, nx, ng=1, xmin=0.0, xmax=1.0):
    '\n        The class constructor function.\n\n        The only data that we require is the number of points that\n        make up the mesh.\n\n        We optionally take the extrema of the domain, number of ghost\n        cells (assume 1)\n        '
    self.nx = nx
    self.ng = ng
    self.qx = ((2 * ng) + nx)
    self.xmin = xmin
    self.xmax = xmax
    self.ilo = ng
    self.ihi = ((ng + nx) - 1)
    self.dx = ((xmax - xmin) / nx)
    self.xl = (((numpy.arange((nx + (2 * ng))) - ng) * self.dx) + xmin)
    self.xr = ((((numpy.arange((nx + (2 * ng))) + 1.0) - ng) * self.dx) + xmin)
    self.x = (0.5 * (self.xl + self.xr))