Converts a case-insensitive string to its corresponding internal BC type ID.
Supports legacy aliases: "fixed_value" (Dirichlet), "zero_gradient" (Neumann),
"no_slip" (Wall), "slip" (Symmetry).
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| character(len=*), | intent(in) | :: | text |
String representation (e.g., "Wall", "Periodic", "Dirichlet"). |
integer function parse_bc_type(text) result(type_id) character(len=*), intent(in) :: text character(len=len(text)) :: key type_id = bc_unknown key = trim(lowercase(text)) select case (trim(key)) case ('wall', 'no_slip', 'moving_wall') type_id = bc_wall case ('symmetry', 'symmetric', 'slip') type_id = bc_symmetry case ('periodic') type_id = bc_periodic case ('dirichlet', 'fixed_value') type_id = bc_dirichlet case ('neumann', 'zero_gradient') type_id = bc_neumann case default call fatal_error('bc', 'unknown boundary type '//trim(text)) end select end function parse_bc_type