diff --git a/src/Numerics/LinearAlgebra/Storage/Indexers/Static/StaticStorageIndexer.cs b/src/Numerics/LinearAlgebra/Storage/Indexers/Static/StaticStorageIndexer.cs new file mode 100644 index 00000000..5237ab96 --- /dev/null +++ b/src/Numerics/LinearAlgebra/Storage/Indexers/Static/StaticStorageIndexer.cs @@ -0,0 +1,56 @@ +namespace MathNet.Numerics.LinearAlgebra.Storage.Indexers.Static +{ + /// + /// Classes that contain indexing information of a static storage scheme. + /// + /// + /// A static storage scheme is always the same and only depends on the size of the matrix. + /// + public abstract class StaticStorageIndexer : IStorageIndexer + { + /// + /// Gets the index of the given element. + /// + /// + /// The row of the element. + /// + /// + /// The column of the element. + /// + /// + /// This method is parameter checked. and to get values without parameter checking. + /// + public abstract int this[int row, int column] + { + get; + } + + /// + /// Gets the length of the stored data. + /// + public abstract int DataLength + { + get; + } + + /// + /// Retrieves the index of the requested element without parameter checking. + /// + /// The row of the element. + /// + /// The column of the element. + /// + /// The requested index. + /// + public abstract int IndexOf(int row, int column); + + /// + /// Retrieves the index of the requested diagonal element without parameter checking. + /// + /// The row=column of the diagonal element. + /// + /// The requested index. + /// + public abstract int IndexOfDiagonal(int row); + } +} diff --git a/src/Numerics/Numerics.csproj b/src/Numerics/Numerics.csproj index 36973819..4e1d798f 100644 --- a/src/Numerics/Numerics.csproj +++ b/src/Numerics/Numerics.csproj @@ -142,6 +142,7 @@ + @@ -481,9 +482,7 @@ - - - +