linearalgebra.numeric
Class SingleElementVector

java.lang.Object
  extended by linearalgebra.numeric.AbstractNumericVector
      extended by linearalgebra.numeric.SingleElementVector
All Implemented Interfaces:
java.lang.Cloneable, NumericVectorInterface, VectorInterface

public class SingleElementVector
extends AbstractNumericVector


Field Summary
private  int m_index
           
private  NumericVectorInterface m_vector
           
 
Constructor Summary
SingleElementVector(NumericVectorInterface proxy, int index)
           
 
Method Summary
 java.lang.Object clone()
           
 int getDimension()
           
 double getValue(int index)
           
 void setValue(int index, double value)
           
 void setValue(NumericVectorInterface v)
           
 double[] toArray()
           
 
Methods inherited from class linearalgebra.numeric.AbstractNumericVector
equals, getCosBetween, getInnerProduct, getLength, getLengthSquared, getMean, getRadiansBetween, getVariance, innerProduct, isLinearlyIndependent, isOrthogonal, isZero, linearCombination, linearCombinationDimension, linearCombinationEquals, minus, normalize, projectionOf, scale, scaleDimension, swapDimensions
 
Methods inherited from class java.lang.Object
finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

m_vector

private NumericVectorInterface m_vector

m_index

private int m_index
Constructor Detail

SingleElementVector

public SingleElementVector(NumericVectorInterface proxy,
                           int index)
Method Detail

clone

public final java.lang.Object clone()
Specified by:
clone in interface NumericVectorInterface
Specified by:
clone in interface VectorInterface
Overrides:
clone in class AbstractNumericVector

toArray

public final double[] toArray()
Specified by:
toArray in interface NumericVectorInterface
Overrides:
toArray in class AbstractNumericVector

getDimension

public final int getDimension()

getValue

public final double getValue(int index)
Specified by:
getValue in interface VectorInterface
Specified by:
getValue in class AbstractNumericVector

setValue

public final void setValue(int index,
                           double value)
Specified by:
setValue in interface NumericVectorInterface
Specified by:
setValue in class AbstractNumericVector

setValue

public final void setValue(NumericVectorInterface v)