casacore
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Modules | Classes | Enumerations

A module implementing multidimensional arrays and operations. More...

Modules

 Arrays_module_internal_classes
 Internal Arrays_module classes and functions.
 

Classes

class  casacore::Array< T >
 template <class T, class U> class vector; More...
 
class  casacore::ArrayAccessor< T, Axis< U > >
 Fast 1D accessor/iterator for nD array classes. More...
 
class  casacore::ArrayAccessor_RT< T, AxisN >
 Specialization for run-time axes. More...
 
class  casacore::ArrayBase
 Non-templated base class for templated Array class. More...
 
class  casacore::ArrayError
 The base class for all Array exception classes. More...
 
class  casacore::ArrayIndexError
 An error thrown when an index is out of range. More...
 
class  casacore::ArrayConformanceError
 An error thrown when two arrays do not conform. More...
 
class  casacore::ArrayNDimError
 Thrown when two arrays have different dimensionality. More...
 
class  casacore::ArrayShapeError
 An error thrown when two arrays have different shapes. More...
 
class  casacore::ArrayIteratorError
 An error thrown by an ArrayIterator. More...
 
class  casacore::ArraySlicerError
 An error thrown by an Slicer member function. More...
 
struct  casacore::ArrayIO_global_functions_Array_IO
 Input/output operators for Arrays. More...
 
struct  casacore::ArrayIO_global_functions_Array_binary_IO
 Global functions to read/write binary arrays from/to a file. More...
 
struct  casacore::ArrayIO_global_functions_Array_Ascii_IO
 Global functions for Matrix/Vector input/output using ASCII format. More...
 
class  casacore::ArrayIterator< T >
 Iterate an Array cursor through another Array. More...
 
class  casacore::ReadOnlyArrayIterator< T >
 Iterate a const Array cursor through a const Array. More...
 
struct  casacore::ArrayLogical_global_functions_Array_logical_operations
 Logical operations for Arrays. More...
 
struct  casacore::ArrayMath_global_functions_Array_mathematical_operations
 Mathematical operations for Arrays. More...
 
class  casacore::ArrayFunctorBase< T, RES >
 Basic class for math on Array objects. More...
 
struct  casacore::ArrayOpsDiffShapes_global_functions_OpsDiff_functions
 Operations for 2 Arrays with possibly different shapes. More...
 
struct  casacore::ArrayPartMath_global_functions_Array_partial_operations
 Mathematical and logical operations for Array parts. More...
 
class  casacore::ArrayPositionIterator
 Iterate an IPosition through the shape of an Array. More...
 
struct  casacore::ArrayUtil_global_functions_stringToVector
 Split a String into its elements. More...
 
struct  casacore::ArrayUtil_global_functions_concatenateArray
 Concatenate two Arrays. More...
 
struct  casacore::ArrayUtil_global_functions_partialFuncHelper
 Helper function for partialX functions. More...
 
struct  casacore::ArrayUtil_global_functions_reverseArray
 Reverse the order of one or more axes of an array. More...
 
struct  casacore::ArrayUtil_global_functions_reorderArray
 Reorder the axes of an array. More...
 
class  casacore::AxesSpecifier
 Specification of axes to keep or remove. More...
 
class  casacore::Cube< T >
 A 3-D Specialization of the Array class. More...
 
class  casacore::IPosition
 A Vector of integers, for indexing into Array<T> objects. More...
 
struct  casacore::IPosition_global_functions_IPosition_Arithmetic
 Arithmetic Operations for IPosition's Element by element arithmetic on IPositions. More...
 
struct  casacore::IPosition_global_functions_IPosition_Logical
 Logical operations for IPosition's Element by element boolean operations on IPositions. More...
 
struct  casacore::IPosition_global_functions_IPosition_Indexing
 Indexing functions for IPosition's Convert between IPosition and offset in an array. More...
 
struct  casacore::LogiArray_global_functions_LogicalArray
 Logical valued Arrays. More...
 
struct  casacore::LogiArrayFwd_global_functions_LogicalArray_forwards
 Forward declarations for LogicalArrays. More...
 
struct  casacore::LogiCube_global_functions_LogicalCube
 Logical valued Cubes. More...
 
struct  casacore::LogiMatrix_global_functions_LogicalMatrix
 Logical valued Matrices. More...
 
struct  casacore::LogiVector_global_functions_LogicalVector
 Logical valued Vectors. More...
 
struct  casacore::MaskArrIO_global_functions_MaskedArray_IO
 Ascii input/output operations for MaskedArrays. More...
 
struct  casacore::MaskArrLogi_global_functions_MaskedArray_logical_operations
 Logical operations for MaskedArrays, and between MaskedArrays and Arrays. More...
 
struct  casacore::MaskArrMath_global_functions_MaskedArray_mathematical_operations
 Mathematical operations for MaskedArrays (and with Arrays) More...
 
class  casacore::MaskedArray< T >
 Class for masking an Array for operations on that Array. More...
 
struct  casacore::MaskedArray_global_functions_MaskedArray_general_global_functions
 General global functions for MaskedArrays, and MaskedArrays and Arrays. More...
 
struct  casacore::MaskLogiArr_global_functions_MaskedLogicalArray
 Masked LogicalArrays. More...
 
struct  casacore::MaskLogiArrFwd_global_functions_MaskedLogicalArray_forwards
 Forward declarations for MaskedLogicalArrays. More...
 
class  casacore::Matrix< T >
 A 2-D Specialization of the Array class. More...
 
class  casacore::MatrixIterator< T >
 Iterate a Matrix cursor through another Array. More...
 
class  casacore::ReadOnlyMatrixIterator< T >
 Iterate a Matrix cursor through a R/O Array. More...
 
struct  casacore::MatrixMath_global_functions_Linear_Algebra
 Linear algebra functions on Vectors and Matrices. More...
 
class  casacore::Slice
 define a (start,length,increment) along an axis More...
 
class  casacore::Slicer
 Specify which elements to extract from an n-dimensional array. More...
 
struct  casacore::Slicer_global_functions_Slicer_IO
 IO functions for Slicer's. More...
 
class  casacore::Vector< T >
 A 1-D Specialization of the Array class. More...
 
class  casacore::VectorIterator< T >
 Iterate an Vector cursor through another Array. More...
 
class  casacore::ReadOnlyVectorIterator< T >
 Iterate a Vector cursor through another Array. More...
 
class  casacore::VectorSTLIterator< T >
 Casacore Vector iterator. More...
 

Enumerations

enum  casacore::StorageInitPolicy {
  casacore::COPY,
  casacore::TAKE_OVER,
  casacore::SHARE
}
 A global enum used by some Array constructors. More...
 
size_t casacore::ArrayVolume (uInt Ndim, const Int *Shape)
 General global functions for Arrays. More...
 
size_t casacore::ArrayIndexOffset (uInt Ndim, const ssize_t *Shape, const ssize_t *Origin, const ssize_t *Inc, const IPosition &Index)
 What is the linear index into an "Ndim" dimensional array of the given "Shape", "Origin", and "Increment" for a given IPosition Index. More...
 
size_t casacore::ArrayIndexOffset (uInt Ndim, const ssize_t *Shape, const ssize_t *Inc, const IPosition &Index)
 
void casacore::throwArrayShapes (const IPosition &shape1, const IPosition &shape2, const char *name)
 Function to check the shapes. More...
 
void casacore::checkArrayShapes (const ArrayBase &left, const ArrayBase &right, const char *name)
 

Detailed Description

A module implementing multidimensional arrays and operations.

See below for an overview of the classes in this module.

Review Status

Reviewed By:
UNKNOWN
Date Reviewed:
before2004/08/25

Etymology

This module provides classes and global functions for multidimensional arrays.

Synopsis

Arrays have traditionally played an important role in scientific computation. While it is certainly true that some of the reliance on arrays was due to the paucity of other data structures in FORTRAN, it is also true that computation on arrays reflects the common occurrence of regularly sampled multi-dimensioned data in science.

The Lattices are a generalization of Arrays. They can handle memory- and disk-based arrays as well as other types of arrays (eg. expressions).

The module consists of various parts:

The detailed discussions for the classes and global functions will describe how to use them.

Enumeration Type Documentation

A global enum used by some Array constructors.

Synopsis

StorageInitPolicy is used in functions where an array is formed from a shape and an ordinary pointer. This enum should be in Array but that causes gcc to be unhappy.

Enumerator
COPY 

COPY is used when an internal copy of the storage is to be made.

The array is NOT responsible for deleting the external storage.

TAKE_OVER 

TAKE_OVER is used to indicate that the Array should just use the external storage (i.e., no copy is made).

The Array class is now responsible for deleting the storage (hence it must have come from a call to new[]).

SHARE 

Share means that the Array will just use the pointer (no copy), however the Array will NOT delete it upon destruction.

Definition at line 53 of file ArrayBase.h.

Function Documentation

size_t casacore::ArrayIndexOffset ( uInt  Ndim,
const ssize_t *  Shape,
const ssize_t *  Origin,
const ssize_t *  Inc,
const IPosition &  Index 
)

What is the linear index into an "Ndim" dimensional array of the given "Shape", "Origin", and "Increment" for a given IPosition Index.

An Array helper function.

size_t casacore::ArrayIndexOffset ( uInt  Ndim,
const ssize_t *  Shape,
const ssize_t *  Inc,
const IPosition &  Index 
)
size_t casacore::ArrayVolume ( uInt  Ndim,
const Int *  Shape 
)

General global functions for Arrays.

Review Status

Reviewed By:
UNKNOWN
Date Reviewed:
before2004/08/25
Test programs:
tArray

Prerequisite

Synopsis

These are generally useful global functions which operate on all Arrays.

What is the volume of an N-dimensional array. Shape[0]*Shape[1]*...*Shape[N-1]. An Array helper function.

void casacore::checkArrayShapes ( const ArrayBase &  left,
const ArrayBase &  right,
const char *  name 
)
inline
void casacore::throwArrayShapes ( const IPosition &  shape1,
const IPosition &  shape2,
const char *  name 
)

Function to check the shapes.

It throws an exception if not equal.

Referenced by casacore::checkArrayShapes().