3D plot of an ellipsoid

17 ビュー (過去 30 日間)
Simone Fiumi
Simone Fiumi 2021 年 10 月 12 日
コメント済み: Simone Fiumi 2021 年 10 月 12 日
Hi, I have to plot the following function on a 3d graph, it should be an ellipsoid. theta_ is a 1x3 vector and COV a 3x3 matrix
RC=@(x,y,z) (theta_-[x y z])*inv(COV)*(theta_-[x y z])'-5;

採用された回答

John D'Errico
John D'Errico 2021 年 10 月 12 日
編集済み: John D'Errico 2021 年 10 月 12 日
theta_ = [1 2 3];
COV = cov(rand(10,3)); % picking some arbitrary values for theta_ and COV...
RC=@(x,y,z) (theta_-[x y z])*inv(COV)*(theta_-[x y z])'-5;
fimplicit3(RC)
Warning: Function behaves unexpectedly on array inputs. To improve performance, properly vectorize your function to return an output with the same size and shape as the input arguments.
axis equal
box on
xlabel x
ylabel y
zlabel z
  1 件のコメント
Simone Fiumi
Simone Fiumi 2021 年 10 月 12 日
Thank you!

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

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeVisual Exploration についてさらに検索

タグ

Community Treasure Hunt

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

Start Hunting!

Translated by