fluidvolume Subroutine

public subroutine fluidvolume(volume)

Uses

  • proc~~fluidvolume~~UsesGraph proc~fluidvolume fluidvolume module~modfields modfields proc~fluidvolume->module~modfields module~modglobal modglobal proc~fluidvolume->module~modglobal module~modmpi modmpi proc~fluidvolume->module~modmpi decomp_2d decomp_2d module~modfields->decomp_2d mpi mpi module~modmpi->mpi

Arguments

Type IntentOptional Attributes Name
real, intent(out) :: volume

Calls

proc~~fluidvolume~~CallsGraph proc~fluidvolume fluidvolume proc~avexy_ibm avexy_ibm proc~fluidvolume->proc~avexy_ibm mpi_allreduce mpi_allreduce proc~avexy_ibm->mpi_allreduce

Called by

proc~~fluidvolume~~CalledByGraph proc~fluidvolume fluidvolume proc~calcfluidvolumes calcfluidvolumes proc~calcfluidvolumes->proc~fluidvolume program~dalesurban DALESURBAN program~dalesurban->proc~calcfluidvolumes

Source Code

  subroutine fluidvolume(volume)
    ! calculates fluid volume of domain excluding blocks

    use modglobal, only   : ib,ie,ih,jb,je,jh,kb,ke,kh,dy,dxf,dzf
    use modfields, only   : IIc, IIcs
    use modmpi, only      : sumy_ibm, avexy_ibm

    implicit none
    real, intent(out)             :: volume
    real, dimension(ib:ie,kb:ke)  :: sumy
    real, dimension(kb:ke+kh)        :: sumxy
    integer                          k

    sumy = 0.
    sumxy = 0.

    ! ! integrate fluid volume in y
    ! call sumy_ibm(sumy,IIc(ib:ie,jb:je,kb:ke)*dy,ib,ie,jb,je,kb,ke,IIc(ib:ie,jb:je,kb:ke))
    !
    ! ! integrate fluid area in x
    ! do k=kb,ke
    !   sumxy(k) = sum(sumy(ib:ie,k)*dxf(ib:ie))
    ! end do

    ! Equidistant x
    call avexy_ibm(sumxy(kb:ke+kh),IIc(ib:ie,jb:je,kb:ke+kh)*dxf(1)*dy,ib,ie,jb,je,kb,ke,ih,jh,kh,IIc(ib:ie,jb:je,kb:ke+kh),IIcs(kb:ke+kh),.false.)

    ! integrate fluid area in z
    volume = sum(sumxy(kb:ke)*dzf(kb:ke))

  end subroutine fluidvolume