| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| class(bc_set), | intent(in) | :: | this |
Boundary conditions utility |
||
| character(len=*), | intent(in) | :: | normal |
String denoting the normal direction |
||
| integer, | intent(out) | :: | side |
Side (=BC_LEFT,BC_RIGHT) |
||
| integer, | intent(out) | :: | dir |
Direction (=1,2,3,) |
impure subroutine bc_set_GetSideDirByNormal(this,normal,side,dir) ! Finds the direction and side from a string containing the normal direction. class(bc_set), intent(in) :: this !! Boundary conditions utility character(len=*), intent(in) :: normal !! String denoting the normal direction integer, intent(out):: dir !! Direction (=1,2,3,) integer, intent(out):: side !! Side (=BC_LEFT,BC_RIGHT) select case (trim(adjustl(normal))) case ('+x1','+X1','+x','+X') dir = 1; side = BC_LEFT case ('-x1','-X1','-x','-X') dir = 1; side = BC_RIGHT case ('+x2','+X2','+y','+Y') dir = 2; side = BC_LEFT case ('-x2','-X2','-y','-Y') dir = 2; side = BC_RIGHT case ('+x3','+X3','+z','+Z') dir = 3; side = BC_LEFT case ('-x3','-X3','-z','-Z') dir = 3; side = BC_RIGHT case default call this%parallel%Stop("Invalid value for BC normal") end select return end subroutine bc_set_GetSideDirByNormal