| Type | Visibility | Attributes | Name | Initial | |||
|---|---|---|---|---|---|---|---|
| type(Scalar2D), | public | :: | J | Default-initialized so a freshly allocated object can be distinguished from an initialized one (the controller uses nElem == 0 to decide Init versus Resize). |
|||
| type(Tensor2D), | public | :: | dsdx | ||||
| type(Tensor2D), | public | :: | dxds | ||||
| type(Lagrange), | public, | pointer | :: | meshToModel | => | null() | |
| integer, | public | :: | nElem | = | 0 | Cached scratch for GenerateFromMesh (AMR Stage 6c). Both were previously constructed and destroyed on every call, which the adaptive loop makes once per epoch: |
|
| type(Vector2D), | public | :: | nHat | ||||
| type(Scalar2D), | public | :: | nScale | ||||
| integer, | public | :: | scratchNGeo | = | -1 | ||
| logical, | public | :: | scratchReady | = | .false. | ||
| type(Vector2D), | public | :: | x | ||||
| type(Vector2D), | public | :: | xMesh |
| procedure, private :: CalculateContravariantBasis => CalculateContravariantBasis_SEMQuad | |
| procedure, public :: CalculateMetricTerms => CalculateMetricTerms_SEMQuad | |
| procedure, public :: CopyElements => CopyElements_SEMQuad | |
| procedure, private :: EnsureScratch => EnsureScratch_SEMQuad | |
| procedure, public :: Free => Free_SEMQuad | |
| procedure, public :: GenerateFromMesh => GenerateFromMesh_SEMQuad | |
| procedure, public :: GenerateFromNodeCoords => GenerateFromNodeCoords_SEMQuad | |
| procedure, public :: Init => Init_SEMQuad | |
| procedure, public :: Resize => Resize_SEMQuad | |
| procedure, public :: UploadGeometry => UploadGeometry_SEMQuad | |
| procedure, public :: WriteTecplot => WriteTecplot_SEMQuad |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(SEMQuad), | intent(inout) | :: | myGeom |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(SEMQuad), | intent(inout) | :: | myGeom |
Copy whole-element geometry blocks from src into myGeom: element srcIdx(k) of src becomes element dstIdx(k) of myGeom, for k = 1..n (AMR Stage 6c).
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(SEMQuad), | intent(inout) | :: | myGeom | |||
| type(SEMQuad), | intent(in) | :: | src | |||
| integer, | intent(in) | :: | srcIdx(:) | |||
| integer, | intent(in) | :: | dstIdx(:) | |||
| integer, | intent(in) | :: | n |
Prepare the cached GenerateFromMesh scratch for a mesh with nGeo/quadrature and nElem elements (AMR Stage 6c). The nGeo -> N interpolant is built once and reused; the node coordinate staging is resized, so an adapting run stops rebuilding either one per epoch.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(SEMQuad), | intent(inout) | :: | myGeom | |||
| integer, | intent(in) | :: | nGeo | |||
| integer, | intent(in) | :: | quadrature | |||
| integer, | intent(in) | :: | nElem |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(SEMQuad), | intent(inout) | :: | myGeom |
Generate geometry for nElem elements directly from their mesh node coordinates (AMR Stage 6c). GenerateFromMesh is a thin wrapper over this.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(SEMQuad), | intent(inout) | :: | myGeom | |||
| real(kind=prec), | intent(in) | :: | nodeCoords(1:2,1:nGeo+1,1:nGeo+1,1:nElem) | |||
| integer, | intent(in) | :: | nGeo | |||
| integer, | intent(in) | :: | quadrature | |||
| integer, | intent(in) | :: | nElem |
Rebind a live geometry to a new element count, reusing storage where it fits (AMR Stage 6c). This replaces the Free + Init cycle the adaptive loop performed on a freshly allocated SEMQuad every epoch, which threw away exactly the amortization Stage 6b introduced: each member Free released its pools and device buffers, and each Init reallocated, zeroed, rebuilt metadata and equation parsers, and uploaded the zeros.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(SEMQuad), | intent(inout) | :: | myGeom | |||
| type(Lagrange), | intent(in), | pointer | :: | interp | ||
| integer, | intent(in) | :: | nElem |
Push the geometry the solver kernels read to the device. Mirrors the uploads that GenerateFromMesh's own path performs, for use when geometry was assembled by element copy rather than generated (AMR Stage 6c).
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(SEMQuad), | intent(inout) | :: | myGeom |
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(SEMQuad), | intent(inout) | :: | this | |||
| character, | intent(in) | :: | filename |