ArrayFieldVector implements FieldVector<T>, Serializable { protected void checkVectorDimensions(FieldVector<T> v) throws DimensionMismatchException { checkVectorDimensions(v.getDimension()); } ArrayFieldVector(final Field<T> field);  ArrayFieldVector(Field<T> field, int size);  ArrayFieldVector(int size, T preset);  ArrayFieldVector(T[] d);  ArrayFieldVector(Field<T> field, T[] d);  ArrayFieldVector(T[] d, boolean copyArray);  ArrayFieldVector(Field<T> field, T[] d, boolean copyArray);  ArrayFieldVector(T[] d, int pos, int size);  ArrayFieldVector(Field<T> field, T[] d, int pos, int size);  ArrayFieldVector(FieldVector<T> v);  ArrayFieldVector(ArrayFieldVector<T> v);  ArrayFieldVector(ArrayFieldVector<T> v, boolean deep); @Deprecated  ArrayFieldVector(ArrayFieldVector<T> v1, ArrayFieldVector<T> v2);  ArrayFieldVector(FieldVector<T> v1, FieldVector<T> v2); @Deprecated  ArrayFieldVector(ArrayFieldVector<T> v1, T[] v2);  ArrayFieldVector(FieldVector<T> v1, T[] v2); @Deprecated  ArrayFieldVector(T[] v1, ArrayFieldVector<T> v2);  ArrayFieldVector(T[] v1, FieldVector<T> v2);  ArrayFieldVector(T[] v1, T[] v2);  ArrayFieldVector(Field<T> field, T[] v1, T[] v2); Field<T> getField(); FieldVector<T> copy(); FieldVector<T> add(FieldVector<T> v); ArrayFieldVector<T> add(ArrayFieldVector<T> v); FieldVector<T> subtract(FieldVector<T> v); ArrayFieldVector<T> subtract(ArrayFieldVector<T> v); FieldVector<T> mapAdd(T d); FieldVector<T> mapAddToSelf(T d); FieldVector<T> mapSubtract(T d); FieldVector<T> mapSubtractToSelf(T d); FieldVector<T> mapMultiply(T d); FieldVector<T> mapMultiplyToSelf(T d); FieldVector<T> mapDivide(T d); FieldVector<T> mapDivideToSelf(T d); FieldVector<T> mapInv(); FieldVector<T> mapInvToSelf(); FieldVector<T> ebeMultiply(FieldVector<T> v); ArrayFieldVector<T> ebeMultiply(ArrayFieldVector<T> v); FieldVector<T> ebeDivide(FieldVector<T> v); ArrayFieldVector<T> ebeDivide(ArrayFieldVector<T> v); T[] getData(); T[] getDataRef(); T dotProduct(FieldVector<T> v); T dotProduct(ArrayFieldVector<T> v); FieldVector<T> projection(FieldVector<T> v); ArrayFieldVector<T> projection(ArrayFieldVector<T> v); FieldMatrix<T> outerProduct(FieldVector<T> v); FieldMatrix<T> outerProduct(ArrayFieldVector<T> v); T getEntry(int index); int getDimension(); FieldVector<T> append(FieldVector<T> v); ArrayFieldVector<T> append(ArrayFieldVector<T> v); FieldVector<T> append(T in); FieldVector<T> getSubVector(int index, int n); void setEntry(int index, T value); void setSubVector(int index, FieldVector<T> v); void set(int index, ArrayFieldVector<T> v); void set(T value); T[] toArray(); T walkInDefaultOrder(final FieldVectorPreservingVisitor<T> visitor); T walkInDefaultOrder(final FieldVectorPreservingVisitor<T> visitor,
                                final int start, final int end); T walkInOptimizedOrder(final FieldVectorPreservingVisitor<T> visitor); T walkInOptimizedOrder(final FieldVectorPreservingVisitor<T> visitor,
                                  final int start, final int end); T walkInDefaultOrder(final FieldVectorChangingVisitor<T> visitor); T walkInDefaultOrder(final FieldVectorChangingVisitor<T> visitor,
                                final int start, final int end); T walkInOptimizedOrder(final FieldVectorChangingVisitor<T> visitor); T walkInOptimizedOrder(final FieldVectorChangingVisitor<T> visitor,
                                  final int start, final int end); @Override boolean equals(Object other); @Override int hashCode();  }
@Test public void testMisc() { ArrayFieldVector<Fraction> v1 = new ArrayFieldVector<Fraction>(vec1); ArrayFieldVector<Fraction> v4 = new ArrayFieldVector<Fraction>(vec4); FieldVector<Fraction> v4_2 = new ArrayFieldVector<Fraction>(vec4); String out1 = v1.toString(); Assert.assertTrue("some output ", out1.length()!=0); try { v1.checkVectorDimensions(2); Assert.fail("MathIllegalArgumentException expected"); } catch (MathIllegalArgumentException ex) { } try { v1.checkVectorDimensions(v4); Assert.fail("MathIllegalArgumentException expected"); } catch (MathIllegalArgumentException ex) { } try { v1.checkVectorDimensions(v4_2); Assert.fail("MathIllegalArgumentException expected"); } catch (MathIllegalArgumentException ex) { } }