Class sl09_diffusion
In: held_suarez_1994/sl09_diffusion.f90

Schneider and Liu (2009) ���������´æ··��課ç�

Vertical diffusion by Schneider and Liu (2009)

Note that Japanese and English are described in parallel.

Procedures List

!$ ! Hs94Forcing :å¼·å�¶ã���£é�¸ã���ç®�
!$ ! Hs94Finalize :çµ�äº����� (�¢ã�¸ã�¥ã�¼ã����������°ã���²ã��ä»���解é��)
!$ ! ———— :————
!$ ! Hs94Forcing :Calculate forcing and dissipation
!$ ! Hs94Finalize :Termination (deallocate variables in this module)

References

 Schneider, T. and J. Liu,
   Formation of jets and equatorial superrotation on Jupiter,
   J. Atmos. Sci., 69, 579, 2009.

Methods

Included Modules

gridset composition dc_types dc_message axesset timeset gtool_historyauto constants vdiffusion_my constants0 namelist_util dc_iounit dc_string

Public Instance methods

Subroutine :
xy_SurfHeight(0:imax-1, 1:jmax) :real(DP), intent(in)
xyz_Height(0:imax-1, 1:jmax, 1:kmax) :real(DP), intent(in)
xyz_U(0:imax-1, 1:jmax, 1:kmax) :real(DP), intent(in)
: $ u $ . �±è¥¿é¢���. Eastward wind
xyz_V(0:imax-1, 1:jmax, 1:kmax) :real(DP), intent(in)
: $ v $ . �������. Northward wind
xyzf_QMix(0:imax-1, 1:jmax, 1:kmax, 1:ncmax) :real(DP), intent(in)
xyr_Press(0:imax-1, 1:jmax, 0:kmax) :real(DP), intent(in)
: $ p_s $ . �°è¡¨�¢æ���. Surface pressure
xyr_VirTemp(0:imax-1, 1:jmax, 0:kmax) :real(DP), intent(in)
xyz_DUDt(0:imax-1, 1:jmax, 1:kmax) :real(DP), intent(out)
: $ DP{u}{t} $ . �±è¥¿é¢���å¤���. Eastward wind tendency
xyz_DVDt(0:imax-1, 1:jmax, 1:kmax) :real(DP), intent(out)
: $ DP{v}{t} $ . ����������. Northward wind tendency
xyz_DTempDt(0:imax-1, 1:jmax, 1:kmax) :real(DP), intent(out)
: $ DP{T}{t} $ . æ¸�º¦å¤���. Temperature tendency
xyzf_DQMixDt(0:imax-1, 1:jmax, 1:kmax, 1:ncmax) :real(DP), intent(out)

[Source]

  subroutine SL09Diffusion( xy_SurfHeight, xyz_Height, xyz_U, xyz_V, xyzf_QMix, xyr_Press, xyr_VirTemp, xyz_DUDt, xyz_DVDt, xyz_DTempDt, xyzf_DQMixDt )
    !
    !
    !

    ! �¢ã�¸ã�¥ã�¼ã����� ; USE statements
    !

    ! 座æ����¼ã�¿è¨­å®�
    ! Axes data settings
    !
    use axesset, only: y_Lat, z_Sigma               ! $ \sigma $ ������ (�´æ��). 
                              ! Full $ \sigma $ level

    ! ���»ç���
    ! Time control
    !
    use timeset, only: DelTime, TimeN, TimesetClockStart, TimesetClockStop

    ! ���¹ã�������¼ã�¿å�ºå��
    ! History data output
    !
    use gtool_historyauto, only: HistoryAutoPut

    ! ����å®��°è¨­å®�
    ! Physical constants settings
    !
    use constants, only: GasRDry, CpDry    ! $ C_p $ [J kg-1 K-1].
                                  ! ä¹¾ç�¥å¤§æ°�����§æ���.
                                  ! Specific heat of air at constant pressure

    ! ���´æ�¡æ�£ã����������
    ! Vertical diffusion flux
    !
    use vdiffusion_my, only: VDiffusionExpTendency

    ! 宣�� ; Declaration statements
    !
    implicit none

    real(DP), intent(in):: xy_SurfHeight(0:imax-1, 1:jmax)
    real(DP), intent(in):: xyz_Height   (0:imax-1, 1:jmax, 1:kmax)
    real(DP), intent(in):: xyz_U    (0:imax-1, 1:jmax, 1:kmax)
                              ! $ u $ . �±è¥¿é¢���. 
                              ! Eastward wind
    real(DP), intent(in):: xyz_V    (0:imax-1, 1:jmax, 1:kmax)
                              ! $ v $ . �������. 
                              ! Northward wind
    real(DP), intent(in):: xyzf_QMix(0:imax-1, 1:jmax, 1:kmax, 1:ncmax)
    real(DP), intent(in):: xyr_Press(0:imax-1, 1:jmax, 0:kmax)
                              ! $ p_s $ . �°è¡¨�¢æ���. 
                              ! Surface pressure
    real(DP), intent(in):: xyr_VirTemp  (0:imax-1, 1:jmax, 0:kmax)
    real(DP), intent(out):: xyz_DUDt (0:imax-1, 1:jmax, 1:kmax)
                              ! $ \DP{u}{t} $ . �±è¥¿é¢���å¤���. 
                              ! Eastward wind tendency
    real(DP), intent(out):: xyz_DVDt (0:imax-1, 1:jmax, 1:kmax)
                              ! $ \DP{v}{t} $ . ����������. 
                              ! Northward wind tendency
    real(DP), intent(out):: xyz_DTempDt (0:imax-1, 1:jmax, 1:kmax)
                              ! $ \DP{T}{t} $ . æ¸�º¦å¤���. 
                              ! Temperature tendency
    real(DP), intent(out):: xyzf_DQMixDt (0:imax-1, 1:jmax, 1:kmax, 1:ncmax)

    ! �業��
    ! Work variables
    !
    real(DP) :: xyr_HeatFlux (0:imax-1, 1:jmax, 0:kmax)
                              ! �±ã����������. 
                              ! Heat flux
    real(DP) :: xyrf_QMixFlux (0:imax-1, 1:jmax, 0:kmax, 1:ncmax)

    real(DP) :: xy_SurfQMixTransCoef(0:imax-1, 1:jmax)

!!$    integer:: j               ! ç·�º¦�¹å�������� DO ���¼ã�����業å���
!!$                              ! Work variables for DO loop in latitude
    integer:: k               ! ���´æ�¹å�������� DO ���¼ã�����業å���
                              ! Work variables for DO loop in vertical direction
    integer:: n


    ! ���� ; Executable statement
    !

    ! ������
    ! Initialization
    !
    if ( .not. sl09_diffusion_inited ) then
      call MessageNotify( 'E', module_name, 'This module has not been initialized.' )
    end if

    ! �����������
    ! Start measurement of computation time
    !
    call TimesetClockStart( module_name )

    ! �±è¥¿é¢��� $ u $ ������é¢��� $ v $ �¸ã���¤ã���¼æ����������
    ! Apply Rayleigh damping to eastward wind $ u $ and northward wind $ v $
    !
    xyz_DUDt = - xyz_kv * xyz_U
    xyz_DVDt = - xyz_kv * xyz_V


    ! Set heat flux at the lower boundary
    !
    xyr_HeatFlux(:,:,0     ) = LBHeatFlux
    xyr_HeatFlux(:,:,1:kmax) = 0.0_DP

    ! Set moisture flux at the lower boundary
    !
    xyrf_QMixFlux = 0.0_DP
    n = IndexH2OVap
    k = 0
    xy_SurfQMixTransCoef = SurfQMixDiffCoef * xyr_Press(:,:,k) / ( GasRDry * xyr_VirTemp(:,:,k) ) / ( xyz_Height(:,:,k+1) - xy_SurfHeight )
    xyrf_QMixFlux(:,:,k,n) = - xy_SurfQMixTransCoef * ( xyzf_QMix(:,:,k+1,n) - SurfQVap )



    ! ����å¤��������ç®���è¡����¾ã��.
    ! Calculate tendencies.
    !
    call VDiffusionExpTendency( xyr_Press, xyr_HeatFlux  = xyr_HeatFlux, xyrf_QMixFlux = xyrf_QMixFlux, xyz_DTempDt  = xyz_DTempDt, xyzf_DQMixDt = xyzf_DQMixDt )


    ! This is commented out (yot, 2013/05/12) to be consistent with SL09.
    ! Temporarily, xyzf_DQMixDt is overwritten.
!!$    xyzf_DQMixDt = 0.0_DP
!!$    k = 1
!!$    n = IndexH2OVap
!!$    xyzf_DQMixDt(:,:,k,n) = ( SurfQVap - xyzf_QMix(:,:,k,n) ) &
!!$      & / ( 2.0_DP * DelTime )
!!$    xyzf_DQMixDt(:,:,k,n) = ( SurfQVap - xyzf_QMix(:,:,k,n) ) &
!!$      & / ( 2.0_DP * DelTime )


    !
    ! Add heating due to MHD drag dissipation
    !
    xyz_DTempDt = xyz_DTempDt - ( xyz_DUDt * xyz_U + xyz_DVDt * xyz_V ) / CpDry


    ! ���¹ã�������¼ã�¿å�ºå��
    ! History data output
    !
    call HistoryAutoPut( TimeN, 'DUDtVDiffSL09',    xyz_DUDt    )
    call HistoryAutoPut( TimeN, 'DVDtVDiffSL09',    xyz_DVDt    )
    call HistoryAutoPut( TimeN, 'DTempDtVDiffSL09', xyz_DTempDt )


    ! ��������������
    ! Pause measurement of computation time
    !
    call TimesetClockStop( module_name )

  end subroutine SL09Diffusion
Subroutine :

sl09_diffusion �¢ã�¸ã�¥ã�¼ã������������è¡����¾ã��. NAMELIST#sl09_diffusion_nml ����¿è¾¼�¿ã��������ç¶����§è�����¾ã��.

"sl09_diffusion" module is initialized. "NAMELIST#sl09_diffusion_nml" is loaded in this procedure.

This procedure input/output NAMELIST#sl09_diffusion_nml .

[Source]

  subroutine SL09DiffusionInit
    !
    ! sl09_diffusion �¢ã�¸ã�¥ã�¼ã������������è¡����¾ã��. 
    ! NAMELIST#sl09_diffusion_nml ����¿è¾¼�¿ã��������ç¶����§è�����¾ã��. 
    !
    ! "sl09_diffusion" module is initialized. 
    ! "NAMELIST#sl09_diffusion_nml" is loaded in this procedure. 
    !

    ! �¢ã�¸ã�¥ã�¼ã����� ; USE statements
    !

    ! �����»æ�°å­¦å®��°è¨­å®�
    ! Physical and mathematical constants settings
    !
    use constants0, only: PI
                              ! $ \pi $ .
                              ! �����.  Circular constant

    ! ����å®��°è¨­å®�
    ! Physical constants settings
    !
    use constants, only: GasRDry, CpDry
                              ! $ C_p $ [J kg-1 K-1]. 
                              ! ä¹¾ç�¥å¤§æ°�����§æ���. 
                              ! Specific heat of air at constant pressure

    ! 座æ����¼ã�¿è¨­å®�
    ! Axes data settings
    !
    use axesset, only: y_Lat, z_Sigma               ! $ \sigma $ ������ (�´æ��). 
                              ! Full $ \sigma $ level

    ! NAMELIST ���¡ã�¤ã���¥å�����¢ã�������¼ã���£ã������
    ! Utilities for NAMELIST file input
    !
    use namelist_util, only: namelist_filename, NmlutilMsg, NmlutilAryValid

    ! ���¡ã�¤ã���¥å�ºå��è£���
    ! File I/O support
    !
    use dc_iounit, only: FileOpen

    ! ç¨��¥å�������¡ã��
    ! Kind type parameter
    !
    use dc_types, only: STDOUT ! æ¨�æº��ºå�����ç½����. Unit number of standard output

    ! ��������
    ! Character handling
    !
    use dc_string, only: StoA

    ! ���¹ã�������¼ã�¿å�ºå��
    ! History data output
    !
    use gtool_historyauto, only: HistoryAutoAddVariable

    ! ���´æ�¡æ�£ã����������
    ! Vertical diffusion flux
    !
    use vdiffusion_my, only: VDiffusionInit


    ! 宣�� ; Declaration statements
    !
    implicit none

    real(DP), parameter :: day_seconds = 86400.0_DP
                              ! 1 �¥ã�����. 
                              ! Seconds in day. 
    real(DP):: SigmaB         ! $ \sigma_b $ .
    real(DP):: kf             ! $ k_f $ .

    real(DP):: kfTimeScaleInDay
    real(DP):: FrictionLBLat

    integer:: j               ! ç·�º¦�¹å�������� DO ���¼ã�����業å���
                              ! Work variables for DO loop in latitude
    integer:: k               ! ���´æ�¹å�������� DO ���¼ã�����業å���
                              ! Work variables for DO loop in vertical direction

    integer:: unit_nml        ! NAMELIST ���¡ã�¤ã�����¼ã���³ç���ç½����. 
                              ! Unit number for NAMELIST file open
    integer:: iostat_nml      ! NAMELIST 読ã�¿è¾¼�¿æ���� IOSTAT. 
                              ! IOSTAT of NAMELIST read

    ! NAMELIST å¤��°ç¾¤
    ! NAMELIST group name
    !
    namelist /sl09_diffusion_nml/ SigmaB, kfTimeScaleInDay, FrictionLBLat, LBHeatFlux, SurfQMixDiffCoef, SurfQVap

          !
          ! �����������¤ã���¤ã��������������ç¶� "sl09_diffusion#SL09DiffusionInit" 
          ! ���½ã�¼ã�¹ã�³ã�¼ã�������§ã������. 
          !
          ! Refer to source codes in the initialization procedure
          ! "sl09_diffusion#SL09DiffusionInit" for the default values. 
          !

    ! ���� ; Executable statement
    !

    if ( sl09_diffusion_inited ) return

    ! �����������¤ã��¨­å®�
    ! Default values settings
    !
    SigmaB           =  0.8_DP
    kfTimeScaleInDay = 20.0_DP
    FrictionLBLat    = 16.3_DP
    LBHeatFlux       =  5.7_DP
    SurfQMixDiffCoef =  0.0_DP
!!$    SurfQMixDiffCoef = 800.0d2    ! Sugiyama et al. (2009) Nagare Multimedia
    SurfQVap         =  0.0_DP
!!$    SurfQVap         = 7.816d-4   ! Sugiyama et al. (2009) Nagare Multimedia


    ! NAMELIST ����¿è¾¼��
    ! NAMELIST is input
    !
    if ( trim(namelist_filename) /= '' ) then
      call FileOpen( unit_nml, namelist_filename, mode = 'r' ) ! (in)

      rewind( unit_nml )
      read( unit_nml, nml = sl09_diffusion_nml, iostat = iostat_nml )               ! (out)
      close( unit_nml )

      call NmlutilMsg( iostat_nml, module_name ) ! (in)
!!$      if ( iostat_nml == 0 ) write( STDOUT, nml = held_suarez_1994_nml )
    end if

    ! ä¿��°ã��¨­å®�
    ! Configure coefficients
    !
    kf     = 1.0_DP / ( kfTimeScaleInDay * day_seconds )

    allocate( xyz_kv (0:imax-1, 1:jmax, 1:kmax) )
    do k = 1, kmax
      do j = 1, jmax
        if ( abs( y_Lat(j) ) * 180.0_DP / PI <= FrictionLBLat ) then
          xyz_kv(:,j,k) = 0.0_DP
        else
          xyz_kv(:,j,k) = kf * max( 0.0_DP, ( z_Sigma(k) - SigmaB ) / ( 1.0_DP - SigmaB ) )
        end if
      end do
    end do


    ! ���´æ�¡æ�£ã���������� (Mellor and Yamada, 1974, ������ 2)
    ! Vertical diffusion flux (Mellor and Yamada, 1974, Level 2)
    !
    call VDiffusionInit


    ! ���¹ã�������¼ã�¿å�ºå�����������¸ã����°ç�»é��
    ! Register of variables for history data output
    !
    call HistoryAutoAddVariable( 'DUDtVDiffSL09', (/ 'lon ', 'lat ', 'sig ', 'time' /), 'eastward wind tendency', 'm s-2' )
    call HistoryAutoAddVariable( 'DVDtVDiffSL09', (/ 'lon ', 'lat ', 'sig ', 'time' /), 'northward wind tendency', 'm s-2' )
    call HistoryAutoAddVariable( 'DTempDtVDiffSL09', (/ 'lon ', 'lat ', 'sig ', 'time' /), 'temperature tendency', 'K s-1' )

    ! �°å� ; Print
    !
    call MessageNotify( 'M', module_name, '----- Initialization Messages -----' )
    call MessageNotify( 'M', module_name, 'SigmaB           = %f', d = (/ SigmaB /) )
    call MessageNotify( 'M', module_name, 'kfTimeScaleInDay = %f', d = (/ kfTimeScaleInDay /) )
    call MessageNotify( 'M', module_name, 'FrictionLBLat    = %f', d = (/ FrictionLBLat /) )
    call MessageNotify( 'M', module_name, 'LBHeatFlux       = %f', d = (/ LBHeatFlux /) )
    call MessageNotify( 'M', module_name, 'SurfQMixDiffCoef = %f', d = (/ SurfQMixDiffCoef /) )
    call MessageNotify( 'M', module_name, 'SurfQVap         = %f', d = (/ SurfQVap /) )
    call MessageNotify( 'M', module_name, '-- version = %c', c1 = trim(version) )

    sl09_diffusion_inited = .true.
  end subroutine SL09DiffusionInit
sl09_diffusion_inited
Variable :
sl09_diffusion_inited = .false. :logical, save, public
: ����設������. Initialization flag

Private Instance methods

LBHeatFlux
Variable :
LBHeatFlux :real(DP), save
SurfQMixDiffCoef
Variable :
SurfQMixDiffCoef :real(DP), save
SurfQVap
Variable :
SurfQVap :real(DP), save
module_name
Constant :
module_name = ‘sl09_diffusion :character(*), parameter
: �¢ã�¸ã�¥ã�¼ã������ç§�. Module name
version
Constant :
version = ’$Name: $’ // ’$Id: sl09_diffusion.f90,v 1.8 2013/09/16 12:20:02 yot Exp $’ :character(*), parameter
: �¢ã�¸ã�¥ã�¼ã�������¼ã�¸ã�§ã�� Module version
xyz_kv
Variable :
xyz_kv(:,:,:) :real(DP), save, allocatable
: $ k_v $ .