現行 sim_config を型付き場設定へ写像する。
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(sim_config), | intent(in) | :: | sim | |||
| type(field_physics_config), | intent(out) | :: | field | |||
| type(periodic2_physics_config), | intent(out) | :: | periodic2 | |||
| type(panel_kernel_config), | intent(out) | :: | panel |
subroutine normalize_legacy_physics_config(sim, field, periodic2, panel) type(sim_config), intent(in) :: sim type(field_physics_config), intent(out) :: field type(periodic2_physics_config), intent(out) :: periodic2 type(panel_kernel_config), intent(out) :: panel character(len=32) :: bc_mode, far_mode call derive_field_panel_config(sim, field, panel) periodic2 = periodic2_physics_config() bc_mode = lower_ascii(trim(sim%field_bc_mode)) if (trim(bc_mode) /= 'periodic2') return far_mode = lower_ascii(trim(sim%field_periodic_far_correction)) select case (trim(far_mode)) case ('none', 'auto') periodic2%nonzero_mode_backend = 'legacy_finite_images' periodic2%zero_mode_policy = 'legacy_not_decomposed' periodic2%lower_boundary_model = 'legacy_implicit' case ('cached_kneq0') periodic2%nonzero_mode_backend = 'cached_kneq0' periodic2%zero_mode_policy = 'exclude_k0' periodic2%lower_boundary_model = 'e_bottom_zero' case default periodic2%nonzero_mode_backend = 'invalid' periodic2%zero_mode_policy = 'invalid' periodic2%lower_boundary_model = 'invalid' end select end subroutine normalize_legacy_physics_config