Returns a 3-d array with phase speed values [m/s].
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(domain_type), | intent(in) | :: | self | Domain instance |
Phase speed [m/s] array
Nodes of different colours represent the following:
Solid arrows point from a procedure to one which it calls. Dashed arrows point from an interface to procedures which implement that interface. This could include the module procedures in a generic interface or the implementation in a submodule of an interface in a parent module.
pure function getPhaseSpeed(self) result(cp)
!! Returns a 3-d array with phase speed values [m/s].
class(domain_type),intent(in) :: self
!! Domain instance
real(kind=rk),dimension(:,:,:),allocatable :: cp
!! Phase speed [m/s] array
integer(kind=ik) :: i,j
integer(kind=ik) :: ndirs
associate(lb => self % lb,ub => self % ub)
allocate(cp(self % nfreqs,lb(1):ub(1),lb(2):ub(2)))
do concurrent(i=lb(1):ub(1),j=lb(2):ub(2))
cp(:,i,j) = self % spectrum(i,j) % getPhaseSpeed()
enddo
endassociate
endfunction getPhaseSpeed