TMtxInt Class

Source: MtxVecInt.cs · Assembly: Dew.Math

public class TMtxInt : TAbstractMtxVecInt

Two dimensional array - matrix.

Use the matrix class to perform matix operations like multiplication addition, subtraction, solve a system of linear equations, compute eigenvalues, singular value decomposition, least squares solution, 2D FFT's, parallel 1D FFT's and more.

Properties

NameTypeDescription
BlockEndBooleanReturns true, if the currrent subrange of the vector was also the last subrange in the vector.
CacheIndexInt32For internal use only. Read to get the index of this object in object cache.
CapacityInt64Sizing the object will not allocate less than Capacity.
CapacityInBytesInt64Sizing the object will not allocate less than CapacityInBytes.
CapacityInElementsInt64Sizing the object will not allocate less than CapacityInElements.
CapacityStepDoubleSpecifies increment step for the Capacity property.
CaptionStringCaption.
ColsInt32Defines the number of matrix columns.
ColsBitCountInt32Defines number of bits stored in one row.
ConditionCheckBooleanEnables/disable inline condition checking.
FirstInt32First element in object Values array.
IntegerValuesStringReturns content as a string suitable for display as a tooltip.
IntPrecisionTIntPrecisionDefines internal storage precision which can be either 32, 16 or 8 bit.
IntPrecisionLockBooleanPrevents change to IntPrecision if Lock = True.
IsDoubleBooleanDefines the precision (single or double) of the floating point operations.
IsSubRangeBooleanSet to true after the SetSubIndex or SetSubRange call.
ItemInt32Access elements of the matrix without specifying the name of the property.
LastInt32Last element in object Values array.
LeadingColsInt32Defines the number of leading columns.
LengthInt32Defines the length in number of samples.
OnSetSizeTMtxNotifyEventCalled when object size changes.
PoolIndexInt32Internal.
RowsInt32Defines the number of matrix rows.
ScaleFactorInt32Specifies the power of two for the scale factor used by some methods.
TagInt32Stores an integer value as part of a TMtxVec object.
ValuesSerializationStringProvides serializatin of object content.

Methods

NameDescription
Abs (4)Absolute values.
Add (12)Add Src elements to calling vector elements.
AddAndMul (26)Compute (X + Y)*Z
AddScaled (10)Compute X + Y + Z*zScale
AddScaledC (4)Compute X + Y*yScale + zScalar
AddScaledSqr (4)Compute sqr(X + Y*yScale)
AdoptAdopts a pointer to one dimensional array.
BinaryAnd (8)Apply binary "and" between coresponding elements in Src and Self.
BinaryNot (4)Applies binary "not" operation to elements stored in the object.
BinaryOr (8)Apply binary "or" between coresponding elements in Src and Self.
BinarySearch (2)Finds a match for X in object values using binary search.
BinaryXor (8)Apply binary "xor" between coresponding elements in Src and Self.
BitPack (2)Packs integer storage matrix to bit storage.
BitShift (4)Apply binary shift by number of Bits to the left (positive) or right (negative) to elements in Src.
BitShiftLeft (4)Apply binary shift by number of Bits to the left to elements in Src.
BitShiftRight (4)Apply binary shift by number of Bits to the right to elements in Src.
BitSizeSizes the matrix according to bit storage required.
BitUnpack (2)Unpacks bit storage to specified integer storage.
BlockFinishDeinitializes block processing before the final block is processed.
BlockInit (3)Initializes block processing.
BlockNextObtains the next subrange of the data.
BlockSubRangeLevelReturns the current subrange stack level used by block processing functions.
ClearSets vector size to zero.
ColExchangeExchange matrix columns.
ColPermutePermute the columns of the Src matrix.
ConcatConcatenate an array of matrices to single matrix.
ConcatHorz (2)Concenates an array of matrices horizontally.
ConcatVert (2)Concenates an array of matrices vertically.
CondDisableSaves the current value of ConditionCheck property and sets it to false.
CondEnableSets the ConditionCheck property to whatever it was before the CondDisable was used.
Convert (2)Copy each of Vec elements to the calling object.
Copy (3)Copy the Mtx elements [MtxRow,MtxCol]..[MtxRow+NrRows-1,MtxCol+NrCols-1] to the calling matrix elements [Row,Col],,[Row+NrRows-1,Col+NrCols-1].
CopyFromArray (17)Sizes the matrix to match the size of the 2D array and copies all the values.
CopyToArray (19)Copies all matrix values to a 2D array.
CopyVec (2)Copies values from vector to a matrix.
CountInRange (2)Returns number of values within the interval.
CreateFromCacheObtain a pointer to a matrix from object cache.
ctorCreate a new TMtxInt object.
CumSum (4)Cumulative sum for each of the matrix columns.
DiagSets the matrix diagonal to values from the vector.
DifferenceDifference.
DisableSelectPrevents calls to Dew.Math.TMtxVecBase.Select.
DisableSubrangePrevents calls to Dew.Math.TMtxVecBase.SetSubRange.
Disown (2)Disowns a pointer to an array from calling matrix Values1D.
DivAndAdd (12)Compute X/Y + Z
DivAndSub (12)Compute X/Y - Z
Divide (12)Divide calling object elements with Src elements.
DivideBy (4)Divide Value with calling vector elements.
DivideC (2)Compute X / (Y*zScale)
EnableSelectEnables calls to Dew.Math.TMtxVecBase.Select.
EnableSubrangeEnables calls to Dew.Math.TMtxVecBase.SetSubRange.
EqualCompares two matrices.
EyeConstructs an eye matrix.
FindFinds a match for X in object values.
FindIndexes (2)Finds matching indexes. The b parameter is of Dew.Math.TMtxVecInt type.
FindIndexesAndLength (2)Finds matching indexes and returns their count. The b parameter is of Dew.Math.TMtxVecInt type.
FindMask (2)The b parameter is of Dew.Math.TMtxVecInt type.
FlipHor (2)Flips the matrix elements horizontally.
FlipVer (2)Flips the matrix elements vertically
FreeToCacheFrees the object.
GetObjectToByteArrayCopies object to an array of bytes.
GetSchemaReturns null.
IndexOfReturns the 1D index in to the matrix.
IsEqual (4)Compares all Vec elements with calling object elements and checks also Length and IntPrecision properties, if they match.
IsPinnedReturns true of the working memory is pinned.
KronThe Kronecker product between two vectors.
LoadFromFileReads the header information and the values array content from the file.
LoadFromStreamLoad the list from a stream.
LogicalNot (4)Applies logical "not" operation to elements stored in the object.
LowerTriangleConstructs lower triangular matrix.
Max (4)Maximum value.
MaxColsCompute maximum of each column.
MaxEvery (4)Vectorised maximum.
MaxMin (2)Calculate minimum and maximum in one procedure call.
MaxMinColsCompute maximum and minimum of each column.
MaxMinIdx (2)Calculate minimum, maximum and their indices in one procedure call.
MaxMinRowsCompute maximum and minimum of each row.
MaxRowsCompute maximum of each row.
Median (4)Median.
Min (4)Minimum value.
MinColsCompute minimum of each column.
MinEvery (4)Vectorised minimum.
MinRowsCompute minimum of each row.
Mul (4)Compute X*Y*Z
MulAndAdd (14)Compute X*Y + Z
MulAndDiv (6)Compute X * Y / Z
MulAndSub (14)Compute X*Y - Z
MulElem (2)Matrix array multiplication.
Multiply (8)Multiply Src elements with calling vector elements.
ParseParses string content as vector.
PBValues (2)Returns a pointer to the real value stored at Row and Col.
PinPin down internal data structures for GC.
PIValues (2)Returns a pointer to the real value stored at Row and Col.
PSValues (2)Returns a pointer to the real value stored at Row and Col.
PValuesObtains a pointer to the integer value of the vector at Index.
RampFills the calling vector elements [Index]..[Index+Len-1].
ReadHeaderReads the header information from a stream to object.
ReadValuesRead values content from stream to object.
ReadXmlRead the object from the .NET XML stream.
RemDiv (6)Divide all Src elements with Value elements and store result of division in the calling object and reminder in RemDst.
ResetFor internal use only. Used to return object to cache.
Resize (2)Performs resize of the calling matrix to NewRows and NewCols.
ResizeAndTransposeResize and transpose.
Reverse (2)Reverse vector elements.
Rotate (2)A cyclic shift on vector elements in range.
Rotate90 (2)Rotates matrix Rows 90 degrees clockwise.
RowExchangeExchanges two matrix Rows.
RowPermutePermute the Rows of the Src matrix.
SaveToFileWrite object header and values to a file.
SaveToMatrixMarketFileSaves matrix data to MatrixMarket ASCII file format.
SaveToStreamSave the list to a stream.
ScatterScatter object elements.
ScatterByIncrScatters Src elements starting at Offset and with Increment to the calling object.
ScatterByIndexesScatters Src elements defined with indices stored in Indexes to the calling object.
ScatterByMaskScatters Src elements defined with the Mask to the calling object.
Select (2)Resets the selection.
SelectAllResets any defined selection.
SetCol (2)Copies values from vector to matrix column.
SetFullRangeResets subrange defined with SetSubRange.
SetFullRangeLevelPops the current subrange stack one level up.
SetItSets matrix values.
SetObjectFromByteArrayReads the properties of the object from the array of bytes.
SetRow (2)Copies values from vector to matrix row.
SetSubIndexDefines a subarray.
SetSubRange (4)Sets the subarray size to full size.
SetSubRangeLevel (2)Defines a sub vector/matrix of Src and pushes any previous subranges on to a stack.
SetVal (3)Initializes matrix values to Value.
SetZero (3)Initializes matrix values to zero.
Shift (2)A shift on vector elements in range.
Size (4)Specifies size of an integer matrix.
SizeFromArray (3)Sizes the calling matrix to match the size of the array.
SizeToArray (11)Sizes the Dst array to match the size of the matrix.
SortAscend (4)Sorts the elements in a matrix row(s) in ascending order.
SortDescend (4)Sorts the elements in a matrix row(s) in descending order.
SplitSplits matrix in blocks.
SqrAddScaled (4)Compute sqr(X) + sqr(Y)*yScale
StringsToValues (3)Convert strings to integers and store them in the Values array.
Sub (4)Compute X - Y - Z
SubAndMul (26)Compute (X - Y)*Z
SubRangeLevelReturns the current subrange stack level.
SubScaled (6)Compute X - Y - Z*zScale
SubScaledC (4)Compute X - Y*yScale - zScalar
Subtract (8)Subtract all Src elements from calling vector elements.
SubtractFrom (4)Subtract all calling vector elements from integer Value.
Sum (2)Sums vector values.
SumColsCalculates the sum of each of the calling matrix columns.
SumRowsCalculates the sum of each of the calling matrix Rows.
TensorProdCalculates the tensor product of two vectors.
ThreshAbsGT (4)Perform threshold operation on all Src object values.
ThreshAbsLT (4)Perform threshold operation on all Src object values.
ThreshBottom (4)Perform threshold operation on all Src object values.
ThresholdGT_LT (4)Threshold greater than and less than operation.
ThreshTop (4)Perform threshold operation on all Src object values.
ToStringReturns content as a string.
Transp (2)Transposes matrix.
UnPinUnpin internal data structures for GC.
UpperTriangleConstructs upper triangular matrix.
ValuesToStrings (3)Convert calling matrix elements, starting with [Row,Col] and up to [Row+RowCount-1,Col+ColCount-1] elements to strings.
ValuesToText (2)Converts Row..Col to Row+RowCount..Col+ColCount matrix elements to string.
WriteHeaderWrites the header information for the calling vector to a stream.
WriteXmlWrite the object to the .NET XML stream.

Operators

NameDescription
op_Implicit (3)Implicit conversion from TMtxInt to Span<Byte>.

Events

NameDescription
OnSetSizeEventCalled when object size changes.