Subroutine : |
|
xyr_Press(0:imax-1, 1:jmax, 0:kmax) : | real(DP), intent(in )
: | $ hat{p} $ . 気圧 (半整数レベル). Air pressure (half level)
|
|
xyz_Press(0:imax-1, 1:jmax, 1:kmax) : | real(DP), intent(in )
: | $ p $ . 気圧 (整数レベル). Air pressure (full level)
|
|
xy_SurfTemp(0:imax-1, 1:jmax) : | real(DP), intent(inout)
: | $ T_s $ . 惑星表面温度. Surface temperature
|
|
xyz_Temp(0:imax-1, 1:jmax, 1:kmax) : | real(DP), intent(inout)
: | $ T $ . 温度. Temperature
|
|
subroutine CO2PhaseChangeLimitTemp( xyr_Press, xyz_Press, xy_SurfTemp, xyz_Temp )
!
! CO2 相変化
!
! CO2 phase change
!
! モジュール引用 ; USE statements
!
! 時刻管理
! Time control
!
use timeset, only: DelTime, TimeN, TimesetClockStart, TimesetClockStop
! ヒストリデータ出力
! History data output
!
use gtool_historyauto, only: HistoryAutoPut
! 宣言文 ; Declaration statements
!
implicit none
real(DP), intent(in ):: xyr_Press (0:imax-1, 1:jmax, 0:kmax)
! $ \hat{p} $ . 気圧 (半整数レベル).
! Air pressure (half level)
real(DP), intent(in ):: xyz_Press (0:imax-1, 1:jmax, 1:kmax)
! $ p $ . 気圧 (整数レベル).
! Air pressure (full level)
real(DP), intent(inout):: xy_SurfTemp(0:imax-1, 1:jmax)
! $ T_s $ . 惑星表面温度. Surface temperature
real(DP), intent(inout):: xyz_Temp (0:imax-1, 1:jmax, 1:kmax)
! $ T $ . 温度. Temperature
! 作業変数
! Work variables
!
real(DP):: xy_SurfTempB (0:imax-1, 1:jmax)
! 調節前の惑星表面温度.
! Surface temperature before adjustment
real(DP):: xyz_TempB (0:imax-1, 1:jmax, 1:kmax)
! 調節前の温度.
! Temperature before adjustment
real(DP):: xy_DSurfTempDt(0:imax-1, 1:jmax)
! 惑星表面温度変化率.
! Surface temperature tendency
real(DP):: xyz_DTempDt (0:imax-1, 1:jmax, 1:kmax)
! 温度変化率.
! Temperature tendency
real(DP):: xy_SurfTempCond(0:imax-1, 1:jmax)
real(DP):: xyz_TempCond (0:imax-1, 1:jmax, 1:kmax)
integer:: i ! 経度方向に回る DO ループ用作業変数
! Work variables for DO loop in longitude
integer:: j ! 緯度方向に回る DO ループ用作業変数
! Work variables for DO loop in latitude
integer:: k ! 鉛直方向に回る DO ループ用作業変数
! Work variables for DO loop in vertical direction
logical :: FlagCheckPs
! 実行文 ; Executable statement
!
! 計算時間計測開始
! Start measurement of computation time
!
call TimesetClockStart( module_name )
! 初期化
! Initialization
!
if ( .not. co2_phase_change_inited ) call CO2PhaseChangeInit
if ( .not. FlagUse ) return
FlagCheckPs = .false.
do j = 1, jmax
do i = 0, imax-1
if ( xyr_Press(i,j,0) > 1.0d4 ) then
FlagCheckPs = .true.
end if
end do
end do
if ( FlagCheckPs ) then
call MessageNotify( 'W', module_name, 'Surface pressure is greater than 10000 Pa.' )
end if
! 調節前 "Temp" の保存
! Store "Temp" before adjustment
!
xy_SurfTempB = xy_SurfTemp
xyz_TempB = xyz_Temp
do j = 1, jmax
do i = 0, imax-1
xy_SurfTempCond(i,j) = 149.2d0 + 6.48d0 * log( 0.135d0 * xyr_Press(i,j,0) * 1.0d-2 )
end do
end do
do k = 1, kmax
do j = 1, jmax
do i = 0, imax-1
xyz_TempCond(i,j,k) = 149.2d0 + 6.48d0 * log( 0.135d0 * xyz_Press(i,j,k) * 1.0d-2 )
end do
end do
end do
do j = 1, jmax
do i = 0, imax-1
if ( xy_SurfTemp(i,j) < xy_SurfTempCond(i,j) ) then
xy_SurfTemp(i,j) = xy_SurfTempCond(i,j)
end if
end do
end do
do k = 1, kmax
do j = 1, jmax
do i = 0, imax-1
if ( xyz_Temp(i,j,k) < xyz_TempCond(i,j,k) ) then
xyz_Temp(i,j,k) = xyz_TempCond(i,j,k)
end if
end do
end do
end do
! 温度変化率
! Calculate temperature tendency
!
xy_DSurfTempDt = ( xy_SurfTemp - xy_SurfTempB ) / ( 2.0_DP * DelTime )
xyz_DTempDt = ( xyz_Temp - xyz_TempB ) / ( 2.0_DP * DelTime )
! ヒストリデータ出力
! History data output
!
call HistoryAutoPut( TimeN, 'DSurfTempDtCO2PhaseChange', xy_DSurfTempDt )
call HistoryAutoPut( TimeN, 'DTempDtCO2PhaseChange' , xyz_DTempDt )
! 計算時間計測一時停止
! Pause measurement of computation time
!
call TimesetClockStop( module_name )
end subroutine CO2PhaseChangeLimitTemp