Returns the 3-d array with values of Eulerian velocity (mean current) in y-direction [m/s].
Note: this implementation assumes that all u and v velocity arrays in the domain instance are of same length in depth, such that the resulting u and v arrays are regular 3-d arrays.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(domain_type), | intent(in) | :: | self | Domain instance |
Eulerian v-velocity [m/s]
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 getCurrent_v(self) result(v)
!! Returns the 3-d array with values of Eulerian velocity (mean current) in
!! y-direction [m/s].
!!
!! Note: this implementation assumes that all u and v velocity arrays in
!! the domain instance are of same length in depth, such that the resulting
!! u and v arrays are regular 3-d arrays.
class(domain_type),intent(in) :: self
!! Domain instance
real(kind=rk),dimension(:,:,:),allocatable :: v
!! Eulerian v-velocity [m/s]
integer(kind=ik) :: i,j
integer(kind=ik) :: kdm
associate(lb => self % lb,ub => self % ub)
kdm = size(self % spectrum(1,1) % getCurrent_v())
allocate(v(lb(1):ub(1),lb(2):ub(2),kdm))
do concurrent(i=lb(1):ub(1),j=lb(2):ub(2))
v(i,j,:) = self % spectrum(i,j) % getCurrent_v()
enddo
endassociate
endfunction getCurrent_v