This routine loads coupling defintion from boundary condition table
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(tem_aps_coupling_type), | intent(out) | :: | me |
Coupling description to be filled from config file |
||
integer, | intent(in) | :: | thandle |
Boundary condition sub table |
||
type(flu_State), | intent(in) | :: | conf |
Lua script to obtain the configuration data from. |
subroutine tem_aps_load_coupling(me, thandle, conf)
! -------------------------------------------------------------------------!
!> Coupling description to be filled from config file
type(tem_aps_coupling_type), intent(out) :: me
!> Boundary condition sub table
integer, intent(in) :: thandle
!> Lua script to obtain the configuration data from.
type(flu_State), intent(in) :: conf
! -------------------------------------------------------------------------!
integer :: iError
integer, allocatable :: vError(:)
! -------------------------------------------------------------------------!
! get the domain name with whom we want to couple
call aot_get_val( L = conf, &
& thandle = thandle, &
& key = 'domain_from', &
& val = me%rem_domLabel, &
& ErrCode = iError )
if (iError .NE. 0) then
write(logUnit(1),*) ' No coupling domain for the coupling boundary' &
& //' is defined, coupling can not work, abort...'
call tem_abort
end if
! get the list of variables
! look for the request variable table
call aot_get_val( val = me%varNames, &
& ErrCode = vError, &
& maxLength = 100, &
& L = conf, &
& thandle = thandle, &
& key = 'input_varname' )
if ( any(btest(vError, aoterr_Fatal)) ) then
write(logUnit(1),*) 'ERROR: could not input_varname for coupling variable'
call tem_abort()
end if
me%nVars = size(me%varNames)
end subroutine tem_aps_load_coupling