Error in ECHAM pressure levels.

From: A.R Ragi <ar.ragi_at_nyahnyahspammersnyahnyah>
Date: Tue Feb 23 2010 - 01:21:04 MST

Dear NCL users..,

I want to calculate the equation which is for converting ECHAM 31 levels to
pressure levels in hPa.

1 level is 1000hPa and 31 level is 10 hPa.

The equation written in model to calculate pressure levels is:

*P(lev) =a(lev)+b(lev)*Ps(time,lat,lon)

a* and* b* are hybrid coefficient which is in the model output.
and *Ps *also in the model output.

But *a and b *are one dimensional but Ps is three dimensional.

*a(31), b(31) but Ps (30,192,96)*

The error saying *P(lev) *is undefined.

Means it is not calculating the equation.

Is this because of matrix multiplication needed for this case?

Thanks in advance.
*

Code:*

begin

echam_out = addfile("/....../test_2003.06.nc","r")

  A = echam_out->hyam(:)
  B = echam_out->hybm(:)
  Ps = echam_out->aps(:,:,:)

do k = 1,31

        do j = 1,96

                do i = 1,192

                        P(k) = A(k)+B(k)* Ps(1,i,j)

                        asciiwrite("P.txt",P(1,1,k))

                 end do

        end do

end do

end

fatal:Undefined identifier: (P) is undefined, can't continue
fatal:Execute: Error occurred at or near line 46 in file Pvalues.ncl

-- 
*********************************************************************
Thanks,
A.R.Ragi
M.Tech Atmospheric science
Department of Atmospheric science
Cochin University of Science and Technology
Email : ar.ragi@gmail.com

_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Tue Feb 23 01:21:30 2010

This archive was generated by hypermail 2.1.8 : Tue Feb 23 2010 - 08:26:41 MST