Ellipsoid is represented as follows.
Ten parameters are A, B, ..., J. Ellipsoid is a sphere with scaling (degree of freedom: 3), rotation (degree of freedom: 3), and translation (degree of freedom: 3). Multiplying same constant value to left hand side and right hand side results in same equation. The degree of freedom is 9. The above equation represents a quadric surface.
In order to solve A,...,J using least squares method from point clouds, SVD is useful. The right singular vector assigned to the smallest singular value is the solution. Multiplying same constant value to left hand side and right hand side also results in the solution.
3D coordinates of the barycenter (x0, y0, z0) of the ellipsoid can be calculated from following equation.
I skip the derivation. The ellipsoid is an implicit function, so consider the local minima/maxima, and you can derive.
Ellipsoid has three axes. Those can be calculated as the eigenvectors of the following matrix.
I skip the derivation. The ellipsoid is an implicit function, and the Hessian is the above. The direction where the gradient of the 3D scalar field is the largest, smallest, and the moderate will be these three directions.
Radius can be calculated using the intersection between ellipsoid and line. Radius can also be represented by eigenvalue calculated from the above Hessian, but I skip to explain it.
How about ellipse in 3D space? If one of the radius of ellipsoid is infinite, that is the ellipse (or, elliptic cylinder).