How to compute DOT & CURL function together?

3 ビュー (過去 30 日間)
chi shing
chi shing 2014 年 1 月 25 日
回答済み: Roger Stafford 2014 年 1 月 26 日
  • I have these data: Ex,Ey,Ez,Hx,Hy,Hz,X,Y,Z (all 3D matrix)
  • I first to calculate the curl of each component
  • And then calculate the dot product
  • [CurlE_x,CurlE_y,CurlE_z] = curl(X,Y,Z,Ex,Ey,Ez);
  • E_dot_CurlE = (Ex.*CurlE_x + Ey.*CurlE_y + Ez.*CurlE_z);
  • I want to know the above syntax correct or not?

回答 (1 件)

Roger Stafford
Roger Stafford 2014 年 1 月 26 日
That looks good to me. Remember that X, Y, and Z must be monotonic and as produced by 'meshgrid' for 'curl' to work properly.
Also remember that for your discrete arrays, this computation will only be an approximation to the theoretical value.

カテゴリ

Help Center および File ExchangeThermodynamics & Statistical Physics についてさらに検索

製品

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by