I'm using MathsNet.Numerics lib. I want to do operations on Complex Vectors i.e. I'm
using MathNet.Numerics.LinearAlgebra.Complex
which gives me Vector
as Complex version of MathNet.Numerics.LinearAlgebra.Generic.Vector<T>
Operatations on Vector
s however don't return objects assignable to Vector
:
Complex[] complexData = new Complex[n]
... fill data, fft etc ...
Vector vectorReference = new DenseVector(complexData);
vectorReference = vectorReference.Conjugate(); // Error.
error CS0266: Cannot implicitly convert type '
MathNet.Numerics.LinearAlgebra.Generic.Vector<System.Numerics.Complex>
' to 'MathNet.Numerics.LinearAlgebra.Complex.Vector
'
Why are the return values of methods that operate on Vector
s (e.g. Conjugate
and PointwiseMultiply
) not assignable to Vector
s?