I have three orthonormal vectors
(-0.460021, -0.241295, -0.854493),
(-0.641846, 0.755344, 0.132244),
(-0.613526, -0.609288, 0.502348)
and a magntitude value along each of these direction 1.44, 3.45
and 2.02
.
How can I plot an ellipsoid (3D surface) representing the axis directions along the orthonormal vectors and the axis lengths given by their magnitude ?
CodePudding user response:
If I understand your question correctly, you want to create an ellipsoid and rotate it so that its major axis are aligned with the orthonormal vectors.
Note: since Matplotlib's 3D capability are rather limited, I'm going to use Plotly: it will make our life a lot easier since it provides an "equal" aspect ratio for 3D plots. You can easily change the plotting library to Matplotlib.