Questions tagged [mathnet-numerics]

Math.NET Numerics is an opensource numerical library for .Net, Silverlight and Mono.

Math.NET Numerics is the numerical foundation of the Math.NET project, aiming to provide methods and algorithms for numerical computations in science, engineering and every day use. Covered topics include special functions, linear algebra, probability models, random numbers, statistics, interpolation, integration, curve fitting, integral transforms (FFT) and more.

In addition to the core .NET package (which is written entirely in C#), Numerics specifically supports F# 3.0 with idiomatic extension modules and maintains mathematical data structures like BigRational that originated in the F# PowerPack. If a performance boost is needed, the managed-code provider backing its linear algebra routines and decompositions can be exchanged with wrappers for optimized native implementations such as Intel MKL.

Supports Mono and .NET 4.0 on Linux, Mac and Windows, the portable version also Silverlight 5, WindowsPhone 8 and .NET for Windows Store apps.

Source: GitHub: Math.NET Numerics ReadMe file

230 questions
1
vote
1 answer

Representing fractions in MathNet matrices

I am trying solve some matrices calculations using the MathNet.Numericslibraries. It all works fine with double numbers. However now I want to represent numbers as fractions and want to get the answers to the calculations as fractions. How can I do…
Herne
  • 77
  • 6
1
vote
1 answer

Which Formula/Function To Use to Rotate a Series Of Points

What mathematical formula can I use to rotate a series of 3d Vectors about a given 3d Vector? I am attempting to use the 3rd party library: Math.NET Iridium to calculate my rotations but I dont know what formulas or mathematical concepts I should…
sazr
  • 24,984
  • 66
  • 194
  • 362
1
vote
1 answer

How to format DelimitedReader in MathNet Numerics to read in empty strings as zero?

I'm reading from a CSV file that has a lot of empty cells and I want to read in the empty cells as zero. Is there a way to do this using DelimitedReader? I'm looking at the documentation for DelimitedReader and I see that it takes four…
covfefe
  • 2,485
  • 8
  • 47
  • 77
1
vote
1 answer

Keep getting runtime error from MathNet Numerics library. Can't seem to get it to work

I've been trying to get the MathNet.Numerics library to work. I keep getting this weird run time error every time I try to initialize a matrix. I have scoured the internet for post of similar problems, without any luck. This have made me believe…
Robert Erneborg
  • 69
  • 2
  • 12
1
vote
1 answer

Difference between methods Matrix Divide(double scalar) and Matrix DivideByThis(double scalar) in MathNet Numerics?

I'm looking at the documentation for DenseMatrix in MathNet Numerics which can be found here. I found two method definitions Matrix Divide(double scalar) and Matrix DivideByThis(double scalar) which both seem to return a Matrix and accept a…
covfefe
  • 2,485
  • 8
  • 47
  • 77
1
vote
1 answer

Multiple Linear Regression in C#

I want to make a multiple linear regression in C#. I am trying to achieve this with MathNet.Numerics, but I keep getting the error "Matrix dimensions must agree 2x3". /***************************************************** * MathNet.Numerics…
Christoph Bühler
  • 2,795
  • 2
  • 28
  • 43
1
vote
2 answers

Best way to use Math.NET statistics functions on the properties of objects in a List

I'm trying to figure out the best way to perform a computation fast and wanted to find out what sort of approach people would usually take in a situation like this. I have a List of objects which have properties that I want to compute the mean and…
rex
  • 3,133
  • 6
  • 35
  • 62
1
vote
1 answer

math.net DenseVectors vs DenseMatrix 1xn | nx1

This is really simple stuff but, as I am a noob with math.net, I may need to be pointed in the right direction: let a = new DenseVector([| 5.0; 2.0; 3.0; |]) let m = new DenseMatrix(3, 3, 1.0) let r = a * m let r2 = m * a results in: > r;; val it…
NoIdeaHowToFixThis
  • 4,484
  • 2
  • 34
  • 69
1
vote
1 answer

QR decomposition in Math.NET Numerics

How is QR decomposition implemented in Math.NET Numerics? Is it with Gram-Schimdt or with Givens rotations? I have a feeling that it is implemented with Gram-Schimdt, but I'm not sure. I can't find the implementation. Is QR decomposition with…
Stefan P.
  • 331
  • 6
  • 23
0
votes
2 answers

Error when using MathNet.Numerics Fit.Line with F# tuple type

I am working on a library in F# that calculates rheological parameters for a fluid using MathNet.Numerics. However, I'm encountering an issue when implementing the BinghamModel and GetBinghamModelFit functions. Here's the code I'm using: open…
0
votes
0 answers

Why can't Math.Net Numerics resolve creator?

Math.Net Numerics returning "Native Provider Probing failed to resolve creator" when trying to use MKL or OpenBLAS I'm trying to enable acceleration using either MKL or OpenBLAS on a Windows machine. I've added both Nuget packages, and it now…
Ben
  • 3
  • 3
0
votes
0 answers

Understand FFT generated by MathNet.Numerics

Below is the code I wrote to calculate FFT for a simple wave, 10 oscillations with 200 samples, as expected FFT gave the frequency as 20. But when I created a wave of 100 oscillations with 2000 samples I got a frequency of 200 instead of 20. Where…
codeDom
  • 1,623
  • 18
  • 54
0
votes
0 answers

Changing a struct to a class in a third party library that implements IXmlSerializable, IFormattable, and IEquatable

I need to do quite a bit 2D geometry work and have found a library that is absolutely perfect for my needs. The specific library is MathNet.Spatial which along with offering the exact functionality that I need, it integrates perfectly with the…
0
votes
0 answers

How fill MathNet.numerics from SQL database table?

I want to create a software to solve problems(find minimum cost). My question is: How to fill matrices and vectors in MathNet.numerics from SQL database table(int, double)? I have seen MathNet documentation, but they are not so helpful (there is no…
Amine
  • 1
  • 2
0
votes
0 answers

Assembly 'MathNet.Numerics' with identity "MathNet.Numerics' Version=5.0.0.0, Culture=neutral, PublicKeyToken=###' uses 'System.Runtime, Version=6.0.0

I'm using tickblaze, a software package that runs C# scripts for algorithmic trading. I want to run a strategy that uses linear algebra, so I need MathNet.Numerics package. I referenced MathNet.Numberics, but and I was getting the following…
Theron
  • 13
  • 4