Returns the nGeo+1 one-dimensional geometry node positions, in [-1,1], of a mesh
whose node coordinates are sampled on quadrature points. These are the points
GenerateFromMesh interpolates the node coordinates from (see Lagrange_t%Init), so
a coordinate sampled here is reproduced exactly by the geometry interpolant.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| integer, | intent(in) | :: | nGeo | |||
| integer, | intent(in) | :: | quadrature | |||
| real(kind=prec), | intent(out) | :: | nodes(1:nGeo+1) |
subroutine GeometryNodes1D(nGeo,quadrature,nodes)
!! Returns the nGeo+1 one-dimensional geometry node positions, in [-1,1], of a mesh
!! whose node coordinates are sampled on `quadrature` points. These are the points
!! GenerateFromMesh interpolates the node coordinates from (see Lagrange_t%Init), so
!! a coordinate sampled here is reproduced exactly by the geometry interpolant.
implicit none
integer,intent(in) :: nGeo
integer,intent(in) :: quadrature
real(prec),intent(out) :: nodes(1:nGeo+1)
! Local
real(prec) :: weights(1:nGeo+1)
if(quadrature == GAUSS .or. quadrature == GAUSS_LOBATTO) then
call LegendreQuadrature(nGeo,nodes,weights,quadrature)
elseif(quadrature == CHEBYSHEV_GAUSS .or. quadrature == CHEBYSHEV_GAUSS_LOBATTO) then
call ChebyshevQuadrature(nGeo,nodes,weights,quadrature)
elseif(quadrature == UNIFORM) then
nodes = UniformPoints(-1.0_prec,1.0_prec,0,nGeo)
else
error stop "GeometryNodes1D : unrecognized mesh quadrature type"
endif
endsubroutine GeometryNodes1D