LAL  7.5.0.1-b72065a
VectorMath.h File Reference

Prototypes

Failsafe Aligned Memory Handling
UINT4VectorAlignedXLALCreateUINT4VectorAligned (const UINT4 length, const UINT4 align)
 Create a new UINT4VectorAligned struct with length length and alignment align. More...
 
UINT4VectorAlignedXLALResizeUINT4VectorAligned (UINT4VectorAligned *in, const UINT4 length, const UINT4 align)
 Resize an existing UINT4VectorAligned struct to length length and alignment align. More...
 
void XLALDestroyUINT4VectorAligned (UINT4VectorAligned *in)
 Free a UINT4VectorAligned struct. More...
 
REAL4VectorAlignedXLALCreateREAL4VectorAligned (const UINT4 length, const UINT4 align)
 Create a new REAL4VectorAligned struct with length length and alignment align. More...
 
REAL4VectorAlignedXLALResizeREAL4VectorAligned (REAL4VectorAligned *in, const UINT4 length, const UINT4 align)
 Resize an existing REAL4VectorAligned struct to length length and alignment align. More...
 
void XLALDestroyREAL4VectorAligned (REAL4VectorAligned *in)
 Free a REAL4VectorAligned struct. More...
 
REAL8VectorAlignedXLALCreateREAL8VectorAligned (const UINT4 length, const UINT4 align)
 Create a new REAL8VectorAligned struct with length length and alignment align. More...
 
REAL8VectorAlignedXLALResizeREAL8VectorAligned (REAL8VectorAligned *in, const UINT4 length, const UINT4 align)
 Resize an existing REAL8VectorAligned struct to length length and alignment align. More...
 
void XLALDestroyREAL8VectorAligned (REAL8VectorAligned *in)
 Free a REAL8VectorAligned struct. More...
 
COMPLEX8VectorAlignedXLALCreateCOMPLEX8VectorAligned (const UINT4 length, const UINT4 align)
 Create a new COMPLEX8VectorAligned struct with length length and alignment align. More...
 
COMPLEX8VectorAlignedXLALResizeCOMPLEX8VectorAligned (COMPLEX8VectorAligned *in, const UINT4 length, const UINT4 align)
 Resize an existing COMPLEX8VectorAligned struct to length length and alignment align. More...
 
void XLALDestroyCOMPLEX8VectorAligned (COMPLEX8VectorAligned *in)
 Free a COMPLEX8VectorAligned struct. More...
 
COMPLEX16VectorAlignedXLALCreateCOMPLEX16VectorAligned (const UINT4 length, const UINT4 align)
 Create a new COMPLEX16VectorAligned struct with length length and alignment align. More...
 
COMPLEX16VectorAlignedXLALResizeCOMPLEX16VectorAligned (COMPLEX16VectorAligned *in, const UINT4 length, const UINT4 align)
 Resize an existing COMPLEX16VectorAligned struct to length length and alignment align. More...
 
void XLALDestroyCOMPLEX16VectorAligned (COMPLEX16VectorAligned *in)
 Free a COMPLEX16VectorAligned struct. More...
 
Vector Math Functions
int XLALVectorINT4FromREAL4 (INT4 *out, const REAL4 *in, const UINT4 len)
 Cast (i.e. More...
 
int XLALVectorSinREAL4 (REAL4 *out, const REAL4 *in, const UINT4 len)
 Compute \(\text{out} = \sin(\text{in})\) over REAL4 vectors out, in with len elements. More...
 
int XLALVectorCosREAL4 (REAL4 *out, const REAL4 *in, const UINT4 len)
 Compute \(\text{out} = \cos(\text{in})\) over REAL4 vectors out, in with len elements. More...
 
int XLALVectorExpREAL4 (REAL4 *out, const REAL4 *in, const UINT4 len)
 Compute \(\text{out} = \exp(\text{in})\) over REAL4 vectors out, in with len elements. More...
 
int XLALVectorLogREAL4 (REAL4 *out, const REAL4 *in, const UINT4 len)
 Compute \(\text{out} = \log(\text{in})\) over REAL4 vectors out, in with len elements. More...
 
int XLALVectorRoundREAL4 (REAL4 *out, const REAL4 *in, const UINT4 len)
 Compute \(\text{out} = round ( \text{in} )\) over REAL4 vectors out, in with len elements. More...
 
int XLALVectorRoundREAL8 (REAL8 *out, const REAL8 *in, const UINT4 len)
 Compute \(\text{out} = round ( \text{in} )\) over REAL8 vectors out, in with len elements. More...
 
int XLALVectorSinCosREAL4 (REAL4 *out1, REAL4 *out2, const REAL4 *in, const UINT4 len)
 Compute \(\text{out1} = \sin(\text{in}), \text{out2} = \cos(\text{in})\) over REAL4 vectors out1, out2, in with len elements. More...
 
int XLALVectorSinCos2PiREAL4 (REAL4 *out1, REAL4 *out2, const REAL4 *in, const UINT4 len)
 Compute \(\text{out1} = \sin(2\pi \text{in}), \text{out2} = \cos(2\pi \text{in})\) over REAL4 vectors out1, out2, in with len elements. More...
 
Vector by Vector Operations
int XLALVectorAddREAL4 (REAL4 *out, const REAL4 *in1, const REAL4 *in2, const UINT4 len)
 Compute \(\text{out} = \text{in1} + \text{in2}\) over REAL4 vectors in1 and in2 with len elements. More...
 
int XLALVectorSubREAL4 (REAL4 *out, const REAL4 *in1, const REAL4 *in2, const UINT4 len)
 Compute \(\text{out} = \text{in1} - \text{in2}\) over REAL4 vectors in1 and in2 with len elements. More...
 
int XLALVectorMultiplyREAL4 (REAL4 *out, const REAL4 *in1, const REAL4 *in2, const UINT4 len)
 Compute \(\text{out} = \text{in1} \times \text{in2}\) over REAL4 vectors in1 and in2 with len elements. More...
 
int XLALVectorMaxREAL4 (REAL4 *out, const REAL4 *in1, const REAL4 *in2, const UINT4 len)
 Compute \(\text{out} = max ( \text{in1}, \text{in2} )\) over REAL4 vectors in1 and in2 with len elements. More...
 
int XLALVectorAddREAL8 (REAL8 *out, const REAL8 *in1, const REAL8 *in2, const UINT4 len)
 Compute \(\text{out} = \text{in1} + \text{in2}\) over REAL8 vectors in1 and in2 with len elements. More...
 
int XLALVectorSubREAL8 (REAL8 *out, const REAL8 *in1, const REAL8 *in2, const UINT4 len)
 Compute \(\text{out} = \text{in1} - \text{in2}\) over REAL8 vectors in1 and in2 with len elements. More...
 
int XLALVectorMultiplyREAL8 (REAL8 *out, const REAL8 *in1, const REAL8 *in2, const UINT4 len)
 Compute \(\text{out} = \text{in1} \times \text{in2}\) over REAL8 vectors in1 and in2 with len elements. More...
 
int XLALVectorMaxREAL8 (REAL8 *out, const REAL8 *in1, const REAL8 *in2, const UINT4 len)
 Compute \(\text{out} = max ( \text{in1}, \text{in2} )\) over REAL8 vectors in1 and in2 with len elements. More...
 
int XLALVectorMultiplyCOMPLEX8 (COMPLEX8 *out, const COMPLEX8 *in1, const COMPLEX8 *in2, const UINT4 len)
 Compute \(\text{out} = \text{in1} \times \text{in2}\) over COMPLEX8 vectors in1 and in2 with len elements. More...
 
int XLALVectorAddCOMPLEX8 (COMPLEX8 *out, const COMPLEX8 *in1, const COMPLEX8 *in2, const UINT4 len)
 Compute \(\text{out} = \text{in1} + \text{in2}\) over COMPLEX8 vectors in1 and in2 with len elements. More...
 
Vector by Scalar Operations
int XLALVectorShiftREAL4 (REAL4 *out, REAL4 scalar, const REAL4 *in, const UINT4 len)
 Compute \(\text{out} = \text{scalar} + \text{in}\) over REAL4 vector in with len elements. More...
 
int XLALVectorScaleREAL4 (REAL4 *out, REAL4 scalar, const REAL4 *in, const UINT4 len)
 Compute \(\text{out} = \text{scalar} \times \text{in}\) over REAL4 vector in with len elements. More...
 
int XLALVectorScaleREAL8 (REAL8 *out, REAL8 scalar, const REAL8 *in, const UINT4 len)
 Compute \(\text{out} = \text{scalar} \times \text{in}\) over REAL8 vector in with len elements. More...
 
int XLALVectorShiftREAL8 (REAL8 *out, REAL8 scalar, const REAL8 *in, const UINT4 len)
 Compute \(\text{out} = \text{scalar} + \text{in}\) over REAL8 vector in with len elements. More...
 
int XLALVectorScaleCOMPLEX8 (COMPLEX8 *out, COMPLEX8 scalar, const COMPLEX8 *in, const UINT4 len)
 Compute \(\text{out} = \text{scalar} \times \text{in}\) over COMPLEX8 vector in with len elements. More...
 
int XLALVectorShiftCOMPLEX8 (COMPLEX8 *out, COMPLEX8 scalar, const COMPLEX8 *in, const UINT4 len)
 Compute \(\text{out} = \text{scalar} + \text{in}\) over COMPLEX8 vector in with len elements. More...
 
Vector Element Finding Operations
int XLALVectorFindVectorLessEqualREAL4 (UINT4 *count, UINT4 *out, const REAL4 *in1, const REAL4 *in2, const UINT4 len)
 Count and return indexes (in count and out respectively) of vector elements where \(\text{in1} \le \text{in2}\). More...
 
int XLALVectorFindScalarLessEqualREAL4 (UINT4 *count, UINT4 *out, REAL4 scalar, const REAL4 *in, const UINT4 len)
 Count and return indexes (in count and out respectively) of vector elements where \(\text{scalar} \le \text{in2}\). More...
 

Go to the source code of this file.

Data Structures

struct  UINT4VectorAligned
 A special UINT4Vector with n-byte aligned memory data array. More...
 
struct  REAL4VectorAligned
 A special REAL4Vector with n-byte aligned memory data array. More...
 
struct  REAL8VectorAligned
 A special REAL8Vector with n-byte aligned memory data array. More...
 
struct  COMPLEX8VectorAligned
 A special COMPLEX8Vector with n-byte aligned memory data array. More...
 
struct  COMPLEX16VectorAligned
 A special COMPLEX16Vector with n-byte aligned memory data array. More...