thermcell_main_mars.F90

路径

LMDZ.MARS\libf\phymars\thermcell_main_mars.F90

所属目录 / 模块

libf\phymars

文件定位

thermcell_main_mars.F90 定义 Martian thermal plume model 的主体子步长求解器。它由 calltherm_interface_modnsplit_thermals 子步长循环内调用,负责从当前温度、风、压力、层几何和 CO2 tracer 状态出发,估计热羽流源层、保守羽流高度、卷入/退卷、上升质量通量、下沉气流、温度 tendency、CO2 tracer tendency、覆盖率和热通量诊断。

本文件不处理非 CO2 tracer 或风的被动输送;那些变量在接口层用 thermcell_dqup 后处理。CO2 tracer 是例外:它会改变平均分子量和修正位温,因此在本主求解器内部用同一个输送算子更新。

定义的符号

符号 类型 行号 作用
thermcell_main_mars_mod module 1 封装 Martian thermal plume 主求解器。
thermcell_main_mars subroutine 39 在一个热羽流子步长内计算热羽流结构、温度/CO2 演化和诊断通量。

依赖的模块

use 模块 only 列表 用途 待确认
comtherm_h 未限制 读取 r_aspect_thermalsad/bd/ae/befdfu/omega/a1/b1/a1inv/b1invthermverbose 等热羽流参数。 -
planetwide_mod planetwide_maxval MESOSCALE 构建中把局地 lmax/lalim 扩展为全行星最大 limz/llmax -
comcstfi_h g, r 用重力和气体常数计算质量、密度、浮力和温度 tendency 换算。 -
thermcell_dqup_mod thermcell_dqup 在本求解器内部输送 CO2 tracer。 -

调用的关键例程

被调用例程 所在模块 / 文件 调用位置 作用
planetwide_maxval planetwide_mod.F90 行 782、818 取得全行星最大热羽流层索引;limz=lmax_global+2 控制后续积分范围,llmax 控制源层闭合循环范围。
thermcell_dqup thermcell_dqup.F90 行 1193-1195 在质量通量修正后输送 CO2 tracer,并返回 pdqadj(:,:,igcm_co2)

被调用位置

调用方 文件 位置 作用
calltherm_interface calltherm_interface_mod.F90 use 行 60;调用行 232-242 每个热羽流子步长调用本例程,再把本例程返回的温度、CO2 和诊断量时间平均或累计回整物理步长。

输入

输入 来源 类型 / 维度 单位 含义
ngrid, nlayer, nq 接口层 integer - 物理列数、垂直层数和 tracer 数。
igcm_co2 接口层 / tracer 初始化 integer - CO2 tracer 在 pq 中的索引;0 表示没有 CO2 tracer。
ptimestep 接口层子步长 real scalar s 当前热羽流子步长长度。
pt, pu, pv, pq, pq2 接口层准备的状态 real arrays K, m/s, kg/kg, TKE 单位 温度、水平风、tracer 混合比和层中心 TKE。
pplay, pplev, pphi physiq real arrays Pa, Pa, m2/s2 层中心压力、层界面压力和位势。
zlay, zlev 接口层几何 real arrays m 层中心和层界面高度。
zpopsk 接口层热力因子 real array - 温度与位温换算因子。

输出

输出 去向 类型 / 维度 单位 含义
pdtadj 接口层累计为温度 tendency real (ngrid,nlayer) K/s 热羽流上升流和下沉气流导致的温度变化率。
pdqadj 接口层只读取 CO2 分量 real (ngrid,nlayer,nq) kg/kg/s CO2 tracer 的热羽流输送 tendency;非 CO2 分量在接口层另行处理。
fm, entr, detr 接口层时间平均并供被动输送使用 real arrays mass flux 上升质量通量、夹卷通量、退卷通量。
lmax, zmax, limz 接口层诊断和后续输送范围 integer / real layer index, m 每列热羽流最高层、插值高度和全域积分上限。
zw2, fraca 接口层诊断 real arrays m/s, fraction 界面垂直速度和热羽流面积分数。
heatFlux, heatFlux_down 接口层诊断 / hfmax 计算 real arrays K m/s 量级 上升热羽流和下沉气流热通量诊断。
buoyancyOut, buoyancyEst 接口层诊断 real arrays m/s2 实际和估计的界面浮力项。

共享状态与副作用

核心逻辑

  1. 清零 entr/detr/fm,用 zhc=pt/zpopsk 得到位温,并令内部 CO2 输送子步数 ndt=1
  2. igcm_co2.ne.0,用 CO2 与非凝结气体分子量计算 A/B,把位温改写为依赖 CO2 混合比的修正位温;否则直接用普通位温。
  3. 识别源层、保守羽流速度和羽流高度,估计无量纲夹卷/退卷率,并迭代更新上升流温度、垂直速度和源层夹卷。
  4. 根据 zw2 加权积分得到 zmax;非 MESOSCALE 下用 planetwide_maxval(lmax,limz) 后令 limz=limz+2MESOSCALE 下直接设为 nlayer-5
  5. 用源层闭合得到质量通量尺度 f,再把无量纲 entr_star/detr_star/alim_star 转为真实 entr/detr
  6. 重建 fm,随后逐层执行负质量通量、过大退卷、过强夹卷和 alphamax 覆盖率限制等修正,保证 fm(lmax+1)=0
  7. 按上升流温度差计算 zdthladj,再按 fdfu 和高度比例构造下沉质量通量 fm_down 与下沉温度廓线 ztvd,计算 zdthladj_down
  8. 用清理后的 fm/(rhobarz*zw2) 得到界面覆盖率 fraca
  9. 若存在 CO2 tracer,先由质量守恒重算 detrmod=fm(k)-fm(k+1)+entr(k),再调用 thermcell_dqup 输送 pq(:,:,igcm_co2),并用输送后的 CO2 重新计算 ratiom。如果第 786-790 行已因热羽流触顶把 limz 截断为 nlayer,这里传入 thermcell_dqup 的仍是 nlayer;下游会读取 q(:,limz+1),复现时必须检查 pq(:,:,igcm_co2) 的顶层边界是否安全。
  10. (zdthladj+zdthladj_down)*zpopsk*ratiom 得到 pdtadj,最后在界面插值环境、上升流和下沉流位温,输出 heatFluxheatFlux_downbuoyancyOutbuoyancyEst

伪代码

thermcell_main_mars(...):
    entr, detr, fm = 0
    theta = pt / zpopsk

    if igcm_co2 != 0:
        theta_model = theta * (A * pq[:,:,igcm_co2] + B)
    else:
        theta_model = theta

    find source layers and conservative plume velocity
    estimate entrainment/detrainment and updraft profile
    compute lmax and zmax

    if MESOSCALE:
        limz = nlayer - 5
    else:
        limz = planetwide_max(lmax) + 2
    limz = min(limz, nlayer)

    f = closure_mass_flux(...)
    entr = f * (entr_star + alim_star)
    detr = f * detr_star
    reconstruct fm and apply correction blocks

    zdthladj = upward_temperature_transport(fm, theta_model)
    fm_down, ztvd = downdraft_parameterization(fm, zmax)
    zdthladj_down = downdraft_temperature_transport(fm_down, ztvd)
    fraca = fm / (rhobarz * zw2)

    if igcm_co2 != 0:
        detrmod = fm - fm_next + entr
        thermcell_dqup(..., pq[:,:,igcm_co2], pdqadj[:,:,igcm_co2], ndt=1, limz)
        ratiom = 1 / (A * transported_CO2 + B)

    pdtadj = (zdthladj + zdthladj_down) * zpopsk * ratiom
    heatFlux, heatFlux_down, buoyancyOut, buoyancyEst = diagnostics(...)

参与的主题流程

主题 参与方式
热羽流 / 边界层对流 求解 thermal plume 主体结构,给出热羽流高度、质量通量、温度 tendency 和诊断量。
CO2 tracer / 极区混合 igcm_co2 非零时用 CO2 混合比修正位温,并在子步长内部输送 CO2。
并行物理网格规约 MESOSCALE 下用 planetwide_maxval 保证所有进程使用一致的 limz/llmax
诊断输出 输出 heatFluxheatFlux_downbuoyancyOutbuoyancyEstfracazw2 等供接口层和后续输出使用。

写法特点

复现要点

待确认

相关页面