seq_linear Class Reference
[Data Grids and Sequences]

Collaboration diagram for seq_linear:
Collaboration graph
[legend]

Detailed Description

Sequence defined by an evenly spaced grid of points.

Designed to serve the same function as the a=1:2:N Matlab construct.


Constructor & Destructor Documentation

seq_linear ( value_type  first,
value_type  temp,
size_type  size,
bool  first_last = false 
) [inline]

Construct sequence using first value, increment/last, and size.

Parameters:
first Value at start of sequence.
temp Increment or the last value in the sequence.
size Number of elements in this sequence.
first_last if true, the second constructor element is the last value in the sequence, otherwise it is the increment value.
seq_linear ( value_type  first,
value_type  increment,
int  size 
) [inline]

Construct sequence using first value, increment, and size.

Parameters:
first Value at start of sequence.
increment Spacing between elements.
size Number of elements in this sequence.
seq_linear ( value_type  first,
value_type  increment,
value_type  last 
) [inline]

Construct sequence using first value, increment value, and last value.

If last value is not part of the sequence, the sequence will end on a value <= last. All sequences constructed in this way have at least a single value.

Parameters:
first Value at start of sequence.
increment Spacing between elements.
last Value at end of sequence.
seq_linear ( const seq_linear copy  )  [inline]

Copies data from another sequence object.

Parameters:
copy The object to be copied.
virtual ~seq_linear (  )  [inline, virtual]

Virtual destructor.


Member Function Documentation

virtual seq_vector* clone (  )  const [inline, virtual]

Create a copy using a reference to the base class.

Implements seq_vector.

virtual size_type find_index ( value_type  value  )  [inline, virtual]

Search for a value in this sequence.

If the value is outside of the legal range, the index for the nearest endpoint will be returned.

Parameters:
value Value of the element to find.
Returns:
Index of the largest value that is not greater than the argument.

Implements seq_vector.

void initialize ( value_type  first,
value_type  increment,
size_type  size 
) [inline, private]

Construct sequence using first value, increment, and size.

Parameters:
first Value at start of sequence.
increment Spacing between elements.
size Number of elements in this sequence.

Generated on 4 May 2015 for USML by  doxygen 1.6.1