Fixes part of MAHOUT-1155.

https://issues.apache.org/jira/browse/MAHOUT-1155

Doesn't update Centroid because that is now part of the larger Vector changes
in https://issues.apache.org/jira/browse/MAHOUT-1202.



git-svn-id: https://svn.apache.org/repos/asf/mahout/trunk@1478836 13f79535-47bb-0310-9956-ffa450edef68
Part of MAHOUT-1202.

Makes DoubleFunction and DoubleDoubleFunction abstract
classes and adds method for a function class that can speedup vector operations
that check if a function has certain properties (is associative/commutative
etc.)



git-svn-id: https://svn.apache.org/repos/asf/mahout/trunk@1478853 13f79535-47bb-0310-9956-ffa450edef68
Part of MAHOUT-1202.

Extended OrderedIntDoubleMapping to support merging and zero values.
This is required for faster SequentialAccessSparseVector updates.



git-svn-id: https://svn.apache.org/repos/asf/mahout/trunk@1478865 13f79535-47bb-0310-9956-ffa450edef68
Fixes MAHOUT-1202.

https://issues.apache.org/jira/browse/MAHOUT-1202

This issue relates to the design document at
https://docs.google.com/document/d/1g1PjUuvjyh2LBdq2_rKLIcUiDbeOORA1sCJiSsz-JVU/edit#heading=h.koi571fvwha3jj



git-svn-id: https://svn.apache.org/repos/asf/mahout/trunk@1478958 13f79535-47bb-0310-9956-ffa450edef68
Merge branch 'trunk' of https://github.com/apache/mahout into trunk
Merge branch 'trunk' into vector

Conflicts:
	core/src/main/java/org/apache/mahout/common/distance/ChebyshevDistanceMeasure.java
	core/src/main/java/org/apache/mahout/common/distance/ManhattanDistanceMeasure.java
	core/src/main/java/org/apache/mahout/common/distance/MinkowskiDistanceMeasure.java
	core/src/main/java/org/apache/mahout/common/distance/TanimotoDistanceMeasure.java
	core/src/main/java/org/apache/mahout/math/hadoop/stochasticsvd/qr/GivensThinSolver.java
	math/src/main/java/org/apache/mahout/math/AbstractVector.java
	math/src/main/java/org/apache/mahout/math/Centroid.java
	math/src/main/java/org/apache/mahout/math/DelegatingVector.java
	math/src/main/java/org/apache/mahout/math/DenseVector.java
	math/src/main/java/org/apache/mahout/math/NamedVector.java
	math/src/main/java/org/apache/mahout/math/OrderedIntDoubleMapping.java
	math/src/main/java/org/apache/mahout/math/PermutedVectorView.java
	math/src/main/java/org/apache/mahout/math/RandomAccessSparseVector.java
	math/src/main/java/org/apache/mahout/math/SequentialAccessSparseVector.java
	math/src/main/java/org/apache/mahout/math/Vector.java
	math/src/main/java/org/apache/mahout/math/VectorView.java
	math/src/main/java/org/apache/mahout/math/function/Functions.java
	math/src/main/java/org/apache/mahout/math/jet/random/AbstractDistribution.java
	math/src/test/java/org/apache/mahout/math/FunctionTest.java
	math/src/test/java/org/apache/mahout/math/VectorBinaryAggregateCostTest.java
	math/src/test/java/org/apache/mahout/math/VectorBinaryAggregateTest.java
	math/src/test/java/org/apache/mahout/math/VectorBinaryAssignCostTest.java
	math/src/test/java/org/apache/mahout/math/VectorBinaryAssignTest.java
	math/src/test/java/org/apache/mahout/math/VectorTest.java
Reverted spurious import changes.