g3d.mesh.modules package

Submodules

g3d.mesh.modules.block module

single-block mesh module

class g3d.mesh.modules.block.BlockModule(*args: Any, **kwargs: Any)[source]

Bases: MeshModule

Attributes:
blocks
return:

coordinates
return:

data
return:

data_file
return:

dx_wall
return:

dy_wall
return:

dz_wall
return:

edges
return:

n_blocks
return:

n_cells
return:

n_nodes
return:

n_smooth
return:

ni
return:

nj
return:

nk
return:

nk3D
return:

nodes
return:

smooth_faces
return:

stretch_rate_x
return:

stretch_rate_y
return:

stretch_rate_z
return:

tag

tag (string) used for identification

tags
return:

x1
return:

x2
return:

y1
return:

y2
return:

z1
return:

z2
return:

Methods

add_BC(bc, **kwargs)

add_Block(ni[, nj, nk])

add_Coord(c)

add_Edge(e)

add_IO(io, **kwargs)

add_Intf(faceA_def, faceB_def, **kwargs)

add_smooth_face(face_def)

add_smooth_face_glue(faceA_def, faceB_def)

add_tag(key, tag)

cell_get_block(kc)

cell_get_ijk(kc)

check_volumes()

circular_edge(c, ni, **kwargs)

copy(e)

copies data from specified entity input: entity example: copy(e)

copy_Face(faceA_def, faceB_def)

copy_X(im_to, l_to, im_from, l_from)

copy_XYZ(im_to, l_to, im_from, l_from)

copy_Y(im_to, l_to, im_from, l_from)

copy_Z(im_to, l_to, im_from, l_from)

export(*args, **kwargs)

exports mesh to file :param args: arguments (BinaryFormat), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE)

export_connections([bcf])

generate_mesh()

get_X(im[, lp])

get_XYZ(im[, lp])

get_Y(im[, lp])

get_Z(im[, lp])

get_extreme_coordinates()

get_x_min_x_max()

get_y_min_y_max()

get_z_min_z_max()

header(*args, **kwargs)

prints a header with specified information input: info optional input: dashes (default='='), scrw (default=80), number of blank lines after dashes n_space (default=1) example: header(info='header info')

hline(*args, **kwargs)

prints horizontal line optional input (kwargs): dashes (default='-'), scrw (default=80) example: hline(dashes='*', scrw=90)

import_mesh(*args, **kwargs)

imports mesh from file :param args: arguments (BinaryFormat, file base name (str)), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE), 'msh_file' -> filename, 'topo_file' -> filename

jobname_append(name)

extends jobname with the specified string input: name example: jobname_append(name)

node_get_block(kp)

node_get_ijk(kp)

populate_face_coordinate_placeholders(im, b)

print()

prints entity data

scale(sf)

set(*args, **kwargs)

sets code parameters according to specifications input: args, kwargs example: set(args, kwargs)

set_X(im, X[, lp])

set_XYZ(im, X, Y, Z[, lp])

set_Y(im, Y[, lp])

set_Z(im, Z[, lp])

set_from_key_value(key, value)

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: 'verbose', 'silent/quiet', 'jobname', 'working_directory', 'dimension', 'cuda', 'prof' example: set_from_key_value(key, value)

smooth([N])

allocate_arrays

export_3D_connections

fill

glue_blocks

nullify_boundary_lists

nullify_smooth_faces

plot_edges

plot_edges_XY

plot_edges_XZ

plot_edges_YZ

plot_module_edges

print_coordinates

print_extreme_values

redefine_ghosts

reset_coordinates

reset_edges

property dx_wall: float | int

return:

property dy_wall: float | int

return:

property dz_wall: float | int

return:

property ni: int

return:

property nj: int

return:

property nk: int

return:

property stretch_rate_x: float

return:

property stretch_rate_y: float

return:

property stretch_rate_z: float

return:

property x1: float

return:

property x2: float

return:

property y1: float

return:

property y2: float

return:

property z1: float

return:

property z2: float

return:

g3d.mesh.modules.channel module

channel (single-block) mesh module

class g3d.mesh.modules.channel.ChannelModule(*args: Any, **kwargs: Any)[source]

Bases: BlockModule

Attributes:
H
return:

L
return:

M
return:

Re
return:

Re_tau
return:

W
return:

blocks
return:

coordinates
return:

data
return:

data_file
return:

delta
return:

dx
return:

dx_p
return:

dx_wall
return:

dy_p
return:

dy_wall
return:

dz
return:

dz_p
return:

dz_wall
return:

edges
return:

flow_data
return:

n_blocks
return:

n_cells
return:

n_nodes
return:

n_smooth
return:

ni
return:

nj
return:

nk
return:

nk3D
return:

nodes
return:

rho
return:

smooth_faces
return:

stretch_rate_x
return:

stretch_rate_y
return:

stretch_rate_z
return:

tag

tag (string) used for identification

tags
return:

tau_w
return:

u_tau
return:

x1
return:

x2
return:

y1
return:

y2
return:

z1
return:

z2
return:

Methods

add_BC(bc, **kwargs)

add_Block(ni[, nj, nk])

add_Coord(c)

add_Edge(e)

add_IO(io, **kwargs)

add_Intf(faceA_def, faceB_def, **kwargs)

add_smooth_face(face_def)

add_smooth_face_glue(faceA_def, faceB_def)

add_tag(key, tag)

cell_get_block(kc)

cell_get_ijk(kc)

check_volumes()

circular_edge(c, ni, **kwargs)

copy(e)

copies data from specified entity input: entity example: copy(e)

copy_Face(faceA_def, faceB_def)

copy_X(im_to, l_to, im_from, l_from)

copy_XYZ(im_to, l_to, im_from, l_from)

copy_Y(im_to, l_to, im_from, l_from)

copy_Z(im_to, l_to, im_from, l_from)

de_plusify(d)

export(*args, **kwargs)

exports mesh to file :param args: arguments (BinaryFormat), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE)

export_connections([bcf])

generate_mesh()

get_X(im[, lp])

get_XYZ(im[, lp])

get_Y(im[, lp])

get_Z(im[, lp])

get_extreme_coordinates()

get_x_min_x_max()

get_y_min_y_max()

get_z_min_z_max()

header(*args, **kwargs)

prints a header with specified information input: info optional input: dashes (default='='), scrw (default=80), number of blank lines after dashes n_space (default=1) example: header(info='header info')

hline(*args, **kwargs)

prints horizontal line optional input (kwargs): dashes (default='-'), scrw (default=80) example: hline(dashes='*', scrw=90)

import_mesh(*args, **kwargs)

imports mesh from file :param args: arguments (BinaryFormat, file base name (str)), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE), 'msh_file' -> filename, 'topo_file' -> filename

jobname_append(name)

extends jobname with the specified string input: name example: jobname_append(name)

node_get_block(kp)

node_get_ijk(kp)

plusify(d)

populate_face_coordinate_placeholders(im, b)

print()

prints entity data

scale(sf)

set(*args, **kwargs)

sets code parameters according to specifications input: args, kwargs example: set(args, kwargs)

set_X(im, X[, lp])

set_XYZ(im, X, Y, Z[, lp])

set_Y(im, Y[, lp])

set_Z(im, Z[, lp])

set_from_key_value(key, value)

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: 'verbose', 'silent/quiet', 'jobname', 'working_directory', 'dimension', 'cuda', 'prof' example: set_from_key_value(key, value)

smooth([N])

allocate_arrays

export_3D_connections

fill

glue_blocks

nullify_boundary_lists

nullify_smooth_faces

plot_edges

plot_edges_XY

plot_edges_XZ

plot_edges_YZ

plot_module_edges

print_coordinates

print_extreme_values

redefine_ghosts

reset_coordinates

reset_edges

property H: float

return:

property L: float

return:

property M: float

return:

property Re: float

return:

property Re_tau: float

return:

property W: float

return:

de_plusify(d: float) → float[source]
Parameters:

d

Returns:

property delta: float

return:

property dx: float

return:

property dx_p: float

return:

property dy_p: float

return:

property dz: float

return:

property dz_p: float

return:

property flow_data: G3DChannelFlowCalculator

return:

plusify(d: float) → float[source]
Parameters:

d

Returns:

print() → None[source]

prints entity data

property rho: float

return:

property tau_w: float

return:

property u_tau: float

return:

g3d.mesh.modules.g3dmesh module

G3DMesh definitions (G3DMesh, G2DMesh)

class g3d.mesh.modules.g3dmesh.G2DMesh(*args: Any, **kwargs: Any)[source]

Bases: MeshModule

Attributes:
blocks
return:

coordinates
return:

data
return:

data_file
return:

edges
return:

n_blocks
return:

n_cells
return:

n_nodes
return:

n_smooth
return:

nk3D
return:

nodes
return:

smooth_faces
return:

tag

tag (string) used for identification

tags
return:

Methods

add_BC(bc, **kwargs)

add_Block(ni[, nj, nk])

add_Coord(c)

add_Edge(e)

add_IO(io, **kwargs)

add_Intf(faceA_def, faceB_def, **kwargs)

add_smooth_face(face_def)

add_smooth_face_glue(faceA_def, faceB_def)

add_tag(key, tag)

cell_get_block(kc)

cell_get_ijk(kc)

check_volumes()

circular_edge(c, ni, **kwargs)

copy(e)

copies data from specified entity input: entity example: copy(e)

copy_Face(faceA_def, faceB_def)

copy_X(im_to, l_to, im_from, l_from)

copy_XYZ(im_to, l_to, im_from, l_from)

copy_Y(im_to, l_to, im_from, l_from)

copy_Z(im_to, l_to, im_from, l_from)

export(*args, **kwargs)

exports mesh to file :param args: arguments (BinaryFormat), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE)

export_connections([bcf])

generate_mesh()

get_X(im[, lp])

get_XYZ(im[, lp])

get_Y(im[, lp])

get_Z(im[, lp])

get_extreme_coordinates()

get_x_min_x_max()

get_y_min_y_max()

get_z_min_z_max()

header(*args, **kwargs)

prints a header with specified information input: info optional input: dashes (default='='), scrw (default=80), number of blank lines after dashes n_space (default=1) example: header(info='header info')

hline(*args, **kwargs)

prints horizontal line optional input (kwargs): dashes (default='-'), scrw (default=80) example: hline(dashes='*', scrw=90)

import_mesh(*args, **kwargs)

imports mesh from file :param args: arguments (BinaryFormat, file base name (str)), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE), 'msh_file' -> filename, 'topo_file' -> filename

jobname_append(name)

extends jobname with the specified string input: name example: jobname_append(name)

node_get_block(kp)

node_get_ijk(kp)

populate_face_coordinate_placeholders(im, b)

print()

prints entity data

scale(sf)

set(*args, **kwargs)

sets code parameters according to specifications input: args, kwargs example: set(args, kwargs)

set_X(im, X[, lp])

set_XYZ(im, X, Y, Z[, lp])

set_Y(im, Y[, lp])

set_Z(im, Z[, lp])

set_from_key_value(key, value)

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: 'verbose', 'silent/quiet', 'jobname', 'working_directory', 'dimension', 'cuda', 'prof' example: set_from_key_value(key, value)

smooth([N])

allocate_arrays

export_3D_connections

fill

glue_blocks

nullify_boundary_lists

nullify_smooth_faces

plot_edges

plot_edges_XY

plot_edges_XZ

plot_edges_YZ

plot_module_edges

print_coordinates

print_extreme_values

redefine_ghosts

reset_coordinates

reset_edges

class g3d.mesh.modules.g3dmesh.G3DMesh(*args: Any, **kwargs: Any)[source]

Bases: MeshModule

Attributes:
blocks
return:

coordinates
return:

data
return:

data_file
return:

edges
return:

n_blocks
return:

n_cells
return:

n_nodes
return:

n_smooth
return:

nk3D
return:

nodes
return:

smooth_faces
return:

tag

tag (string) used for identification

tags
return:

Methods

add_BC(bc, **kwargs)

add_Block(ni[, nj, nk])

add_Coord(c)

add_Edge(e)

add_IO(io, **kwargs)

add_Intf(faceA_def, faceB_def, **kwargs)

add_smooth_face(face_def)

add_smooth_face_glue(faceA_def, faceB_def)

add_tag(key, tag)

cell_get_block(kc)

cell_get_ijk(kc)

check_volumes()

circular_edge(c, ni, **kwargs)

copy(e)

copies data from specified entity input: entity example: copy(e)

copy_Face(faceA_def, faceB_def)

copy_X(im_to, l_to, im_from, l_from)

copy_XYZ(im_to, l_to, im_from, l_from)

copy_Y(im_to, l_to, im_from, l_from)

copy_Z(im_to, l_to, im_from, l_from)

export(*args, **kwargs)

exports mesh to file :param args: arguments (BinaryFormat), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE)

export_connections([bcf])

generate_mesh()

get_X(im[, lp])

get_XYZ(im[, lp])

get_Y(im[, lp])

get_Z(im[, lp])

get_extreme_coordinates()

get_x_min_x_max()

get_y_min_y_max()

get_z_min_z_max()

header(*args, **kwargs)

prints a header with specified information input: info optional input: dashes (default='='), scrw (default=80), number of blank lines after dashes n_space (default=1) example: header(info='header info')

hline(*args, **kwargs)

prints horizontal line optional input (kwargs): dashes (default='-'), scrw (default=80) example: hline(dashes='*', scrw=90)

import_mesh(*args, **kwargs)

imports mesh from file :param args: arguments (BinaryFormat, file base name (str)), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE), 'msh_file' -> filename, 'topo_file' -> filename

jobname_append(name)

extends jobname with the specified string input: name example: jobname_append(name)

node_get_block(kp)

node_get_ijk(kp)

populate_face_coordinate_placeholders(im, b)

print()

prints entity data

scale(sf)

set(*args, **kwargs)

sets code parameters according to specifications input: args, kwargs example: set(args, kwargs)

set_X(im, X[, lp])

set_XYZ(im, X, Y, Z[, lp])

set_Y(im, Y[, lp])

set_Z(im, Z[, lp])

set_from_key_value(key, value)

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: 'verbose', 'silent/quiet', 'jobname', 'working_directory', 'dimension', 'cuda', 'prof' example: set_from_key_value(key, value)

smooth([N])

allocate_arrays

export_3D_connections

fill

glue_blocks

nullify_boundary_lists

nullify_smooth_faces

plot_edges

plot_edges_XY

plot_edges_XZ

plot_edges_YZ

plot_module_edges

print_coordinates

print_extreme_values

redefine_ghosts

reset_coordinates

reset_edges

g3d.mesh.modules.generic module

base class - generic mesh module

class g3d.mesh.modules.generic.MeshModule(*args: Any, **kwargs: Any)[source]

Bases: Grid

Attributes:
blocks
return:

coordinates
return:

data
return:

data_file
return:

edges
return:

n_blocks
return:

n_cells
return:

n_nodes
return:

n_smooth
return:

nk3D
return:

nodes
return:

smooth_faces
return:

tag

tag (string) used for identification

tags
return:

Methods

add_BC(bc, **kwargs)

add_Block(ni[, nj, nk])

add_Coord(c)

add_Edge(e)

add_IO(io, **kwargs)

add_Intf(faceA_def, faceB_def, **kwargs)

add_smooth_face(face_def)

add_smooth_face_glue(faceA_def, faceB_def)

add_tag(key, tag)

cell_get_block(kc)

cell_get_ijk(kc)

check_volumes()

circular_edge(c, ni, **kwargs)

copy(e)

copies data from specified entity input: entity example: copy(e)

copy_Face(faceA_def, faceB_def)

copy_X(im_to, l_to, im_from, l_from)

copy_XYZ(im_to, l_to, im_from, l_from)

copy_Y(im_to, l_to, im_from, l_from)

copy_Z(im_to, l_to, im_from, l_from)

export(*args, **kwargs)

exports mesh to file :param args: arguments (BinaryFormat), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE)

export_connections([bcf])

generate_mesh()

get_X(im[, lp])

get_XYZ(im[, lp])

get_Y(im[, lp])

get_Z(im[, lp])

get_extreme_coordinates()

get_x_min_x_max()

get_y_min_y_max()

get_z_min_z_max()

header(*args, **kwargs)

prints a header with specified information input: info optional input: dashes (default='='), scrw (default=80), number of blank lines after dashes n_space (default=1) example: header(info='header info')

hline(*args, **kwargs)

prints horizontal line optional input (kwargs): dashes (default='-'), scrw (default=80) example: hline(dashes='*', scrw=90)

import_mesh(*args, **kwargs)

imports mesh from file :param args: arguments (BinaryFormat, file base name (str)), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE), 'msh_file' -> filename, 'topo_file' -> filename

jobname_append(name)

extends jobname with the specified string input: name example: jobname_append(name)

node_get_block(kp)

node_get_ijk(kp)

populate_face_coordinate_placeholders(im, b)

print()

prints entity data

scale(sf)

set(*args, **kwargs)

sets code parameters according to specifications input: args, kwargs example: set(args, kwargs)

set_X(im, X[, lp])

set_XYZ(im, X, Y, Z[, lp])

set_Y(im, Y[, lp])

set_Z(im, Z[, lp])

set_from_key_value(key, value)

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: 'verbose', 'silent/quiet', 'jobname', 'working_directory', 'dimension', 'cuda', 'prof' example: set_from_key_value(key, value)

smooth([N])

allocate_arrays

export_3D_connections

fill

glue_blocks

nullify_boundary_lists

nullify_smooth_faces

plot_edges

plot_edges_XY

plot_edges_XZ

plot_edges_YZ

plot_module_edges

print_coordinates

print_extreme_values

redefine_ghosts

reset_coordinates

reset_edges

add_Coord(c: Coord) → None[source]
Parameters:

c

add_Edge(e: Edge) → None[source]
Parameters:

e

add_tag(key: str, tag: str) → None[source]
Parameters:
  • key

  • tag

static circular_edge(c: Coord, ni: int, **kwargs: Any) → Edge[source]
Parameters:
  • c

  • ni

  • kwargs

Returns:

property coordinates: list

return:

property data: list | ndarray

return:

property data_file: str

return:

property edges: list

return:

export_3D_connections() → None[source]
generate_mesh() → int[source]
Returns:

property n_smooth: int

return:

property nk3D: int

return:

plot_edges() → None[source]
plot_module_edges() → None[source]
print_coordinates() → None[source]
reset_coordinates() → None[source]
reset_edges() → None[source]
set_from_key_value(key: str, value: Any) → bool[source]

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: ‘verbose’, ‘silent/quiet’, ‘jobname’, ‘working_directory’, ‘dimension’, ‘cuda’, ‘prof’ example: set_from_key_value(key, value)

property smooth_faces: bool

return:

property tags: dict

return:

g3d.mesh.modules.hump module

hump mesh module (single block)

class g3d.mesh.modules.hump.DomainType(value)

Bases: Enum

An enumeration.

HILL_CENTER = 2
HILL_LEFT = 1
HILL_RIGHT = 3
UNDEFINED = 4
class g3d.mesh.modules.hump.HumpModule(*args: Any, **kwargs: Any)[source]

Bases: MeshModule

Attributes:
blocks
return:

coordinates
return:

data
return:

data_file
return:

dxf_control
return:

dy_wall
return:

edges
return:

n_blocks
return:

n_cells
return:

n_control_lines
return:

n_nodes
return:

n_smooth
return:

ni
return:

nj
return:

nj_wall_offset
return:

nk
return:

nk3D
return:

nodes
return:

shape_control
return:

smooth_faces
return:

stretch_rate_x
return:

stretch_rate_y
return:

tag

tag (string) used for identification

tags
return:

top_spacing_factor
return:

x1
return:

x2
return:

x_control
return:

y1
return:

y2
return:

z1
return:

z2
return:

Methods

add_BC(bc, **kwargs)

add_Block(ni[, nj, nk])

add_Coord(c)

add_Edge(e)

add_IO(io, **kwargs)

add_Intf(faceA_def, faceB_def, **kwargs)

add_smooth_face(face_def)

add_smooth_face_glue(faceA_def, faceB_def)

add_tag(key, tag)

cell_get_block(kc)

cell_get_ijk(kc)

check_volumes()

circular_edge(c, ni, **kwargs)

copy(e)

copies data from specified entity input: entity example: copy(e)

copy_Face(faceA_def, faceB_def)

copy_X(im_to, l_to, im_from, l_from)

copy_XYZ(im_to, l_to, im_from, l_from)

copy_Y(im_to, l_to, im_from, l_from)

copy_Z(im_to, l_to, im_from, l_from)

export(*args, **kwargs)

exports mesh to file :param args: arguments (BinaryFormat), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE)

export_connections([bcf])

generate_mesh()

get_X(im[, lp])

get_XYZ(im[, lp])

get_Y(im[, lp])

get_Z(im[, lp])

get_extreme_coordinates()

get_x_min_x_max()

get_y_min_y_max()

get_z_min_z_max()

header(*args, **kwargs)

prints a header with specified information input: info optional input: dashes (default='='), scrw (default=80), number of blank lines after dashes n_space (default=1) example: header(info='header info')

hline(*args, **kwargs)

prints horizontal line optional input (kwargs): dashes (default='-'), scrw (default=80) example: hline(dashes='*', scrw=90)

import_mesh(*args, **kwargs)

imports mesh from file :param args: arguments (BinaryFormat, file base name (str)), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE), 'msh_file' -> filename, 'topo_file' -> filename

jobname_append(name)

extends jobname with the specified string input: name example: jobname_append(name)

node_get_block(kp)

node_get_ijk(kp)

populate_face_coordinate_placeholders(im, b)

print()

prints entity data

scale(sf)

set(*args, **kwargs)

sets code parameters according to specifications input: args, kwargs example: set(args, kwargs)

set_X(im, X[, lp])

set_XYZ(im, X, Y, Z[, lp])

set_Y(im, Y[, lp])

set_Z(im, Z[, lp])

set_from_key_value(key, value)

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: 'verbose', 'silent/quiet', 'jobname', 'working_directory', 'dimension', 'cuda', 'prof' example: set_from_key_value(key, value)

smooth([N])

allocate_arrays

export_3D_connections

fill

glue_blocks

nullify_boundary_lists

nullify_smooth_faces

plot_edges

plot_edges_XY

plot_edges_XZ

plot_edges_YZ

plot_module_edges

print_coordinates

print_extreme_values

redefine_ghosts

reset_coordinates

reset_edges

property dxf_control: float

return:

property dy_wall: float

return:

property n_control_lines: int

return:

property ni: int

return:

property nj: int

return:

property nj_wall_offset: int

return:

property nk: int

return:

set_from_key_value(key: str, value: Any) → bool[source]

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: ‘verbose’, ‘silent/quiet’, ‘jobname’, ‘working_directory’, ‘dimension’, ‘cuda’, ‘prof’ example: set_from_key_value(key, value)

property shape_control: float

return:

property stretch_rate_x: float

return:

property stretch_rate_y: float

return:

property top_spacing_factor: float

return:

property x1: float

return:

property x2: float

return:

property x_control: float

return:

property y1: float

return:

property y2: float

return:

property z1: float

return:

property z2: float

return:

g3d.mesh.modules.ogv module

outlet guide vane (OGV) mesh module

class g3d.mesh.modules.ogv.OGVModule(*args: Any, **kwargs: Any)[source]

Bases: MeshModule

Attributes:
blocks
return:

chord
return:

coordinates
return:

data
return:

data_file
return:

edges
return:

idx_le
return:

idx_ps_le
return:

idx_ps_te
return:

idx_ss_le
return:

idx_ss_te
return:

idx_te
return:

idx_x_max
return:

idx_x_min
return:

idx_y_max
return:

idx_y_min
return:

le
return:

leading_edge
return:

length
return:

n_blocks
return:

n_cells
return:

n_nodes
return:

n_smooth
return:

ni_chord
return:

ni_inlet_block
return:

ni_le
return:

ni_outlet_block
return:

ni_ps
return:

ni_ss
return:

ni_te
return:

nj_o_grid
return:

nj_pitch
return:

nk3D
return:

nodes
return:

o_grid_offset
return:

ogv_edge
return:

ogv_edge_offset
return:

pitch
return:

pressure_side_edge
return:

ps_le
return:

ps_te
return:

smooth_faces
return:

span
return:

ss_le
return:

ss_te
return:

stretch_rate_x
return:

suction_side_edge
return:

tag

tag (string) used for identification

tags
return:

te
return:

trailing_edge
return:

wall_resolution
return:

x_in
return:

x_max
return:

x_min
return:

x_out
return:

y_max
return:

y_min
return:

Methods

add_BC(bc, **kwargs)

add_Block(ni[, nj, nk])

add_Coord(c)

add_Edge(e)

add_IO(io, **kwargs)

add_Intf(faceA_def, faceB_def, **kwargs)

add_smooth_face(face_def)

add_smooth_face_glue(faceA_def, faceB_def)

add_tag(key, tag)

cell_get_block(kc)

cell_get_ijk(kc)

check_volumes()

circular_edge(c, ni, **kwargs)

copy(e)

copies data from specified entity input: entity example: copy(e)

copy_Face(faceA_def, faceB_def)

copy_X(im_to, l_to, im_from, l_from)

copy_XYZ(im_to, l_to, im_from, l_from)

copy_Y(im_to, l_to, im_from, l_from)

copy_Z(im_to, l_to, im_from, l_from)

export(*args, **kwargs)

exports mesh to file :param args: arguments (BinaryFormat), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE)

export_connections([bcf])

generate_mesh()

get_X(im[, lp])

get_XYZ(im[, lp])

get_Y(im[, lp])

get_Z(im[, lp])

get_extreme_coordinates()

get_x_min_x_max()

get_y_min_y_max()

get_z_min_z_max()

header(*args, **kwargs)

prints a header with specified information input: info optional input: dashes (default='='), scrw (default=80), number of blank lines after dashes n_space (default=1) example: header(info='header info')

hline(*args, **kwargs)

prints horizontal line optional input (kwargs): dashes (default='-'), scrw (default=80) example: hline(dashes='*', scrw=90)

import_mesh(*args, **kwargs)

imports mesh from file :param args: arguments (BinaryFormat, file base name (str)), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE), 'msh_file' -> filename, 'topo_file' -> filename

jobname_append(name)

extends jobname with the specified string input: name example: jobname_append(name)

node_get_block(kp)

node_get_ijk(kp)

populate_face_coordinate_placeholders(im, b)

print()

prints entity data

scale(sf)

set(*args, **kwargs)

sets code parameters according to specifications input: args, kwargs example: set(args, kwargs)

set_X(im, X[, lp])

set_XYZ(im, X, Y, Z[, lp])

set_Y(im, Y[, lp])

set_Z(im, Z[, lp])

set_from_key_value(key, value)

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: 'verbose', 'silent/quiet', 'jobname', 'working_directory', 'dimension', 'cuda', 'prof' example: set_from_key_value(key, value)

smooth([N])

allocate_arrays

export_3D_connections

fill

glue_blocks

nullify_boundary_lists

nullify_smooth_faces

plot_edges

plot_edges_XY

plot_edges_XZ

plot_edges_YZ

plot_module_edges

print_coordinates

print_extreme_values

redefine_ghosts

reset_coordinates

reset_edges

property chord: float

return:

export_3D_connections() → None[source]
property idx_le: int

return:

property idx_ps_le: int

return:

property idx_ps_te: int

return:

property idx_ss_le: int

return:

property idx_ss_te: int

return:

property idx_te: int

return:

property idx_x_max: int

return:

property idx_x_min: int

return:

property idx_y_max: int

return:

property idx_y_min: int

return:

property le: Coord

return:

property leading_edge: Edge

return:

property length: float

return:

property ni_chord: int

return:

property ni_inlet_block: int

return:

property ni_le: int

return:

property ni_outlet_block: int

return:

property ni_ps: int

return:

property ni_ss: int

return:

property ni_te: int

return:

property nj_o_grid: int

return:

property nj_pitch: int

return:

property o_grid_offset: float

return:

property ogv_edge: Edge

return:

property ogv_edge_offset: Edge

return:

property pitch: float

return:

property pressure_side_edge: Edge

return:

property ps_le: Coord

return:

property ps_te: Coord

return:

set_from_key_value(key: str, value: Any) → bool[source]

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: ‘verbose’, ‘silent/quiet’, ‘jobname’, ‘working_directory’, ‘dimension’, ‘cuda’, ‘prof’ example: set_from_key_value(key, value)

property span: float

return:

property ss_le: Coord

return:

property ss_te: Coord

return:

property stretch_rate_x: float

return:

property suction_side_edge: Edge

return:

property te: Coord

return:

property trailing_edge: Edge

return:

property wall_resolution: float

return:

property x_in: float

return:

property x_max: Coord

return:

property x_min: Coord

return:

property x_out: float

return:

property y_max: Coord

return:

property y_min: Coord

return:

g3d.mesh.modules.single_block_cylinder module

single-block cylinder mesh module

class g3d.mesh.modules.single_block_cylinder.SingleBlockCylinderModule(*args: Any, **kwargs: Any)[source]

Bases: BlockModule

Attributes:
blocks
return:

coordinates
return:

cylinder_length
return:

cylinder_radius
return:

data
return:

data_file
return:

do_not_smooth_o_grid
return:

dx_wall
return:

dy_wall
return:

dz_wall
return:

edges
return:

inner_wake_cell_size
return:

n_blocks
return:

n_cells
return:

n_cells_external
return:

n_cells_half_freestream
return:

n_cells_half_inlet
return:

n_cells_half_outlet
return:

n_cells_o_grid
return:

n_data_points
return:

n_nodes
return:

n_smooth
return:

ni
return:

nj
return:

nk
return:

nk3D
return:

nodes
return:

o_grid_radius
return:

o_grid_scale_factor
return:

o_grid_shape_factor
return:

o_grid_stretch_rate
return:

outer_box_size
return:

outer_wake_cell_size
return:

smooth_faces
return:

stretch_rate_x
return:

stretch_rate_y
return:

stretch_rate_z
return:

tag

tag (string) used for identification

tags
return:

wall_cell_height
return:

x1
return:

x2
return:

y1
return:

y2
return:

z1
return:

z2
return:

Methods

add_BC(bc, **kwargs)

add_Block(ni[, nj, nk])

add_Coord(c)

add_Edge(e)

add_IO(io, **kwargs)

add_Intf(faceA_def, faceB_def, **kwargs)

add_smooth_face(face_def)

add_smooth_face_glue(faceA_def, faceB_def)

add_tag(key, tag)

cell_get_block(kc)

cell_get_ijk(kc)

check_volumes()

circular_edge(c, ni, **kwargs)

copy(e)

copies data from specified entity input: entity example: copy(e)

copy_Face(faceA_def, faceB_def)

copy_X(im_to, l_to, im_from, l_from)

copy_XYZ(im_to, l_to, im_from, l_from)

copy_Y(im_to, l_to, im_from, l_from)

copy_Z(im_to, l_to, im_from, l_from)

export(*args, **kwargs)

exports mesh to file :param args: arguments (BinaryFormat), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE)

export_connections([bcf])

generate_mesh()

get_X(im[, lp])

get_XYZ(im[, lp])

get_Y(im[, lp])

get_Z(im[, lp])

get_extreme_coordinates()

get_x_min_x_max()

get_y_min_y_max()

get_z_min_z_max()

header(*args, **kwargs)

prints a header with specified information input: info optional input: dashes (default='='), scrw (default=80), number of blank lines after dashes n_space (default=1) example: header(info='header info')

hline(*args, **kwargs)

prints horizontal line optional input (kwargs): dashes (default='-'), scrw (default=80) example: hline(dashes='*', scrw=90)

import_mesh(*args, **kwargs)

imports mesh from file :param args: arguments (BinaryFormat, file base name (str)), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE), 'msh_file' -> filename, 'topo_file' -> filename

jobname_append(name)

extends jobname with the specified string input: name example: jobname_append(name)

node_get_block(kp)

node_get_ijk(kp)

populate_face_coordinate_placeholders(im, b)

print()

prints entity data

scale(sf)

set(*args, **kwargs)

sets code parameters according to specifications input: args, kwargs example: set(args, kwargs)

set_X(im, X[, lp])

set_XYZ(im, X, Y, Z[, lp])

set_Y(im, Y[, lp])

set_Z(im, Z[, lp])

set_from_key_value(key, value)

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: 'verbose', 'silent/quiet', 'jobname', 'working_directory', 'dimension', 'cuda', 'prof' example: set_from_key_value(key, value)

smooth([N])

allocate_arrays

export_3D_connections

fill

glue_blocks

nullify_boundary_lists

nullify_smooth_faces

plot_edges

plot_edges_XY

plot_edges_XZ

plot_edges_YZ

plot_module_edges

print_coordinates

print_extreme_values

redefine_ghosts

reset_coordinates

reset_edges

property cylinder_length: float

return:

property cylinder_radius: float

return:

property do_not_smooth_o_grid: bool

return:

property inner_wake_cell_size: float

return:

property n_cells_external: int

return:

property n_cells_half_freestream: int

return:

property n_cells_half_inlet: int

return:

property n_cells_half_outlet: int

return:

property n_cells_o_grid: int

return:

property n_data_points: int

return:

property o_grid_radius: float

return:

property o_grid_scale_factor: float

return:

property o_grid_shape_factor: float

return:

property o_grid_stretch_rate: float

return:

property outer_box_size: float

return:

property outer_wake_cell_size: float

return:

set_from_key_value(key: str, value: Any) → bool[source]

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: ‘verbose’, ‘silent/quiet’, ‘jobname’, ‘working_directory’, ‘dimension’, ‘cuda’, ‘prof’ example: set_from_key_value(key, value)

property wall_cell_height: float

return:

Module contents

g3d/mesh/models sub library

class g3d.mesh.modules.BlockModule(*args: Any, **kwargs: Any)[source]

Bases: MeshModule

Attributes:
blocks
return:

coordinates
return:

data
return:

data_file
return:

dx_wall
return:

dy_wall
return:

dz_wall
return:

edges
return:

n_blocks
return:

n_cells
return:

n_nodes
return:

n_smooth
return:

ni
return:

nj
return:

nk
return:

nk3D
return:

nodes
return:

smooth_faces
return:

stretch_rate_x
return:

stretch_rate_y
return:

stretch_rate_z
return:

tag

tag (string) used for identification

tags
return:

x1
return:

x2
return:

y1
return:

y2
return:

z1
return:

z2
return:

Methods

add_BC(bc, **kwargs)

add_Block(ni[, nj, nk])

add_Coord(c)

add_Edge(e)

add_IO(io, **kwargs)

add_Intf(faceA_def, faceB_def, **kwargs)

add_smooth_face(face_def)

add_smooth_face_glue(faceA_def, faceB_def)

add_tag(key, tag)

cell_get_block(kc)

cell_get_ijk(kc)

check_volumes()

circular_edge(c, ni, **kwargs)

copy(e)

copies data from specified entity input: entity example: copy(e)

copy_Face(faceA_def, faceB_def)

copy_X(im_to, l_to, im_from, l_from)

copy_XYZ(im_to, l_to, im_from, l_from)

copy_Y(im_to, l_to, im_from, l_from)

copy_Z(im_to, l_to, im_from, l_from)

export(*args, **kwargs)

exports mesh to file :param args: arguments (BinaryFormat), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE)

export_connections([bcf])

generate_mesh()

get_X(im[, lp])

get_XYZ(im[, lp])

get_Y(im[, lp])

get_Z(im[, lp])

get_extreme_coordinates()

get_x_min_x_max()

get_y_min_y_max()

get_z_min_z_max()

header(*args, **kwargs)

prints a header with specified information input: info optional input: dashes (default='='), scrw (default=80), number of blank lines after dashes n_space (default=1) example: header(info='header info')

hline(*args, **kwargs)

prints horizontal line optional input (kwargs): dashes (default='-'), scrw (default=80) example: hline(dashes='*', scrw=90)

import_mesh(*args, **kwargs)

imports mesh from file :param args: arguments (BinaryFormat, file base name (str)), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE), 'msh_file' -> filename, 'topo_file' -> filename

jobname_append(name)

extends jobname with the specified string input: name example: jobname_append(name)

node_get_block(kp)

node_get_ijk(kp)

populate_face_coordinate_placeholders(im, b)

print()

prints entity data

scale(sf)

set(*args, **kwargs)

sets code parameters according to specifications input: args, kwargs example: set(args, kwargs)

set_X(im, X[, lp])

set_XYZ(im, X, Y, Z[, lp])

set_Y(im, Y[, lp])

set_Z(im, Z[, lp])

set_from_key_value(key, value)

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: 'verbose', 'silent/quiet', 'jobname', 'working_directory', 'dimension', 'cuda', 'prof' example: set_from_key_value(key, value)

smooth([N])

allocate_arrays

export_3D_connections

fill

glue_blocks

nullify_boundary_lists

nullify_smooth_faces

plot_edges

plot_edges_XY

plot_edges_XZ

plot_edges_YZ

plot_module_edges

print_coordinates

print_extreme_values

redefine_ghosts

reset_coordinates

reset_edges

property dx_wall: float | int

return:

property dy_wall: float | int

return:

property dz_wall: float | int

return:

property ni: int

return:

property nj: int

return:

property nk: int

return:

property stretch_rate_x: float

return:

property stretch_rate_y: float

return:

property stretch_rate_z: float

return:

property x1: float

return:

property x2: float

return:

property y1: float

return:

property y2: float

return:

property z1: float

return:

property z2: float

return:

class g3d.mesh.modules.ChannelModule(*args: Any, **kwargs: Any)[source]

Bases: BlockModule

Attributes:
H
return:

L
return:

M
return:

Re
return:

Re_tau
return:

W
return:

blocks
return:

coordinates
return:

data
return:

data_file
return:

delta
return:

dx
return:

dx_p
return:

dx_wall
return:

dy_p
return:

dy_wall
return:

dz
return:

dz_p
return:

dz_wall
return:

edges
return:

flow_data
return:

n_blocks
return:

n_cells
return:

n_nodes
return:

n_smooth
return:

ni
return:

nj
return:

nk
return:

nk3D
return:

nodes
return:

rho
return:

smooth_faces
return:

stretch_rate_x
return:

stretch_rate_y
return:

stretch_rate_z
return:

tag

tag (string) used for identification

tags
return:

tau_w
return:

u_tau
return:

x1
return:

x2
return:

y1
return:

y2
return:

z1
return:

z2
return:

Methods

add_BC(bc, **kwargs)

add_Block(ni[, nj, nk])

add_Coord(c)

add_Edge(e)

add_IO(io, **kwargs)

add_Intf(faceA_def, faceB_def, **kwargs)

add_smooth_face(face_def)

add_smooth_face_glue(faceA_def, faceB_def)

add_tag(key, tag)

cell_get_block(kc)

cell_get_ijk(kc)

check_volumes()

circular_edge(c, ni, **kwargs)

copy(e)

copies data from specified entity input: entity example: copy(e)

copy_Face(faceA_def, faceB_def)

copy_X(im_to, l_to, im_from, l_from)

copy_XYZ(im_to, l_to, im_from, l_from)

copy_Y(im_to, l_to, im_from, l_from)

copy_Z(im_to, l_to, im_from, l_from)

de_plusify(d)

export(*args, **kwargs)

exports mesh to file :param args: arguments (BinaryFormat), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE)

export_connections([bcf])

generate_mesh()

get_X(im[, lp])

get_XYZ(im[, lp])

get_Y(im[, lp])

get_Z(im[, lp])

get_extreme_coordinates()

get_x_min_x_max()

get_y_min_y_max()

get_z_min_z_max()

header(*args, **kwargs)

prints a header with specified information input: info optional input: dashes (default='='), scrw (default=80), number of blank lines after dashes n_space (default=1) example: header(info='header info')

hline(*args, **kwargs)

prints horizontal line optional input (kwargs): dashes (default='-'), scrw (default=80) example: hline(dashes='*', scrw=90)

import_mesh(*args, **kwargs)

imports mesh from file :param args: arguments (BinaryFormat, file base name (str)), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE), 'msh_file' -> filename, 'topo_file' -> filename

jobname_append(name)

extends jobname with the specified string input: name example: jobname_append(name)

node_get_block(kp)

node_get_ijk(kp)

plusify(d)

populate_face_coordinate_placeholders(im, b)

print()

prints entity data

scale(sf)

set(*args, **kwargs)

sets code parameters according to specifications input: args, kwargs example: set(args, kwargs)

set_X(im, X[, lp])

set_XYZ(im, X, Y, Z[, lp])

set_Y(im, Y[, lp])

set_Z(im, Z[, lp])

set_from_key_value(key, value)

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: 'verbose', 'silent/quiet', 'jobname', 'working_directory', 'dimension', 'cuda', 'prof' example: set_from_key_value(key, value)

smooth([N])

allocate_arrays

export_3D_connections

fill

glue_blocks

nullify_boundary_lists

nullify_smooth_faces

plot_edges

plot_edges_XY

plot_edges_XZ

plot_edges_YZ

plot_module_edges

print_coordinates

print_extreme_values

redefine_ghosts

reset_coordinates

reset_edges

property H: float

return:

property L: float

return:

property M: float

return:

property Re: float

return:

property Re_tau: float

return:

property W: float

return:

de_plusify(d: float) → float[source]
Parameters:

d

Returns:

property delta: float

return:

property dx: float

return:

property dx_p: float

return:

property dy_p: float

return:

property dz: float

return:

property dz_p: float

return:

property flow_data: G3DChannelFlowCalculator

return:

plusify(d: float) → float[source]
Parameters:

d

Returns:

print() → None[source]

prints entity data

property rho: float

return:

property tau_w: float

return:

property u_tau: float

return:

class g3d.mesh.modules.G2DMesh(*args: Any, **kwargs: Any)[source]

Bases: MeshModule

Attributes:
blocks
return:

coordinates
return:

data
return:

data_file
return:

edges
return:

n_blocks
return:

n_cells
return:

n_nodes
return:

n_smooth
return:

nk3D
return:

nodes
return:

smooth_faces
return:

tag

tag (string) used for identification

tags
return:

Methods

add_BC(bc, **kwargs)

add_Block(ni[, nj, nk])

add_Coord(c)

add_Edge(e)

add_IO(io, **kwargs)

add_Intf(faceA_def, faceB_def, **kwargs)

add_smooth_face(face_def)

add_smooth_face_glue(faceA_def, faceB_def)

add_tag(key, tag)

cell_get_block(kc)

cell_get_ijk(kc)

check_volumes()

circular_edge(c, ni, **kwargs)

copy(e)

copies data from specified entity input: entity example: copy(e)

copy_Face(faceA_def, faceB_def)

copy_X(im_to, l_to, im_from, l_from)

copy_XYZ(im_to, l_to, im_from, l_from)

copy_Y(im_to, l_to, im_from, l_from)

copy_Z(im_to, l_to, im_from, l_from)

export(*args, **kwargs)

exports mesh to file :param args: arguments (BinaryFormat), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE)

export_connections([bcf])

generate_mesh()

get_X(im[, lp])

get_XYZ(im[, lp])

get_Y(im[, lp])

get_Z(im[, lp])

get_extreme_coordinates()

get_x_min_x_max()

get_y_min_y_max()

get_z_min_z_max()

header(*args, **kwargs)

prints a header with specified information input: info optional input: dashes (default='='), scrw (default=80), number of blank lines after dashes n_space (default=1) example: header(info='header info')

hline(*args, **kwargs)

prints horizontal line optional input (kwargs): dashes (default='-'), scrw (default=80) example: hline(dashes='*', scrw=90)

import_mesh(*args, **kwargs)

imports mesh from file :param args: arguments (BinaryFormat, file base name (str)), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE), 'msh_file' -> filename, 'topo_file' -> filename

jobname_append(name)

extends jobname with the specified string input: name example: jobname_append(name)

node_get_block(kp)

node_get_ijk(kp)

populate_face_coordinate_placeholders(im, b)

print()

prints entity data

scale(sf)

set(*args, **kwargs)

sets code parameters according to specifications input: args, kwargs example: set(args, kwargs)

set_X(im, X[, lp])

set_XYZ(im, X, Y, Z[, lp])

set_Y(im, Y[, lp])

set_Z(im, Z[, lp])

set_from_key_value(key, value)

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: 'verbose', 'silent/quiet', 'jobname', 'working_directory', 'dimension', 'cuda', 'prof' example: set_from_key_value(key, value)

smooth([N])

allocate_arrays

export_3D_connections

fill

glue_blocks

nullify_boundary_lists

nullify_smooth_faces

plot_edges

plot_edges_XY

plot_edges_XZ

plot_edges_YZ

plot_module_edges

print_coordinates

print_extreme_values

redefine_ghosts

reset_coordinates

reset_edges

class g3d.mesh.modules.G3DMesh(*args: Any, **kwargs: Any)[source]

Bases: MeshModule

Attributes:
blocks
return:

coordinates
return:

data
return:

data_file
return:

edges
return:

n_blocks
return:

n_cells
return:

n_nodes
return:

n_smooth
return:

nk3D
return:

nodes
return:

smooth_faces
return:

tag

tag (string) used for identification

tags
return:

Methods

add_BC(bc, **kwargs)

add_Block(ni[, nj, nk])

add_Coord(c)

add_Edge(e)

add_IO(io, **kwargs)

add_Intf(faceA_def, faceB_def, **kwargs)

add_smooth_face(face_def)

add_smooth_face_glue(faceA_def, faceB_def)

add_tag(key, tag)

cell_get_block(kc)

cell_get_ijk(kc)

check_volumes()

circular_edge(c, ni, **kwargs)

copy(e)

copies data from specified entity input: entity example: copy(e)

copy_Face(faceA_def, faceB_def)

copy_X(im_to, l_to, im_from, l_from)

copy_XYZ(im_to, l_to, im_from, l_from)

copy_Y(im_to, l_to, im_from, l_from)

copy_Z(im_to, l_to, im_from, l_from)

export(*args, **kwargs)

exports mesh to file :param args: arguments (BinaryFormat), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE)

export_connections([bcf])

generate_mesh()

get_X(im[, lp])

get_XYZ(im[, lp])

get_Y(im[, lp])

get_Z(im[, lp])

get_extreme_coordinates()

get_x_min_x_max()

get_y_min_y_max()

get_z_min_z_max()

header(*args, **kwargs)

prints a header with specified information input: info optional input: dashes (default='='), scrw (default=80), number of blank lines after dashes n_space (default=1) example: header(info='header info')

hline(*args, **kwargs)

prints horizontal line optional input (kwargs): dashes (default='-'), scrw (default=80) example: hline(dashes='*', scrw=90)

import_mesh(*args, **kwargs)

imports mesh from file :param args: arguments (BinaryFormat, file base name (str)), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE), 'msh_file' -> filename, 'topo_file' -> filename

jobname_append(name)

extends jobname with the specified string input: name example: jobname_append(name)

node_get_block(kp)

node_get_ijk(kp)

populate_face_coordinate_placeholders(im, b)

print()

prints entity data

scale(sf)

set(*args, **kwargs)

sets code parameters according to specifications input: args, kwargs example: set(args, kwargs)

set_X(im, X[, lp])

set_XYZ(im, X, Y, Z[, lp])

set_Y(im, Y[, lp])

set_Z(im, Z[, lp])

set_from_key_value(key, value)

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: 'verbose', 'silent/quiet', 'jobname', 'working_directory', 'dimension', 'cuda', 'prof' example: set_from_key_value(key, value)

smooth([N])

allocate_arrays

export_3D_connections

fill

glue_blocks

nullify_boundary_lists

nullify_smooth_faces

plot_edges

plot_edges_XY

plot_edges_XZ

plot_edges_YZ

plot_module_edges

print_coordinates

print_extreme_values

redefine_ghosts

reset_coordinates

reset_edges

class g3d.mesh.modules.HumpModule(*args: Any, **kwargs: Any)[source]

Bases: MeshModule

Attributes:
blocks
return:

coordinates
return:

data
return:

data_file
return:

dxf_control
return:

dy_wall
return:

edges
return:

n_blocks
return:

n_cells
return:

n_control_lines
return:

n_nodes
return:

n_smooth
return:

ni
return:

nj
return:

nj_wall_offset
return:

nk
return:

nk3D
return:

nodes
return:

shape_control
return:

smooth_faces
return:

stretch_rate_x
return:

stretch_rate_y
return:

tag

tag (string) used for identification

tags
return:

top_spacing_factor
return:

x1
return:

x2
return:

x_control
return:

y1
return:

y2
return:

z1
return:

z2
return:

Methods

add_BC(bc, **kwargs)

add_Block(ni[, nj, nk])

add_Coord(c)

add_Edge(e)

add_IO(io, **kwargs)

add_Intf(faceA_def, faceB_def, **kwargs)

add_smooth_face(face_def)

add_smooth_face_glue(faceA_def, faceB_def)

add_tag(key, tag)

cell_get_block(kc)

cell_get_ijk(kc)

check_volumes()

circular_edge(c, ni, **kwargs)

copy(e)

copies data from specified entity input: entity example: copy(e)

copy_Face(faceA_def, faceB_def)

copy_X(im_to, l_to, im_from, l_from)

copy_XYZ(im_to, l_to, im_from, l_from)

copy_Y(im_to, l_to, im_from, l_from)

copy_Z(im_to, l_to, im_from, l_from)

export(*args, **kwargs)

exports mesh to file :param args: arguments (BinaryFormat), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE)

export_connections([bcf])

generate_mesh()

get_X(im[, lp])

get_XYZ(im[, lp])

get_Y(im[, lp])

get_Z(im[, lp])

get_extreme_coordinates()

get_x_min_x_max()

get_y_min_y_max()

get_z_min_z_max()

header(*args, **kwargs)

prints a header with specified information input: info optional input: dashes (default='='), scrw (default=80), number of blank lines after dashes n_space (default=1) example: header(info='header info')

hline(*args, **kwargs)

prints horizontal line optional input (kwargs): dashes (default='-'), scrw (default=80) example: hline(dashes='*', scrw=90)

import_mesh(*args, **kwargs)

imports mesh from file :param args: arguments (BinaryFormat, file base name (str)), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE), 'msh_file' -> filename, 'topo_file' -> filename

jobname_append(name)

extends jobname with the specified string input: name example: jobname_append(name)

node_get_block(kp)

node_get_ijk(kp)

populate_face_coordinate_placeholders(im, b)

print()

prints entity data

scale(sf)

set(*args, **kwargs)

sets code parameters according to specifications input: args, kwargs example: set(args, kwargs)

set_X(im, X[, lp])

set_XYZ(im, X, Y, Z[, lp])

set_Y(im, Y[, lp])

set_Z(im, Z[, lp])

set_from_key_value(key, value)

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: 'verbose', 'silent/quiet', 'jobname', 'working_directory', 'dimension', 'cuda', 'prof' example: set_from_key_value(key, value)

smooth([N])

allocate_arrays

export_3D_connections

fill

glue_blocks

nullify_boundary_lists

nullify_smooth_faces

plot_edges

plot_edges_XY

plot_edges_XZ

plot_edges_YZ

plot_module_edges

print_coordinates

print_extreme_values

redefine_ghosts

reset_coordinates

reset_edges

property dxf_control: float

return:

property dy_wall: float

return:

property n_control_lines: int

return:

property ni: int

return:

property nj: int

return:

property nj_wall_offset: int

return:

property nk: int

return:

set_from_key_value(key: str, value: Any) → bool[source]

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: ‘verbose’, ‘silent/quiet’, ‘jobname’, ‘working_directory’, ‘dimension’, ‘cuda’, ‘prof’ example: set_from_key_value(key, value)

property shape_control: float

return:

property stretch_rate_x: float

return:

property stretch_rate_y: float

return:

property top_spacing_factor: float

return:

property x1: float

return:

property x2: float

return:

property x_control: float

return:

property y1: float

return:

property y2: float

return:

property z1: float

return:

property z2: float

return:

class g3d.mesh.modules.MeshModule(*args: Any, **kwargs: Any)[source]

Bases: Grid

Attributes:
blocks
return:

coordinates
return:

data
return:

data_file
return:

edges
return:

n_blocks
return:

n_cells
return:

n_nodes
return:

n_smooth
return:

nk3D
return:

nodes
return:

smooth_faces
return:

tag

tag (string) used for identification

tags
return:

Methods

add_BC(bc, **kwargs)

add_Block(ni[, nj, nk])

add_Coord(c)

add_Edge(e)

add_IO(io, **kwargs)

add_Intf(faceA_def, faceB_def, **kwargs)

add_smooth_face(face_def)

add_smooth_face_glue(faceA_def, faceB_def)

add_tag(key, tag)

cell_get_block(kc)

cell_get_ijk(kc)

check_volumes()

circular_edge(c, ni, **kwargs)

copy(e)

copies data from specified entity input: entity example: copy(e)

copy_Face(faceA_def, faceB_def)

copy_X(im_to, l_to, im_from, l_from)

copy_XYZ(im_to, l_to, im_from, l_from)

copy_Y(im_to, l_to, im_from, l_from)

copy_Z(im_to, l_to, im_from, l_from)

export(*args, **kwargs)

exports mesh to file :param args: arguments (BinaryFormat), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE)

export_connections([bcf])

generate_mesh()

get_X(im[, lp])

get_XYZ(im[, lp])

get_Y(im[, lp])

get_Z(im[, lp])

get_extreme_coordinates()

get_x_min_x_max()

get_y_min_y_max()

get_z_min_z_max()

header(*args, **kwargs)

prints a header with specified information input: info optional input: dashes (default='='), scrw (default=80), number of blank lines after dashes n_space (default=1) example: header(info='header info')

hline(*args, **kwargs)

prints horizontal line optional input (kwargs): dashes (default='-'), scrw (default=80) example: hline(dashes='*', scrw=90)

import_mesh(*args, **kwargs)

imports mesh from file :param args: arguments (BinaryFormat, file base name (str)), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE), 'msh_file' -> filename, 'topo_file' -> filename

jobname_append(name)

extends jobname with the specified string input: name example: jobname_append(name)

node_get_block(kp)

node_get_ijk(kp)

populate_face_coordinate_placeholders(im, b)

print()

prints entity data

scale(sf)

set(*args, **kwargs)

sets code parameters according to specifications input: args, kwargs example: set(args, kwargs)

set_X(im, X[, lp])

set_XYZ(im, X, Y, Z[, lp])

set_Y(im, Y[, lp])

set_Z(im, Z[, lp])

set_from_key_value(key, value)

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: 'verbose', 'silent/quiet', 'jobname', 'working_directory', 'dimension', 'cuda', 'prof' example: set_from_key_value(key, value)

smooth([N])

allocate_arrays

export_3D_connections

fill

glue_blocks

nullify_boundary_lists

nullify_smooth_faces

plot_edges

plot_edges_XY

plot_edges_XZ

plot_edges_YZ

plot_module_edges

print_coordinates

print_extreme_values

redefine_ghosts

reset_coordinates

reset_edges

add_Coord(c: Coord) → None[source]
Parameters:

c

add_Edge(e: Edge) → None[source]
Parameters:

e

add_tag(key: str, tag: str) → None[source]
Parameters:
  • key

  • tag

static circular_edge(c: Coord, ni: int, **kwargs: Any) → Edge[source]
Parameters:
  • c

  • ni

  • kwargs

Returns:

property coordinates: list

return:

property data: list | ndarray

return:

property data_file: str

return:

property edges: list

return:

export_3D_connections() → None[source]
generate_mesh() → int[source]
Returns:

property n_smooth: int

return:

property nk3D: int

return:

plot_edges() → None[source]
plot_module_edges() → None[source]
print_coordinates() → None[source]
reset_coordinates() → None[source]
reset_edges() → None[source]
set_from_key_value(key: str, value: Any) → bool[source]

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: ‘verbose’, ‘silent/quiet’, ‘jobname’, ‘working_directory’, ‘dimension’, ‘cuda’, ‘prof’ example: set_from_key_value(key, value)

property smooth_faces: bool

return:

property tags: dict

return:

class g3d.mesh.modules.OGVModule(*args: Any, **kwargs: Any)[source]

Bases: MeshModule

Attributes:
blocks
return:

chord
return:

coordinates
return:

data
return:

data_file
return:

edges
return:

idx_le
return:

idx_ps_le
return:

idx_ps_te
return:

idx_ss_le
return:

idx_ss_te
return:

idx_te
return:

idx_x_max
return:

idx_x_min
return:

idx_y_max
return:

idx_y_min
return:

le
return:

leading_edge
return:

length
return:

n_blocks
return:

n_cells
return:

n_nodes
return:

n_smooth
return:

ni_chord
return:

ni_inlet_block
return:

ni_le
return:

ni_outlet_block
return:

ni_ps
return:

ni_ss
return:

ni_te
return:

nj_o_grid
return:

nj_pitch
return:

nk3D
return:

nodes
return:

o_grid_offset
return:

ogv_edge
return:

ogv_edge_offset
return:

pitch
return:

pressure_side_edge
return:

ps_le
return:

ps_te
return:

smooth_faces
return:

span
return:

ss_le
return:

ss_te
return:

stretch_rate_x
return:

suction_side_edge
return:

tag

tag (string) used for identification

tags
return:

te
return:

trailing_edge
return:

wall_resolution
return:

x_in
return:

x_max
return:

x_min
return:

x_out
return:

y_max
return:

y_min
return:

Methods

add_BC(bc, **kwargs)

add_Block(ni[, nj, nk])

add_Coord(c)

add_Edge(e)

add_IO(io, **kwargs)

add_Intf(faceA_def, faceB_def, **kwargs)

add_smooth_face(face_def)

add_smooth_face_glue(faceA_def, faceB_def)

add_tag(key, tag)

cell_get_block(kc)

cell_get_ijk(kc)

check_volumes()

circular_edge(c, ni, **kwargs)

copy(e)

copies data from specified entity input: entity example: copy(e)

copy_Face(faceA_def, faceB_def)

copy_X(im_to, l_to, im_from, l_from)

copy_XYZ(im_to, l_to, im_from, l_from)

copy_Y(im_to, l_to, im_from, l_from)

copy_Z(im_to, l_to, im_from, l_from)

export(*args, **kwargs)

exports mesh to file :param args: arguments (BinaryFormat), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE)

export_connections([bcf])

generate_mesh()

get_X(im[, lp])

get_XYZ(im[, lp])

get_Y(im[, lp])

get_Z(im[, lp])

get_extreme_coordinates()

get_x_min_x_max()

get_y_min_y_max()

get_z_min_z_max()

header(*args, **kwargs)

prints a header with specified information input: info optional input: dashes (default='='), scrw (default=80), number of blank lines after dashes n_space (default=1) example: header(info='header info')

hline(*args, **kwargs)

prints horizontal line optional input (kwargs): dashes (default='-'), scrw (default=80) example: hline(dashes='*', scrw=90)

import_mesh(*args, **kwargs)

imports mesh from file :param args: arguments (BinaryFormat, file base name (str)), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE), 'msh_file' -> filename, 'topo_file' -> filename

jobname_append(name)

extends jobname with the specified string input: name example: jobname_append(name)

node_get_block(kp)

node_get_ijk(kp)

populate_face_coordinate_placeholders(im, b)

print()

prints entity data

scale(sf)

set(*args, **kwargs)

sets code parameters according to specifications input: args, kwargs example: set(args, kwargs)

set_X(im, X[, lp])

set_XYZ(im, X, Y, Z[, lp])

set_Y(im, Y[, lp])

set_Z(im, Z[, lp])

set_from_key_value(key, value)

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: 'verbose', 'silent/quiet', 'jobname', 'working_directory', 'dimension', 'cuda', 'prof' example: set_from_key_value(key, value)

smooth([N])

allocate_arrays

export_3D_connections

fill

glue_blocks

nullify_boundary_lists

nullify_smooth_faces

plot_edges

plot_edges_XY

plot_edges_XZ

plot_edges_YZ

plot_module_edges

print_coordinates

print_extreme_values

redefine_ghosts

reset_coordinates

reset_edges

property chord: float

return:

export_3D_connections() → None[source]
property idx_le: int

return:

property idx_ps_le: int

return:

property idx_ps_te: int

return:

property idx_ss_le: int

return:

property idx_ss_te: int

return:

property idx_te: int

return:

property idx_x_max: int

return:

property idx_x_min: int

return:

property idx_y_max: int

return:

property idx_y_min: int

return:

property le: Coord

return:

property leading_edge: Edge

return:

property length: float

return:

property ni_chord: int

return:

property ni_inlet_block: int

return:

property ni_le: int

return:

property ni_outlet_block: int

return:

property ni_ps: int

return:

property ni_ss: int

return:

property ni_te: int

return:

property nj_o_grid: int

return:

property nj_pitch: int

return:

property o_grid_offset: float

return:

property ogv_edge: Edge

return:

property ogv_edge_offset: Edge

return:

property pitch: float

return:

property pressure_side_edge: Edge

return:

property ps_le: Coord

return:

property ps_te: Coord

return:

set_from_key_value(key: str, value: Any) → bool[source]

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: ‘verbose’, ‘silent/quiet’, ‘jobname’, ‘working_directory’, ‘dimension’, ‘cuda’, ‘prof’ example: set_from_key_value(key, value)

property span: float

return:

property ss_le: Coord

return:

property ss_te: Coord

return:

property stretch_rate_x: float

return:

property suction_side_edge: Edge

return:

property te: Coord

return:

property trailing_edge: Edge

return:

property wall_resolution: float

return:

property x_in: float

return:

property x_max: Coord

return:

property x_min: Coord

return:

property x_out: float

return:

property y_max: Coord

return:

property y_min: Coord

return:

class g3d.mesh.modules.SingleBlockCylinderModule(*args: Any, **kwargs: Any)[source]

Bases: BlockModule

Attributes:
blocks
return:

coordinates
return:

cylinder_length
return:

cylinder_radius
return:

data
return:

data_file
return:

do_not_smooth_o_grid
return:

dx_wall
return:

dy_wall
return:

dz_wall
return:

edges
return:

inner_wake_cell_size
return:

n_blocks
return:

n_cells
return:

n_cells_external
return:

n_cells_half_freestream
return:

n_cells_half_inlet
return:

n_cells_half_outlet
return:

n_cells_o_grid
return:

n_data_points
return:

n_nodes
return:

n_smooth
return:

ni
return:

nj
return:

nk
return:

nk3D
return:

nodes
return:

o_grid_radius
return:

o_grid_scale_factor
return:

o_grid_shape_factor
return:

o_grid_stretch_rate
return:

outer_box_size
return:

outer_wake_cell_size
return:

smooth_faces
return:

stretch_rate_x
return:

stretch_rate_y
return:

stretch_rate_z
return:

tag

tag (string) used for identification

tags
return:

wall_cell_height
return:

x1
return:

x2
return:

y1
return:

y2
return:

z1
return:

z2
return:

Methods

add_BC(bc, **kwargs)

add_Block(ni[, nj, nk])

add_Coord(c)

add_Edge(e)

add_IO(io, **kwargs)

add_Intf(faceA_def, faceB_def, **kwargs)

add_smooth_face(face_def)

add_smooth_face_glue(faceA_def, faceB_def)

add_tag(key, tag)

cell_get_block(kc)

cell_get_ijk(kc)

check_volumes()

circular_edge(c, ni, **kwargs)

copy(e)

copies data from specified entity input: entity example: copy(e)

copy_Face(faceA_def, faceB_def)

copy_X(im_to, l_to, im_from, l_from)

copy_XYZ(im_to, l_to, im_from, l_from)

copy_Y(im_to, l_to, im_from, l_from)

copy_Z(im_to, l_to, im_from, l_from)

export(*args, **kwargs)

exports mesh to file :param args: arguments (BinaryFormat), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE)

export_connections([bcf])

generate_mesh()

get_X(im[, lp])

get_XYZ(im[, lp])

get_Y(im[, lp])

get_Z(im[, lp])

get_extreme_coordinates()

get_x_min_x_max()

get_y_min_y_max()

get_z_min_z_max()

header(*args, **kwargs)

prints a header with specified information input: info optional input: dashes (default='='), scrw (default=80), number of blank lines after dashes n_space (default=1) example: header(info='header info')

hline(*args, **kwargs)

prints horizontal line optional input (kwargs): dashes (default='-'), scrw (default=80) example: hline(dashes='*', scrw=90)

import_mesh(*args, **kwargs)

imports mesh from file :param args: arguments (BinaryFormat, file base name (str)), optional :param kwargs: keyword value pairs, optional valid key values: 'format' binary_format (defaults to BinaryFormat.NATIVE), 'msh_file' -> filename, 'topo_file' -> filename

jobname_append(name)

extends jobname with the specified string input: name example: jobname_append(name)

node_get_block(kp)

node_get_ijk(kp)

populate_face_coordinate_placeholders(im, b)

print()

prints entity data

scale(sf)

set(*args, **kwargs)

sets code parameters according to specifications input: args, kwargs example: set(args, kwargs)

set_X(im, X[, lp])

set_XYZ(im, X, Y, Z[, lp])

set_Y(im, Y[, lp])

set_Z(im, Z[, lp])

set_from_key_value(key, value)

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: 'verbose', 'silent/quiet', 'jobname', 'working_directory', 'dimension', 'cuda', 'prof' example: set_from_key_value(key, value)

smooth([N])

allocate_arrays

export_3D_connections

fill

glue_blocks

nullify_boundary_lists

nullify_smooth_faces

plot_edges

plot_edges_XY

plot_edges_XZ

plot_edges_YZ

plot_module_edges

print_coordinates

print_extreme_values

redefine_ghosts

reset_coordinates

reset_edges

property cylinder_length: float

return:

property cylinder_radius: float

return:

property do_not_smooth_o_grid: bool

return:

property inner_wake_cell_size: float

return:

property n_cells_external: int

return:

property n_cells_half_freestream: int

return:

property n_cells_half_inlet: int

return:

property n_cells_half_outlet: int

return:

property n_cells_o_grid: int

return:

property n_data_points: int

return:

property o_grid_radius: float

return:

property o_grid_scale_factor: float

return:

property o_grid_shape_factor: float

return:

property o_grid_stretch_rate: float

return:

property outer_box_size: float

return:

property outer_wake_cell_size: float

return:

set_from_key_value(key: str, value: Any) → bool[source]

sets code parameters from specified key => value data input: key, value valid keys for G3DCode base class: ‘verbose’, ‘silent/quiet’, ‘jobname’, ‘working_directory’, ‘dimension’, ‘cuda’, ‘prof’ example: set_from_key_value(key, value)

property wall_cell_height: float

return: