Types in MathNet.Numerics

Type Sorting

Namespace MathNet.Numerics

Sorting algorithms for single, tuple and triple lists.

Public Static Functions

voidSort<T>(IList<T> keys, IComparer<T> comparer)

Sort a list of keys, in place using the quick sort algorithm using the quick sort algorithm.
Parameters

List to sort.

`IComparer<T>` comparer

Comparison, defining the sort order.

voidSort<T>(IList<T> keys, int index, int count, IComparer<T> comparer)

Sort a range of a list of keys, in place using the quick sort algorithm.
Parameters

List to sort.

`int` index

The zero-based starting index of the range to sort.

`int` count

The length of the range to sort.

`IComparer<T>` comparer

Comparison, defining the sort order.

voidSort<TKey, TItem>(IList<TKey> keys, IList<TItem> items, IComparer<TKey> comparer)

Sort a list of keys and items with respect to the keys, in place using the quick sort algorithm.
Parameters

List to sort.

`IList<TItem>` items

List to permute the same way as the key list.

`IComparer<TKey>` comparer

Comparison, defining the sort order.

voidSort<TKey, TItem>(IList<TKey> keys, IList<TItem> items, int index, int count, IComparer<TKey> comparer)

Sort a list of keys and items with respect to the keys, in place using the quick sort algorithm.
Parameters

List to sort.

`IList<TItem>` items

List to permute the same way as the key list.

`int` index

The zero-based starting index of the range to sort.

`int` count

The length of the range to sort.

`IComparer<TKey>` comparer

Comparison, defining the sort order.

voidSort<TKey, TItem1, TItem2>(IList<TKey> keys, IList<TItem1> items1, IList<TItem2> items2, IComparer<TKey> comparer)

Sort a list of keys, items1 and items2 with respect to the keys, in place using the quick sort algorithm.
Parameters

List to sort.

`IList<TItem1>` items1

First list to permute the same way as the key list.

`IList<TItem2>` items2

Second list to permute the same way as the key list.

`IComparer<TKey>` comparer

Comparison, defining the sort order.

voidSort<TKey, TItem1, TItem2>(IList<TKey> keys, IList<TItem1> items1, IList<TItem2> items2, int index, int count, IComparer<TKey> comparer)

Sort a list of keys, items1 and items2 with respect to the keys, in place using the quick sort algorithm.
Parameters

List to sort.

`IList<TItem1>` items1

First list to permute the same way as the key list.

`IList<TItem2>` items2

Second list to permute the same way as the key list.

`int` index

The zero-based starting index of the range to sort.

`int` count

The length of the range to sort.

`IComparer<TKey>` comparer

Comparison, defining the sort order.

voidSortAll<T1, T2>(IList<T1> primary, IList<T2> secondary, IComparer<T1> primaryComparer, IComparer<T2> secondaryComparer)

Sort a list of keys and items with respect to the keys, in place using the quick sort algorithm.
Parameters

List to sort.

`IList<T2>` secondary

List to sort on duplicate primary items, and permute the same way as the key list.

`IComparer<T1>` primaryComparer

Comparison, defining the primary sort order.

`IComparer<T2>` secondaryComparer

Comparison, defining the secondary sort order.