NMath User's Guide

TOC | Previous | Next | Index

Chapter 5. Vector Classes (.NET, C#, CSharp, VB, Visual Basic, F#)

The NMath vector classes represent mathematical vectors of a particular datatype. Each class contains a reference to the data block they are viewing (see Chapter 4), along with the parameter values necessary to define their view:

the number of elements

a step increment, or stride, between elements of the data block

This is generally transparent to you. NMath provides indexers to perform the necessary indirection. For example, v[i] always returns the ith element of vector v's view of the data.

NOTE—Indexing starts at 0.