A module to provide informations on vertex property for elements.
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
integer, | private, | parameter, dimension( 5, 20 ) | :: | vrtxMap | = | reshape((/0, 0, 0, 1, qBSW, 1, 0, 0, 1, qBSE, 0, 0, 1, 1, qTSW, 1, 0, 1, 1, qTSE, 0, 1, 0, 1, qBNW, 1, 1, 0, 1, qBNE, 0, 1, 1, 1, qTNW, 1, 1, 1, 1, qTNE, 1, 0, 0, 1, q_BS, 0, 0, 1, 1, q_SW, 2, 0, 1, 1, q_SE, 1, 0, 2, 1, q_TS, 0, 1, 0, 1, q_BW, 0, 1, 2, 1, q_TW, 2, 1, 0, 1, q_BE, 2, 1, 2, 1, q_TE, 1, 2, 0, 1, q_BN, 0, 2, 1, 1, q_NW, 2, 2, 1, 1, q_NE, 1, 2, 2, 1, q_TN/), (/5, 20/)) |
Datatype for the vrtx dependend information. A dynamic array and a growing array are 'coupled'. The comparison between the real coordinates is shifted to the integer comparison of the dynamic array. The size of the two arrays are the same. Additionally a map of the 8 vertices for each element to the global index is stored.
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
integer, | private | :: | nVertices | total number of vertices |
|||
type(grw_real2darray_type), | private | :: | coord | growing array to store the coordinates |
|||
integer, | private, | allocatable | :: | map2global(:,:) | map of vertices for each element to global index vrtx_index_map(nelems, 8 vertices) |
||
integer, | private | :: | maxVertices | simulation time that coordinate info belongs to max number of vertices |
|||
logical, | private, | allocatable | :: | refine(:) | array of elements with qValues |
This subroutine calculates the vertex coordinate for a given element depending on the treeID, the global tree, the q-Value and iVrtx
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer(kind=long_k), | intent(in) | :: | treeID | |||
type(treelmesh_type), | intent(in) | :: | tree | |||
real(kind=rk), | intent(in) | :: | qVal | |||
integer, | intent(in) | :: | iVrtx |
This function detects the first position of an integer value of kind long_k in an array. When there is no match the return value is 0.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer(kind=long_k), | intent(in) | :: | long | |||
integer(kind=long_k), | intent(in) | :: | array(:) |
Run over all 8 vertices for each element in the treeID list, calculate its coordinates and add its position to the map.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(treelmesh_type), | intent(in) | :: | tree | fluid mesh |
||
type(tem_vrtx_type), | intent(inout) | :: | vrtx | Vertex data |
||
type(tem_subTree_type), | intent(in), | optional | :: | subTree | optional subTree information |
|
type(tem_BC_prop_type), | intent(in), | optional | :: | boundary | boundary information incl. q-Values |
|
logical, | intent(in), | optional | :: | useQVal | use the qValue information? |
Clean up allocated memory in vrtx structure
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_vrtx_type), | intent(inout) | :: | vrtx |
Run over all 8 vertices for each element in the treeID list, calculate its coordinates and add its position to the map.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(treelmesh_type), | intent(in) | :: | tree | fluid mesh |
||
type(tem_vrtx_type), | intent(inout) | :: | vrtx | Vertex data |
||
type(tem_subTree_type), | intent(in), | optional | :: | subTree | optional subTree information |
|
integer(kind=long_k), | intent(out), | allocatable | :: | vrtxTreeID(:) | boundary information incl. q-Values |
This subroutine takes the sorted list as an input and unifies its entries the result is used to create a unique array of vertex coordinates and a map for the 8 vertices of each element.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer(kind=long_k), | intent(inout), | allocatable | :: | inList(:) | ||
integer(kind=long_k), | intent(inout), | allocatable | :: | origList(:) | ||
type(grw_real2darray_type) | :: | coord | ||||
integer, | intent(inout), | allocatable | :: | map(:,:) | ||
type(treelmesh_type), | intent(in) | :: | tree | |||
integer, | intent(in) | :: | nElems | |||
integer, | intent(in) | :: | nUnique | number of unique vertices (from q-Values) |
||
logical, | intent(in) | :: | refine(:) |
Quicksort for long integer kinds.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer(kind=long_k), | intent(inout) | :: | list(:) | list to be sorted |
This subroutine partitions the given list for the quicksort algorithm
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
integer(kind=long_k), | intent(inout) | :: | list(:) | list to be partitioned |
||
integer, | intent(out) | :: | marker | marker where the list is partitioned |
Invert a given array 1 2 3 4 5 -> 5 4 3 2 1
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=rk), | intent(inout) | :: | me(:,:) | array to invert |
||
integer, | intent(in) | :: | nElems | number of elements in the array |
Initialize the vertex property headers.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_vrtx_type) | :: | vrtx | vertex type |