The polynomial projection describes the change from modal to nodal representation and vice-versa.
The method to be used for this transformation is configured in a table that
contains the kind
of transformation and then further options to the
transformation.
There are three kinds of transformation available:
By default the nodal representation uses as many nodes as there are modes
in the modal representation. This can be changed with the factor
setting.
There will factor
times number of modes nodes used in the transformation.
This oversampling allows for dealiasing of the nodal representation.
A different set of points will be used depending on the kind of
transformation to be used:
If the Chebyshev nodes are used for the nodal representation, the interval
boundaries can be included by setting lobattoPoints=true
. In this case
there will also be at least one point more be used in the nodal
representation than there are modes in the Legendre series.
If FPT is configured but the executable is not linked against the FFTW, there will be a warning, and the simulation uses the L2P method instead. The L2P method is also the default when no kind is provided at all.
For further options of the individual projection kinds, see their respective descriptions:
A minimalistic configuration for the projection method looks as follows:
projection = {
kind = 'l2p',
factor = 1.5
}
The name of the table (here projection
) is arbitrary and defined by the
application.
An application may load multiple projection definitions with differing names.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(ply_poly_project_type), | intent(out) | :: | left | fpt to copy to |
||
type(ply_poly_project_type), | intent(in) | :: | right | fpt to copy from |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(ply_prj_body_type), | intent(out) | :: | left | |||
type(ply_prj_body_type), | intent(in) | :: | right |
Convert nDoF modes to nodal values.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(ply_poly_project_type), | intent(inout) | :: | me | |||
integer, | intent(in) | :: | dim | |||
integer, | intent(in) | :: | nVars | The number of variables to project. If a variable consists of more than one component, the number of components has to be passed. If there are more than one variable, the sum of all components has to be passed (e.g. 6 when there are two three-dimensional vectors). |
||
real(kind=rk), | intent(inout) | :: | modal_data(:,:) | |||
real(kind=rk), | intent(inout) | :: | nodal_data(:,:) |
Convert nodal values to nDoFs modes.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(ply_poly_project_type), | intent(inout) | :: | me | |||
integer, | intent(in) | :: | dim | |||
integer, | intent(in) | :: | nVars | |||
real(kind=rk), | intent(inout) | :: | nodal_data(:,:) | |||
real(kind=rk), | intent(inout) | :: | modal_data(:,:) |
Additional data, required for the projection.
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
type(ply_legFpt_type), | private | :: | fpt | The fast polynomial transformation which will be used in case of nonlinear equations. It is used if fpt is choses as projection method in the lua file |
|||
type(ply_fxt_type), | private | :: | fxt | The Legendre Polynomial type for the Fast Orthogonal Function Transform via fxtpack. It is used if 'fxt' is chosen as projection method in the lua file |
|||
type(ply_l2p_type), | private | :: | l2p | Projection method which cam be used for transfoamtion from modal to nodal space and vice versa. It is used if 'l2p' is chosen as projection method in the lua file |
|||
real(kind=rk), | private, | allocatable | :: | nodes(:,:) | Volume quadrature points in the reference element |
||
type(ply_faceNodes_type), | private, | allocatable | :: | faces(:,:) | Facial quadrature nodes (reference element) for all three spatial direction and left and right face. These points are necessary to transfer boundary conditions given in physical space to modal space by projection (l2p or fpt) |
||
integer, | private | :: | nQuadPoints | quadrature points including oversampling factor |
|||
integer, | private | :: | ndofs | degree of freedom of the scheme depending on maxPolyDegree |
|||
integer, | private | :: | oversamp_dofs | ||||
integer, | private | :: | min_dofs |
Projection definition.
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
integer, | private | :: | basisType | Polynomial basis type. |
|||
character(len=labelLen), | private | :: | kind | Kind of projection. Currently available: - 'l2p', L2-Projection - 'fpt', Fast Polynomial Transformation. Requires the FFTW. - 'fxt', Fast Polynomial Transformation. uses FXTPACK |
|||
integer, | private | :: | maxPolyDegree | The maximal polynomial degree per spatial direction. |
|||
integer, | private | :: | oversamp_degree | Using oversampling, the modal space need to be extended according |
|||
integer, | private | :: | min_degree | ||||
integer, | private | :: | nQuadPointsPerDir | quadrature points including oversampling factor |
|||
logical, | private | :: | lobattoPoints | = | .false. | Logical to indicate whether Chebyshev-Lobatto points or simple Chebyshev points are used |
|
type(ply_prj_body_type), | private | :: | body_1d | projection header consits of general information like which kind of projection is used In the body datatype, there is for each dimension the main data for the projection method stored |
|||
type(ply_prj_body_type), | private | :: | body_2d | ||||
type(ply_prj_body_type), | private | :: | body_3d |
Fill ups the bodys accroding to the DA.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(ply_poly_project_type), | intent(out), | allocatable | :: | proj_list(:) | ||
type(dyn_projectionarray_type), | intent(in) | :: | dyn_projectArray | |||
integer, | intent(in) | :: | scheme_dim |
Fill the body of the projection with all required data, ply_poly_project_define has to be used beforehand to set necessary header information.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(ply_poly_project_type), | intent(inout) | :: | me | |||
type(ply_prj_init_type), | intent(in) | :: | proj_init | |||
integer, | intent(in) | :: | scheme_dim |
function to provide the coordinates from the quadrature points on the faces
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(ply_poly_project_type), | intent(in) | :: | poly_proj | |||
integer, | intent(in) | :: | idir | |||
integer, | intent(in) | :: | ialign | |||
real(kind=rk), | intent(inout), | allocatable | :: | points(:,:) |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(ply_poly_project_type), | intent(in) | :: | poly_proj | |||
integer, | intent(in) | :: | idir | |||
integer, | intent(in) | :: | ialign | |||
real(kind=rk), | intent(out), | allocatable | :: | points(:,:) |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(ply_poly_project_type), | intent(in) | :: | poly_proj | |||
integer, | intent(in) | :: | idir | |||
integer, | intent(in) | :: | ialign | |||
real(kind=rk), | intent(out), | allocatable | :: | points(:,:) |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(ply_poly_project_type), | intent(out) | :: | left | fpt to copy to |
||
type(ply_poly_project_type), | intent(in) | :: | right | fpt to copy from |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(ply_prj_body_type), | intent(out) | :: | left | |||
type(ply_prj_body_type), | intent(in) | :: | right |
Convert nDoF modes to nodal values.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(ply_poly_project_type), | intent(inout) | :: | me | |||
integer, | intent(in) | :: | dim | |||
integer, | intent(in) | :: | nVars | The number of variables to project. If a variable consists of more than one component, the number of components has to be passed. If there are more than one variable, the sum of all components has to be passed (e.g. 6 when there are two three-dimensional vectors). |
||
real(kind=rk), | intent(inout) | :: | modal_data(:,:) | |||
real(kind=rk), | intent(inout) | :: | nodal_data(:,:) |
Convert nodal values to nDoFs modes.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(ply_poly_project_type), | intent(inout) | :: | me | |||
integer, | intent(in) | :: | dim | |||
integer, | intent(in) | :: | nVars | |||
real(kind=rk), | intent(inout) | :: | nodal_data(:,:) | |||
real(kind=rk), | intent(inout) | :: | modal_data(:,:) |