Mesh Generators

class casingSimulations.mesh.BaseCylMixin(**kwargs)

Bases: properties.base.base.HasProperties

Mixin class that contains properties and methods common to a Cyl Mesh Generator

Required Properties:

  • csz (Float): cell size in the z-direction, a float, Default: 25.0
  • domain_x (Float): domain extent in the x-direction, a float, Default: 1000.0
  • hy (Array): cell spacings in the y direction, a list or numpy array of <type ‘float’> with shape (*), Default: [ 6.28318531]
  • nca (Integer): number of fine cells above the air-earth interface, an integer, Default: 5
  • ncb (Integer): number of fine cells below the casing, an integer, Default: 5
  • npadx (Integer): number of padding cells required to get to infinity!, an integer, Default: 23
  • npadz (Integer): number of padding cells in z, an integer, Default: 38
  • pfz (Float): padding factor in the z-direction, a float, Default: 1.5
create_2D_mesh()

create cylindrically symmetric mesh generator

csz

csz (Float): cell size in the z-direction, a float, Default: 25.0

domain_x

domain_x (Float): domain extent in the x-direction, a float, Default: 1000.0

domain_z

z-extent extent of the core mesh

hy

hy (Array): cell spacings in the y direction, a list or numpy array of <type ‘float’> with shape (*), Default: [ 6.28318531]

hz

cell spacings in the z-direction

Return type:numpy.array
nca

nca (Integer): number of fine cells above the air-earth interface, an integer, Default: 5

ncb

ncb (Integer): number of fine cells below the casing, an integer, Default: 5

ncy

number of core y-cells

Return type:float
ncz

number of core z-cells

Return type:float
npadx

npadx (Integer): number of padding cells required to get to infinity!, an integer, Default: 23

npadz

npadz (Integer): number of padding cells in z, an integer, Default: 38

pfz

pfz (Float): padding factor in the z-direction, a float, Default: 1.5

plotModels(sigma, mu, xlim=[0.0, 1.0], zlim=[-1200.0, 100.0], ax=None)

Plot conductivity and permeability models

x0

Origin of the mesh

class casingSimulations.mesh.BaseMeshGenerator(**kwargs)

Bases: casingSimulations.base.BaseCasing

Base Mesh Generator Class

Required Properties:

  • directory (String): Working directory, a unicode string, Default: .
  • filename (String): filename to serialize properties to, a unicode string, Default: MeshParameters.json
  • modelParameters (Wholespace): casing parameters instance, an instance of Wholespace
  • version (String): version of the software, a unicode string, Default: 0.0.4
copy()

Make a copy of the object

Return type:BaseMeshGenerator
filename

filename (String): filename to serialize properties to, a unicode string, Default: MeshParameters.json

mesh

discretize mesh

Return type:discretize.BaseMesh
modelParameters

modelParameters (Wholespace): casing parameters instance, an instance of Wholespace

class casingSimulations.mesh.CasingMeshGenerator(**kwargs)

Bases: casingSimulations.mesh.BaseMeshGenerator, casingSimulations.mesh.BaseCylMixin

Mesh that makes sense for casing examples

Required Properties:

  • csx1 (Float): finest cells in the x-direction, a float, Default: 0.0025
  • csx2 (Float): second uniform cell region in x-direction, a float, Default: 25.0
  • csz (Float): cell size in the z-direction, a float, Default: 25.0
  • directory (String): Working directory, a unicode string, Default: .
  • domain_x (Float): domain extent in the x-direction, a float, Default: 1000.0
  • filename (String): filename to serialize properties to, a unicode string, Default: MeshParameters.json
  • hy (Array): cell spacings in the y direction, a list or numpy array of <type ‘float’> with shape (*), Default: [ 6.28318531]
  • modelParameters (Wholespace): casing parameters instance, an instance of Wholespace
  • nca (Integer): number of fine cells above the air-earth interface, an integer, Default: 5
  • ncb (Integer): number of fine cells below the casing, an integer, Default: 5
  • npadx (Integer): number of padding cells required to get to infinity!, an integer, Default: 23
  • npadz (Integer): number of padding cells in z, an integer, Default: 38
  • pfx1 (Float): padding factor to pad from csx1 to csx2, a float, Default: 1.3
  • pfx2 (Float): padding factor to pad to infinity, a float, Default: 1.5
  • pfz (Float): padding factor in the z-direction, a float, Default: 1.5
  • version (String): version of the software, a unicode string, Default: 0.0.4
csx1

csx1 (Float): finest cells in the x-direction, a float, Default: 0.0025

csx2

csx2 (Float): second uniform cell region in x-direction, a float, Default: 25.0

hx

cell spacings in the x-direction

ncx1

number of cells with size csx1

npadx1

number of padding cells to get from csx1 to csx2

pfx1

pfx1 (Float): padding factor to pad from csx1 to csx2, a float, Default: 1.3

pfx2

pfx2 (Float): padding factor to pad to infinity, a float, Default: 1.5

class casingSimulations.mesh.CylMeshGenerator(**kwargs)

Bases: casingSimulations.mesh.BaseMeshGenerator, casingSimulations.mesh.BaseCylMixin

Simple 3D cylindrical mesh

Required Properties:

  • csx (Float): cell size in the x-direction, a float, Default: 25.0
  • csz (Float): cell size in the z-direction, a float, Default: 25.0
  • directory (String): Working directory, a unicode string, Default: .
  • domain_x (Float): domain extent in the x-direction, a float, Default: 1000.0
  • filename (String): filename to serialize properties to, a unicode string, Default: MeshParameters.json
  • hy (Array): cell spacings in the y direction, a list or numpy array of <type ‘float’> with shape (*), Default: [ 6.28318531]
  • modelParameters (Wholespace): casing parameters instance, an instance of Wholespace
  • nca (Integer): number of fine cells above the air-earth interface, an integer, Default: 5
  • ncb (Integer): number of fine cells below the casing, an integer, Default: 5
  • nch (Integer): number of cells to add on each side of the mesh horizontally, an integer, Default: 10.0
  • npadx (Integer): number of padding cells required to get to infinity!, an integer, Default: 23
  • npadz (Integer): number of padding cells in z, an integer, Default: 38
  • pfx (Float): padding factor to pad to infinity, a float, Default: 1.5
  • pfz (Float): padding factor in the z-direction, a float, Default: 1.5
  • version (String): version of the software, a unicode string, Default: 0.0.4
csx

csx (Float): cell size in the x-direction, a float, Default: 25.0

hx
nch

nch (Integer): number of cells to add on each side of the mesh horizontally, an integer, Default: 10.0

ncx
pfx

pfx (Float): padding factor to pad to infinity, a float, Default: 1.5

class casingSimulations.mesh.TensorMeshGenerator(**kwargs)

Bases: casingSimulations.mesh.BaseMeshGenerator

Tensor mesh designed based on the source and formulation

Required Properties:

  • csx (Float): cell size in the x-direction, a float, Default: 25.0
  • csy (Float): cell size in the y-direction, a float, Default: 25.0
  • csz (Float): cell size in the z-direction, a float, Default: 25.0
  • directory (String): Working directory, a unicode string, Default: .
  • domain_x (Float): domain extent in the x-direction, a float, Default: 1000.0
  • domain_y (Float): domain extent in the y-direction, a float, Default: 1000.0
  • filename (String): filename to serialize properties to, a unicode string, Default: MeshParameters.json
  • modelParameters (Wholespace): casing parameters instance, an instance of Wholespace
  • nca (Integer): number of extra cells above the air-earth interface, an integer, Default: 5
  • ncb (Integer): number of cells below the casing, an integer, Default: 5
  • nch (Integer): number of cells to add on each side of the mesh horizontally, an integer, Default: 10
  • npadx (Integer): number of x-padding cells, an integer, Default: 10
  • npady (Integer): number of y-padding cells, an integer, Default: 10
  • npadz (Integer): number of z-padding cells, an integer, Default: 10
  • pfx (Float): padding factor to pad to infinity, a float, Default: 1.5
  • pfy (Float): padding factor to pad to infinity, a float, Default: 1.5
  • pfz (Float): padding factor to pad to infinity, a float, Default: 1.5
  • version (String): version of the software, a unicode string, Default: 0.0.4
csx

csx (Float): cell size in the x-direction, a float, Default: 25.0

csy

csy (Float): cell size in the y-direction, a float, Default: 25.0

csz

csz (Float): cell size in the z-direction, a float, Default: 25.0

domain_x

domain_x (Float): domain extent in the x-direction, a float, Default: 1000.0

domain_y

domain_y (Float): domain extent in the y-direction, a float, Default: 1000.0

domain_z

vertical extent of the mesh

Return type:float
hx

vector of cell spacings in the x-direction

Return type:numpy.array
hy

vector of cell spacings in the y-direction

Return type:numpy.array
hz

vector of cell spacings in the z-direction

Return type:numpy.array
nca

nca (Integer): number of extra cells above the air-earth interface, an integer, Default: 5

ncb

ncb (Integer): number of cells below the casing, an integer, Default: 5

nch

nch (Integer): number of cells to add on each side of the mesh horizontally, an integer, Default: 10

ncx

number of x-cells

Return type:int
ncy

number of y-cells

Return type:int
ncz

number of z-cells

Return type:int
npadx

npadx (Integer): number of x-padding cells, an integer, Default: 10

npady

npady (Integer): number of y-padding cells, an integer, Default: 10

npadz

npadz (Integer): number of z-padding cells, an integer, Default: 10

pfx

pfx (Float): padding factor to pad to infinity, a float, Default: 1.5

pfy

pfy (Float): padding factor to pad to infinity, a float, Default: 1.5

pfz

pfz (Float): padding factor to pad to infinity, a float, Default: 1.5

x0

Origin of the mesh

Return type:numpy.array