Prepares fields used by the GRANS solver.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(grans_obj), | intent(inout) | :: | this |
GRANS solver |
subroutine grans_obj_PrepareSolverFields(this) !> Prepares fields used by the GRANS solver. implicit none class(grans_obj), intent(inout) :: this !! GRANS solver ! Work variables character(len=str64) :: filename logical :: overwrite call this%parser%Get('Fields write file', filename) call this%parser%Get('Fields overwrite ', overwrite, default=.true.) ! Initialize fields container call this%fields%Initialize(this%block,this%parallel) ! Set IO parameters call this%fields%SetWriteFileName(filename) call this%fields%SetOverwrite(overwrite) ! Add each field to main container. ! This will allocate the underlying arrays ! and facilitate IO. if (this%use_RP .or. this%use_IB) then call this%fields%Add('rhs', 0,this%rhs ) call this%fields%Add('ibS', 0, this%ibS ) call this%fields%Add('ibVF', 0, this%ibVF ) call this%fields%Add('ibF1', 1, this%ibF(1)) call this%fields%Add('ibF2', 2, this%ibF(2)) call this%fields%Add('ibF3', 3, this%ibF(3)) call this%fields%Add('ibN1', 1, this%ibN(1)) call this%fields%Add('ibN2', 2, this%ibN(2)) call this%fields%Add('ibN3', 3, this%ibN(3)) ! Intialize IB vol frac and ibS this%ibVF%cell = 0.0_wp this%ibS%cell = 0.0_wp end if ! Initialize particle vol frac call this%fields%Add('PVF', 0,this%PVF ) this%PVF%cell = 0.0_wp return end subroutine grans_obj_PrepareSolverFields