# [ncl-talk] mixhum_ptrh

Fri Jun 19 09:25:25 MDT 2020

``` Dear Rick,Thank you so much for your quick help.That's exactly what I need.
SincerelyEhsan
On Friday, June 19, 2020, 07:34:13 PM GMT+4:30, Rick Brownrigg <brownrig at ucar.edu> wrote:

Hi,
If I understand correctly (and that's a big "if"), you might check out the conform function:
http://ncl.ucar.edu/Document/Functions/Built-in/conform.shtml
That is, I *think* if you make your pressure array conform to the temp/RH arrays, then you should be able to call mixhum_ptrh directly. It may take some experimentation.
Hope that helps...Rick

On Fri, Jun 19, 2020 at 8:52 AM Ehsan Taghizadeh via ncl-talk <ncl-talk at mailman.ucar.edu> wrote:

Dears,
I hope you're doing great.I want to calculate "specific humidity" via "mixhum_ptrh". I have pressure, temperature and relative humidity arrays, but their dimensions are not the same! Actually I have temperature and relative humidity on grid points at different pressure levels. So their dimensions are like below:
Dimensions and sizes:   [lv_ISBL0 | 15] x [lat_0 | 721] x [lon_0 | 1440]
However, the pressure array is the first dimension of them (lv_ISBL0) and is like below:
Dimensions and sizes:   [15]

Actually, I want to calculate "specific humidity" for each grid point at each pressure level. May I ask any help to use "mixhum_ptrh" without do loops over the grid points?
I hope I could explain my problem clearly and I hope to hear from you.
SincerelyEhsan_______________________________________________
ncl-talk mailing list
ncl-talk at mailman.ucar.edu
List instructions, subscriber options, unsubscribe:
https://mailman.ucar.edu/mailman/listinfo/ncl-talk

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.ucar.edu/pipermail/ncl-talk/attachments/20200619/6606344f/attachment.html>
```