interval_vector.c File Reference

Detailed Description

Definition of the functions operating on vectors of intervals.

See Also
interval_vector.h interval.c interval.h

Definition in file interval_vector.c.

Functions

void IntervalVectFromVector (unsigned int s, double *v, Tinterval *vi)
 Creates a vector of intervals. More...
 
void IntCosVector (unsigned int s, Tinterval *vi, Tinterval *ci)
 Interval cosine on a vector. More...
 
void IntSinVector (unsigned int s, Tinterval *vi, Tinterval *si)
 Interval sine on a vector. More...
 
void IntervalVectSumVectorScale (unsigned int s, Tinterval *v1, Tinterval *w, double *v2, Tinterval *v)
 Adds a scaled constant vector an an interval vector. More...
 
void IntervalVectDotProduct (unsigned int s, Tinterval *v1, Tinterval *v2, Tinterval *dp)
 Dot product between two interval vectors. More...
 

Function Documentation

void IntervalVectFromVector ( unsigned int  s,
double *  v,
Tinterval vi 
)

Creates a vector of intervals from a contant vector.

Parameters
sNumber of elements in the vector.
vThe vector of from where to get the initial values.
viThe interval vector to initialize. The space for this vector must be allocated externally.

Definition at line 13 of file interval_vector.c.

References NewInterval().

void IntCosVector ( unsigned int  s,
Tinterval vi,
Tinterval ci 
)

Compputes the interval cosine for all the elements of an interval vector.

Parameters
sNumber of elements in the vector.
viThe interval vector.
ciThe vector with the interval cosines (output, allocated externally).

Definition at line 22 of file interval_vector.c.

References IntervalCosine().

void IntSinVector ( unsigned int  s,
Tinterval vi,
Tinterval si 
)

Compputes the interval sine for all the elements of an interval vector.

Parameters
sNumber of elements in the vector.
viThe interval vector.
siThe vector with the interval sines (output, allocated externally).

Definition at line 30 of file interval_vector.c.

References IntervalCosine().

void IntervalVectSumVectorScale ( unsigned int  s,
Tinterval v1,
Tinterval w,
double *  v2,
Tinterval v 
)

Adds a scaled constant vector an an interval vector (v=v1+w*v2)

Parameters
sNumber of elements in the vector.
v1The interval vector to add.
wThe interval scale factor for v2.
v2The constant vector to add.
vThe resulting vector.

Definition at line 38 of file interval_vector.c.

References IntervalAdd(), and IntervalScale().

void IntervalVectDotProduct ( unsigned int  s,
Tinterval v1,
Tinterval v2,
Tinterval dp 
)

Dot product between two interval vectors.

Parameters
sNumber of elements in the vector.
v1The first interval vector to operate.
v2The second interval vector to operate.
dpThe resulting interval.

Definition at line 50 of file interval_vector.c.

References IntervalAdd(), IntervalProduct(), and NewInterval().