詢問如何做出斜座標圖

1 回表示 (過去 30 日間)
Jesse chang
Jesse chang 2022 年 5 月 28 日
回答済み: sai charan sampara 2023 年 9 月 27 日
我想詢問該如何做出以下這樣的圖:
把平面的基底換成斜座標,並在上面做出向量;
如果真的沒辦法的話,我想請教該如何畫出斜格線

回答 (1 件)

sai charan sampara
sai charan sampara 2023 年 9 月 27 日
Hello Jesse,
I understand that you are trying to visualise the result of addition of 2 vectors in 3-dimensional space.
You can do so by using “plot3” function of MATLAB. It can be achieved by using the following code:
i=[1;0;0];
j=[1;2;0];
A=i+j;
plot3([0,A(1)],[0,A(2)],[0,A(3)]);
grid on
axis 'auto xy'
Since a vector can start and end at any point, I have plotted it from the origin.
You can refer to the following MATLAB documentation to learn more about “plot3” function:
Thanks,
Charan.

カテゴリ

Help Center および File ExchangeMATLAB 快速入门 についてさらに検索

タグ

製品


リリース

R2021b

Community Treasure Hunt

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

Start Hunting!