This project has moved and is read-only. For the latest updates, please go here.

how to do a cross product?

Jan 27, 2015 at 6:41 PM
Hey All,

I would like to use the (Dense)Vector class in MathNet.Numerics.LinearAlgebra.Double namespace. It seems that it does not contain a CrossProduct function and I was not able to find any similar function via ILSpy either. Could anyone tell me what is the syntax for a crossproduct operation? Yes I could write one myself, but it is really hard to believe an API like this does not contain it. (It would seem like an instant uninstall cause for me.)

Thanks for any help in advance!
Jan 28, 2015 at 7:11 PM
There is a reason there is no cross product available in the Math.NET Numerics linear algebra vectors: the cross product doesn't make a lot of sense in the context of linear algebra, and is even defined for vectors of length 3 only.

However, there is a related project called Math.NET Spatial which is designed for spatial geometry and, of course, does provide the fundamental cross product on its Vector3D type.