フィルターのクリア

Plotting electric field at many points in 3D space.

5 ビュー (過去 30 日間)
Abhay Mohan
Abhay Mohan 2017 年 1 月 8 日
コメント済み: Abhay Mohan 2020 年 3 月 7 日
Hi,
Let me first say that I am aware of surf and plot3 functions, neither of which seem to help me in this scenario:
I have to plot the electric field at many points in 3D space. So I have three vectors x, y and z that indicate positions and a vector Ez that indicates the strength of electric field at each point (x,y,z). If x is a 100 X 1 vector, so are y, z and Ez. Basically I need to plot the function Ez(x,y,z). I have four vector inputs.
Eg: (Values are just random)
x = 0, y = 0, z = 0, Ez = 100.
x = 0, y = 2, z = 0, Ez = 10.
x = 0, y = 4, z = 0, Ez = 1.
x = 2, y = 2, z = 0, Ez = 1.
...
How can I plot this?

採用された回答

halleyhit
halleyhit 2017 年 1 月 8 日
Maybe the function quiver3 may help you. However I haven't use this function so long time. I'm not sure if it works.
  1 件のコメント
Abhay Mohan
Abhay Mohan 2017 年 1 月 10 日
Thank you! Just what I needed.

サインインしてコメントする。

その他の回答 (2 件)

To Nhat
To Nhat 2017 年 2 月 6 日
Can you give me your code, please?
  1 件のコメント
Abhay Mohan
Abhay Mohan 2020 年 3 月 7 日
I ended up using the surf function for my purposed and keeping z=0 always. Since z=0, I didn't really need to plot the z axis. So I just did an intensity plot using surf.

サインインしてコメントする。


Abhay Mohan
Abhay Mohan 2020 年 3 月 7 日
Hi,
This is for the benefit of the member who messaged me regarding this question. I ended up using the surf function for my purposed and keeping z=0 always. Since z=0, I didn't really need to plot the z axis. So I just did an intensity plot using surf.

カテゴリ

Help Center および File ExchangeSurface and Mesh Plots についてさらに検索

製品

Community Treasure Hunt

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

Start Hunting!

Translated by