Functions

Vector Structures and Operations.

Functions

NTTW_DLL_SYM vector vector_2D ()
 Constructs a 2 dimensional vector and returns it.
NTTW_DLL_SYM vector vector_2D_Set (const long x, const long y)
 Constructs a 2 dimensional vector and returns it.
NTTW_DLL_SYM vectorvectorArray_2D (const size_t size)
 Constructs a 2 dimensional vector and returns it.
NTTW_DLL_SYM long getComponent (const vector inVector, const int j)
 Returns the $ x_j $ coordinate/component of the vector.
NTTW_DLL_SYM void setComponent (vector inVector, const int j, const long value)
 Sets component j of inVector to value provided.
NTTW_DLL_SYM long getX (const vector inVector)
 Returns the x component of the vector inVector.
NTTW_DLL_SYM void setX (vector inVector, const long value)
 Sets the x component of the vector inVector.
NTTW_DLL_SYM long getY (const vector inVector)
 Returns the y component of the vector inVector.
NTTW_DLL_SYM void setY (vector inVector, const long value)
 Sets the y component of the vector inVector.
NTTW_DLL_SYM void setXY (vector inVector, const long xValue, const long yValue)
 Sets the x and y components of the vector inVector.
NTTW_DLL_SYM void free_vector (vector vec)
 Free/Deallocates memory of the vector vec.
NTTW_DLL_SYM void free_vectorArray (vector *matrix, const size_t size)
 Free/Deallocates memory used by vector array provided.

Function Documentation

free_vector ( vector  vec  ) 

Free/Deallocates memory of the vector vec.

Definition at line 95 of file vector.c.

free_vectorArray ( vector matrix,
const size_t  size 
)

Free/Deallocates memory used by vector array provided.

Definition at line 100 of file vector.c.

getComponent ( const vector  inVector,
const int  j 
)

Returns the $ x_j $ coordinate/component of the vector.

Definition at line 59 of file vector.c.

getX ( const vector  inVector  ) 

Returns the x component of the vector inVector.

Definition at line 69 of file vector.c.

getY ( const vector  inVector  ) 

Returns the y component of the vector inVector.

Definition at line 79 of file vector.c.

setComponent ( vector  inVector,
const int  j,
const long  value 
)

Sets component j of inVector to value provided.

Definition at line 64 of file vector.c.

setX ( vector  inVector,
const long  value 
)

Sets the x component of the vector inVector.

Definition at line 74 of file vector.c.

setXY ( vector  inVector,
const long  xValue,
const long  yValue 
)

Sets the x and y components of the vector inVector.

Definition at line 89 of file vector.c.

setY ( vector  inVector,
const long  value 
)

Sets the y component of the vector inVector.

Definition at line 84 of file vector.c.

vector vector_2D (  ) 

Constructs a 2 dimensional vector and returns it.

Use the free() operation from <stdlib.h> to delete it.

Definition at line 28 of file vector.c.

vector vector_2D_Set ( const long  x,
const long  y 
)

Constructs a 2 dimensional vector and returns it.

Use the free() operation from <stdlib.h> to delete it.

Definition at line 37 of file vector.c.

vector vectorArray_2D ( const size_t  size  ) 

Constructs a 2 dimensional vector and returns it.

Use the free() operation from <stdlib.h> to delete it.

Definition at line 46 of file vector.c.