The Open FUSION Toolkit 1.0.0-8905cc5
Modeling tools for plasma and fusion research and engineering
Loading...
Searching...
No Matches
Data Types | Functions/Subroutines | Variables
oft_mesh_cubit Module Reference

Detailed Description

Mesh handling for CUBIT meshes.

Author
Chris Hansen
Date
July 2012

Data Types

type  exodus_cadlink
 T3D CAD linkage structure. More...
 
type  exodus_curve
 T3D CAD boundary structure. More...
 
type  exodus_surf
 T3D CAD boundary structure. More...
 

Functions/Subroutines

subroutine, public cubit_finalize_setup
 Finalize setup/load-in of CUBIT mesh and destroy temporaries created for grid construction (eg. high-order input nodes, in-memory data)
 
subroutine cubit_ho_tor (pts, wts, n, rmin, pt)
 
subroutine, public cubit_read_nodesets (nsets, cubit_filename)
 Needs Docs.
 
subroutine, public cubit_read_sidesets (ssets, cubit_filename)
 Needs Docs.
 
subroutine, public mesh_cubit_add_quad (mg_mesh)
 Add quadratic mesh node points using CAD model.
 
subroutine, public mesh_cubit_cadlink (mesh)
 Link OpenNURBS CAD objects to Exodus mesh entities for use in refinement.
 
subroutine mesh_cubit_error (status)
 Catch NETCDF errors.
 
subroutine mesh_cubit_geom
 Load and initialize OpenNURBS geometry for current Exodus mesh.
 
subroutine, public mesh_cubit_hobase (self)
 Add quadratic mesh node points from high order import.
 
subroutine mesh_cubit_hobase_hex (self)
 Add quadratic mesh node points from HEX27 import.
 
subroutine mesh_cubit_hobase_quad (self)
 Add quadratic mesh node points from QUAD9 import.
 
subroutine mesh_cubit_hobase_tet (self)
 Add quadratic mesh node points from TETRA10 import.
 
subroutine mesh_cubit_hobase_tri (self)
 Add quadratic mesh node points from TRI6 import.
 
subroutine, public mesh_cubit_load (mg_mesh)
 Read in Exodus mesh and geometry information.
 
subroutine mesh_cubit_read_surface
 Read in Exodus surface mesh.
 
subroutine, public mesh_cubit_reffix (mg_mesh)
 Adjust points to CAD boundary and propogate CAD linkage.
 
subroutine mesh_cubit_reflect (mesh, tol)
 Reflect an exodus mesh and CAD model across the xy-plane.
 
subroutine, public mesh_cubit_set_periodic (mesh)
 Needs docs.
 
subroutine, public mesh_cubit_test_edge (i)
 Add quadratic mesh node points using CAD model.
 
subroutine, public smesh_cubit_load (mg_mesh)
 Needs Docs.
 

Variables

type(exodus_cadlink), pointer cad_link => NULL()
 Linkage of mesh to CAD geometry.
 
integer(i4), parameter cubit_soffset =1E4
 
real(r4cubit_version = 0.
 
integer(i4), parameter ex_topc_len =5
 
integer(i4), parameter ex_tops_len =5
 
integer(i4), dimension(2, 12), parameter exodus_hex_emap = RESHAPE((/1,2, 2,3, 3,4, 1,4, 1,5, 2,6, 3,7, 4,8, 5,6, 6,7, 7,8, 5,8/), (/2,12/))
 
integer(i4), dimension(4, 6), parameter exodus_hex_fmap = RESHAPE((/1,2,3,4, 5,6,7,8, 1,4,8,5, 2,3,7,6, 1,2,6,5, 3,4,8,7/), (/4,6/))
 
integer(i4), dimension(2, 4), parameter exodus_quad_emap = RESHAPE([1,2, 2,3, 3,4, 4,1], [2,4])
 
integer(i4), parameter exodus_string_len =33
 
integer(i4), dimension(2, 6), parameter exodus_tet_emap = RESHAPE((/1,2, 2,3, 3,1, 1,4, 2,4, 3,4/), (/2,6/))
 
integer(i4), dimension(2, 3), parameter exodus_tri_emap = RESHAPE([1,2, 2,3, 3,1], [2,3])
 
character(len=oft_path_slen) filename = 'none'
 Name of Cubit input file for mesh.
 
logical have_ho = .FALSE.
 
character(len=oft_path_slen), public inpname = 'none'
 Name of Cubit input file for geometry (Used to retrieve CAD objects)
 
integer(i4), dimension(:,:), allocatable lc_ho
 
logical lf_file = .TRUE.
 Large format file flag.
 
integer(i4), parameter, public mesh_cubit_id = 2
 
type(exodus_cadlink), dimension(:), pointer ml_cad_link => NULL()
 ML CAD linkage.
 
type(exodus_curve), dimension(:), pointer model_curves => NULL()
 List of model curves.
 
type(exodus_surf), dimension(:), pointer model_surfaces => NULL()
 List of model surfaces.
 
integer(i4nblks = 0
 
integer(i4ncid = 0
 
integer(i4ngmc = 0
 Number of geometry model curves.
 
integer(i4ngms = 0
 Number of geometry model surfaces.
 
integer(i4ngwc = 0
 Number of geometry wireframe curves.
 
integer(i4ngws = 0
 Number of geometry wireframe surfaces.
 
integer(i4np_ho = 0
 
integer(i4np_per = 0
 
integer(i4nregions = 0
 
integer(i4), dimension(:), allocatable per_nodes
 
integer(i4per_ns = -1
 Integer index of periodic nodeset.
 
real(r8), dimension(:,:), allocatable r_ho
 
logical reflect = .FALSE.
 Logical flag for mesh reflection (z-direction)
 
logical tor_mesh = .FALSE.
 Curve grid to toroidal shaping.
 
real(r8tor_rmin = 0.d0
 
type(nurbs_curve), dimension(:), pointer wf_curves => NULL()
 List of CAD wireframe curves.
 
type(nurbs_surf), dimension(:), pointer wf_surfs => NULL()
 List of CAD wireframe surfaces.
 
real(r8zstretch = 1.d0
 Scale for z-coordinates (useful for cylindrical pinch studies)
 

Function/Subroutine Documentation

◆ cubit_finalize_setup()

subroutine, public cubit_finalize_setup

Finalize setup/load-in of CUBIT mesh and destroy temporaries created for grid construction (eg. high-order input nodes, in-memory data)

◆ cubit_ho_tor()

subroutine cubit_ho_tor ( real(r8), dimension(3,n), intent(in)  pts,
real(r8), dimension(n), intent(in)  wts,
integer(i4), intent(in)  n,
real(r8), intent(in)  rmin,
real(r8), dimension(3), intent(inout)  pt 
)
private

◆ cubit_read_nodesets()

subroutine, public cubit_read_nodesets ( type(oft_1d_int), dimension(:), intent(inout), pointer  nsets,
character(len=oft_path_slen), intent(in), optional  cubit_filename 
)

Needs Docs.

◆ cubit_read_sidesets()

subroutine, public cubit_read_sidesets ( type(oft_1d_int), dimension(:), intent(inout), pointer  ssets,
character(len=oft_path_slen), intent(in), optional  cubit_filename 
)

Needs Docs.

◆ mesh_cubit_add_quad()

subroutine, public mesh_cubit_add_quad ( type(multigrid_mesh), intent(inout)  mg_mesh)

Add quadratic mesh node points using CAD model.

◆ mesh_cubit_cadlink()

subroutine, public mesh_cubit_cadlink ( class(oft_amesh), intent(inout)  mesh)

Link OpenNURBS CAD objects to Exodus mesh entities for use in refinement.

  • Map Exodus surface mesh to CAD objects using name attributes

◆ mesh_cubit_error()

subroutine mesh_cubit_error ( integer(i4), intent(in)  status)
private

Catch NETCDF errors.

◆ mesh_cubit_geom()

subroutine mesh_cubit_geom
private

Load and initialize OpenNURBS geometry for current Exodus mesh.

  • Initialize OpenNURBS library
  • Construct FORTRAN objects for each CAD object

◆ mesh_cubit_hobase()

subroutine, public mesh_cubit_hobase ( class(oft_amesh), intent(inout)  self)

Add quadratic mesh node points from high order import.

◆ mesh_cubit_hobase_hex()

subroutine mesh_cubit_hobase_hex ( class(oft_mesh), intent(inout)  self)
private

Add quadratic mesh node points from HEX27 import.

◆ mesh_cubit_hobase_quad()

subroutine mesh_cubit_hobase_quad ( class(oft_bmesh), intent(inout)  self)
private

Add quadratic mesh node points from QUAD9 import.

◆ mesh_cubit_hobase_tet()

subroutine mesh_cubit_hobase_tet ( class(oft_mesh), intent(inout)  self)
private

Add quadratic mesh node points from TETRA10 import.

◆ mesh_cubit_hobase_tri()

subroutine mesh_cubit_hobase_tri ( class(oft_bmesh), intent(inout)  self)
private

Add quadratic mesh node points from TRI6 import.

◆ mesh_cubit_load()

subroutine, public mesh_cubit_load ( type(multigrid_mesh), intent(inout)  mg_mesh)

Read in Exodus mesh and geometry information.

  • Read in Cubit options from input file
  • Read in mesh points and cells
  • Read in surface mesh
  • Load and initialize OpenNURBS CAD representation

◆ mesh_cubit_read_surface()

subroutine mesh_cubit_read_surface
private

Read in Exodus surface mesh.

  • Surface mesh used for indexing CAD geometry

◆ mesh_cubit_reffix()

subroutine, public mesh_cubit_reffix ( type(multigrid_mesh), intent(inout)  mg_mesh)

Adjust points to CAD boundary and propogate CAD linkage.

◆ mesh_cubit_reflect()

subroutine mesh_cubit_reflect ( class(oft_amesh), intent(inout)  mesh,
real(r8), intent(in)  tol 
)
private

Reflect an exodus mesh and CAD model across the xy-plane.

Parameters
[in,out]meshMesh to reflect
[in]tolTolerance for marking point as on the reflection plane

◆ mesh_cubit_set_periodic()

subroutine, public mesh_cubit_set_periodic ( class(oft_mesh), intent(inout)  mesh)

Needs docs.

◆ mesh_cubit_test_edge()

subroutine, public mesh_cubit_test_edge ( integer(i4), intent(in)  i)

Add quadratic mesh node points using CAD model.

◆ smesh_cubit_load()

subroutine, public smesh_cubit_load ( type(multigrid_mesh), intent(inout)  mg_mesh)

Needs Docs.

Variable Documentation

◆ cad_link

type(exodus_cadlink), pointer cad_link => NULL()
private

Linkage of mesh to CAD geometry.

◆ cubit_soffset

integer(i4), parameter cubit_soffset =1E4
private

◆ cubit_version

real(r4) cubit_version = 0.
private

◆ ex_topc_len

integer(i4), parameter ex_topc_len =5
private

◆ ex_tops_len

integer(i4), parameter ex_tops_len =5
private

◆ exodus_hex_emap

integer(i4), dimension(2,12), parameter exodus_hex_emap = RESHAPE((/1,2, 2,3, 3,4, 1,4, 1,5, 2,6, 3,7, 4,8, 5,6, 6,7, 7,8, 5,8/), (/2,12/))
private

◆ exodus_hex_fmap

integer(i4), dimension(4,6), parameter exodus_hex_fmap = RESHAPE((/1,2,3,4, 5,6,7,8, 1,4,8,5, 2,3,7,6, 1,2,6,5, 3,4,8,7/), (/4,6/))
private

◆ exodus_quad_emap

integer(i4), dimension(2,4), parameter exodus_quad_emap = RESHAPE([1,2, 2,3, 3,4, 4,1], [2,4])
private

◆ exodus_string_len

integer(i4), parameter exodus_string_len =33
private

◆ exodus_tet_emap

integer(i4), dimension(2,6), parameter exodus_tet_emap = RESHAPE((/1,2, 2,3, 3,1, 1,4, 2,4, 3,4/), (/2,6/))
private

◆ exodus_tri_emap

integer(i4), dimension(2,3), parameter exodus_tri_emap = RESHAPE([1,2, 2,3, 3,1], [2,3])
private

◆ filename

character(len=oft_path_slen) filename = 'none'
private

Name of Cubit input file for mesh.

◆ have_ho

logical have_ho = .FALSE.
private

◆ inpname

character(len=oft_path_slen), public inpname = 'none'

Name of Cubit input file for geometry (Used to retrieve CAD objects)

◆ lc_ho

integer(i4), dimension(:,:), allocatable lc_ho
private

◆ lf_file

logical lf_file = .TRUE.
private

Large format file flag.

◆ mesh_cubit_id

integer(i4), parameter, public mesh_cubit_id = 2

◆ ml_cad_link

type(exodus_cadlink), dimension(:), pointer ml_cad_link => NULL()
private

ML CAD linkage.

◆ model_curves

type(exodus_curve), dimension(:), pointer model_curves => NULL()
private

List of model curves.

◆ model_surfaces

type(exodus_surf), dimension(:), pointer model_surfaces => NULL()
private

List of model surfaces.

◆ nblks

integer(i4) nblks = 0
private

◆ ncid

integer(i4) ncid = 0
private

◆ ngmc

integer(i4) ngmc = 0
private

Number of geometry model curves.

◆ ngms

integer(i4) ngms = 0
private

Number of geometry model surfaces.

◆ ngwc

integer(i4) ngwc = 0
private

Number of geometry wireframe curves.

◆ ngws

integer(i4) ngws = 0
private

Number of geometry wireframe surfaces.

◆ np_ho

integer(i4) np_ho = 0
private

◆ np_per

integer(i4) np_per = 0
private

◆ nregions

integer(i4) nregions = 0
private

◆ per_nodes

integer(i4), dimension(:), allocatable per_nodes
private

◆ per_ns

integer(i4) per_ns = -1
private

Integer index of periodic nodeset.

◆ r_ho

real(r8), dimension(:,:), allocatable r_ho
private

◆ reflect

logical reflect = .FALSE.
private

Logical flag for mesh reflection (z-direction)

◆ tor_mesh

logical tor_mesh = .FALSE.
private

Curve grid to toroidal shaping.

◆ tor_rmin

real(r8) tor_rmin = 0.d0
private

◆ wf_curves

type(nurbs_curve), dimension(:), pointer wf_curves => NULL()
private

List of CAD wireframe curves.

◆ wf_surfs

type(nurbs_surf), dimension(:), pointer wf_surfs => NULL()
private

List of CAD wireframe surfaces.

◆ zstretch

real(r8) zstretch = 1.d0
private

Scale for z-coordinates (useful for cylindrical pinch studies)