[ncl-talk] dot product question

Dennis Shea shea at ucar.edu
Fri Aug 14 14:24:14 MDT 2020


  See attached

%> ncl tst_dim_dot_n.ncl

On Thu, Aug 13, 2020 at 9:24 PM M P via ncl-talk <ncl-talk at mailman.ucar.edu>
wrote:

> Hello,
> I have two arrays a(:,:,:), b(:,:,:), third dimension being vertical.  I
> want to obtain a dot product along  the third index i.e.
> c(i,j) = sum[a(i,j,k)*b(i,j,k)]_k=bottom,top.
> I tried dim_sum_n but probably incorrectly and it produces wrong results.
> Can you advise?
> Thanks,
> Mark
> _______________________________________________
> 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/20200814/315e1f19/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: tst_dim_dot_n.ncl
Type: application/octet-stream
Size: 1155 bytes
Desc: not available
URL: <https://mailman.ucar.edu/pipermail/ncl-talk/attachments/20200814/315e1f19/attachment.obj>


More information about the ncl-talk mailing list