31 use ctlblk_mod, only: jsta, jend, spval, im, ista, iend
36 real,
PARAMETER :: capa=0.28589641,p1000=1000.e2
40 real,
dimension(ista:iend,jsta:jend),
intent(in) :: p1d,t1d
41 real,
dimension(ista:iend,jsta:jend),
intent(inout) :: theta
53 IF(t1d(i,j) < spval)
THEN
55 IF(p1d(i,j) > 1.0)
THEN
56 theta(i,j) = t1d(i,j) * (p1000/p1d(i,j))**capa
subroutine calpot(P1D, T1D, THETA)
Subroutine that computes potential temperature.