mus_intp_getSrcMoments Subroutine

public subroutine mus_intp_getSrcMoments(momBuf, state, nSourceElems, srcElemList, QQ, nScalars, nSize, momTransMat, nMoms)

This routine computes moments for all sources elements in momBuf which can be accessed using depFromCoarser(iElem)%elemBuffer. In FillFiner, fine elements can have same sources so to avoid calculating moments for same source elements multiple times, momBuf is used.


real(kind=rk), intent(out) :: momBuf(:,:)

Source moments

real(kind=rk), intent(in) :: state(:)

State vector of source elemnents

integer, intent(in) :: nSourceElems

Total number of source elements

integer, intent(in) :: srcElemList(1:nSourceElems)

element position in source state array

integer, intent(in) :: QQ

number of direction in stencil

integer, intent(in) :: nScalars

number of scalars in state vector

integer, intent(in) :: nSize

Size of state vector

type(tem_matrix_type), intent(in) :: momTransMat

Moments transformation matrix

integer, intent(in) :: nMoms

Number of moments to return



integer, private :: iSourceElem
integer, private :: iDir
integer, private :: sourceElem
real(kind=rk), private :: fTmp(QQ)