VectorExtensions Class Reference

Extensions for vector-like data. More...

List of all members.

Static Public Member Functions

static double EuclideanNorm (this ICollection< float > vector)
 Compute the Euclidean norm of a collection of floats.
static double EuclideanNorm (this ICollection< double > vector)
 Compute the Euclidean norm of a collection of doubles.
static void Inc (this IList< double > vector1, IList< float > vector2)
 Increment a vector by another one.
static void Inc (this IList< float > vector1, IList< float > vector2)
 Increment a vector by another one.
static void Inc (this IList< double > vector1, IList< double > vector2)
 Increment a vector by another one.
static void Init (this IList< float > vector, float val)
 Initialize a collection of floats with one value.
static void InitNormal (this IList< float > vector, double mean, double stddev)
 Initialize a collection of floats with values from a normal distribution.
static void InitNormal (this IList< double > vector, double mean, double stddev)
 Initialize a collection of doubles with values from a normal distribution.
static double L1Norm (this ICollection< double > vector)
 Compute the L1 norm of a collection of doubles.
static void Multiply (this IList< float > vector, double x)
 Multiply a vector by a scalar.
static void Multiply (this IList< float > vector, float x)
 Multiply a vector by a scalar.
static void Multiply (this IList< double > vector, double x)
 Multiply a vector by a scalar.

Detailed Description

Extensions for vector-like data.


Member Function Documentation

static double EuclideanNorm ( this ICollection< float >  vector  )  [inline, static]

Compute the Euclidean norm of a collection of floats.

Parameters:
vector the vector to compute the norm for
Returns:
the Euclidean norm of the vector
static double EuclideanNorm ( this ICollection< double >  vector  )  [inline, static]

Compute the Euclidean norm of a collection of doubles.

Parameters:
vector the vector to compute the norm for
Returns:
the Euclidean norm of the vector
static void Inc ( this IList< double >  vector1,
IList< float >  vector2 
) [inline, static]

Increment a vector by another one.

Parameters:
vector1 the vector to be incremented
vector2 the vector to be added to the first one
static void Inc ( this IList< float >  vector1,
IList< float >  vector2 
) [inline, static]

Increment a vector by another one.

Parameters:
vector1 the vector to be incremented
vector2 the vector to be added to the first one
static void Inc ( this IList< double >  vector1,
IList< double >  vector2 
) [inline, static]

Increment a vector by another one.

Parameters:
vector1 the vector to be incremented
vector2 the vector to be added to the first one
static void Init ( this IList< float >  vector,
float  val 
) [inline, static]

Initialize a collection of floats with one value.

Parameters:
vector the vector to initialize
val the value to set each element to
static void InitNormal ( this IList< float >  vector,
double  mean,
double  stddev 
) [inline, static]

Initialize a collection of floats with values from a normal distribution.

Parameters:
vector the vector to initialize
mean the mean of the normal distribution
stddev the standard deviation of the normal distribution
static void InitNormal ( this IList< double >  vector,
double  mean,
double  stddev 
) [inline, static]

Initialize a collection of doubles with values from a normal distribution.

Parameters:
vector the vector to initialize
mean the mean of the normal distribution
stddev the standard deviation of the normal distribution
static double L1Norm ( this ICollection< double >  vector  )  [inline, static]

Compute the L1 norm of a collection of doubles.

Parameters:
vector the vector to compute the norm for
Returns:
the L1 norm of the vector
static void Multiply ( this IList< float >  vector,
double  x 
) [inline, static]

Multiply a vector by a scalar.

Parameters:
vector the vector to be multiplied
x the scalar
static void Multiply ( this IList< float >  vector,
float  x 
) [inline, static]

Multiply a vector by a scalar.

Parameters:
vector the vector to be multiplied
x the scalar
static void Multiply ( this IList< double >  vector,
double  x 
) [inline, static]

Multiply a vector by a scalar.

Parameters:
vector the vector to be multiplied
x the scalar

The documentation for this class was generated from the following file:
Generated on Fri Mar 2 21:19:32 2012 for MyMediaLite by  doxygen 1.6.3