Skip to contents

Modified Total Totals Index

Usage

modified_Total_Totals(ta_s, hus_s, pa_s, ta_pl, hus_pl, pa_pl, nthreads = 1)

Arguments

ta_s

parcel temperature [lon, lat, time] at 2 meter above the surface (K).

hus_s

parcel specific humidity [lon, lat, time] at 2 meter above the surface (kg/kg).

pa_s

surface pressure [lon, lat, time] (hPa).

ta_pl

air temperature [lon, lat, lev, time] on pressure level (K).

hus_pl

specific humidity [lon, lat, lev, time] on pressure level (kg/kg).

pa_pl

pressure profile [lev] in descending manner (hPa).

nthreads

an integer specifying the number of threads to use for computation (OpenMP). Default is 1.

Value

the computed modified total totals index [lon, lat, time] (K).

References

Examples

data("ERA5_sfc")
ta_s <- ERA5_sfc$t2m
td_s <- ERA5_sfc$t2d
pa_s <- ERA5_sfc$sp / 100
hus_s <- hus_from_td(td_s, pa_s)
dim(hus_s) <- dim(ta_s)

data("ERA5_pl")
ta <- ERA5_pl$ta
hus <- ERA5_pl$hus
# convert to hPa
pa <- ERA5_pl$plev / 100
res <- modified_Total_Totals(
  ta_s,
  hus_s,
  pa_s,
  ta,
  hus,
  pa
)