Luc Maisonobe
eb66fe4a1f
Improved test coverage.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1571737 13f79535-47bb-0310-9956-ffa450edef68
2014-02-25 16:42:07 +00:00
Gilles Sadowski
d3470c37ab
Typo.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1571640 13f79535-47bb-0310-9956-ffa450edef68
2014-02-25 10:27:21 +00:00
Gilles Sadowski
1358d274db
Fixed small inconsistency.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1571639 13f79535-47bb-0310-9956-ffa450edef68
2014-02-25 10:26:55 +00:00
Luc Maisonobe
856e3cf007
Javadoc.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1571627 13f79535-47bb-0310-9956-ffa450edef68
2014-02-25 09:21:32 +00:00
Luc Maisonobe
b122db9eda
Make AbstractEvaluation public
...
Allow custom implementations of LeastSquaresProblem to use the default
methods for computing the covariance, rms, etc.
JIRA: MATH-1102
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1571307 13f79535-47bb-0310-9956-ffa450edef68
2014-02-24 14:58:07 +00:00
Luc Maisonobe
9ac2b15e4a
In LeastSquaresProblem.Evaluation removed the getValue() method.
...
- The residuals are the really the values of the objective function
that is being minimized.
- Forcing the value to be a real vector and the residual computed
through subtraction is an unnecessary constraint. For example
Rotation.distance() will compute a better residual than
subtracting the quaternion elements of two rotations.
- Method was not used by any optimizer.
JIRA: MATH-1102
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1571306 13f79535-47bb-0310-9956-ffa450edef68
2014-02-24 14:57:44 +00:00
Luc Maisonobe
a573059d05
Moved OptimizationProblem interface to optim package.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1571015 13f79535-47bb-0310-9956-ffa450edef68
2014-02-23 14:00:48 +00:00
Luc Maisonobe
dcdfd7ed9e
Change private least square problem implementation to internal class.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1571014 13f79535-47bb-0310-9956-ffa450edef68
2014-02-23 14:00:20 +00:00
Luc Maisonobe
f299ecf330
Improved documentation of QR decomposition handling of singular matrix.
...
JIRA: MATH-1101
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1570994 13f79535-47bb-0310-9956-ffa450edef68
2014-02-23 11:10:41 +00:00
Luc Maisonobe
927361d787
QR decomposition can compute pseudo-inverses for tall matrices.
...
Thanks to Sean Owen for the patch.
JIRA: MATH-1053
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1570566 13f79535-47bb-0310-9956-ffa450edef68
2014-02-21 13:18:35 +00:00
Luc Maisonobe
ed7ac7cf74
Field vectors now implement the visitor pattern just like real vectors.
...
JIRA: MATH-820
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1570536 13f79535-47bb-0310-9956-ffa450edef68
2014-02-21 11:26:09 +00:00
Luc Maisonobe
5ea537df99
Un-deprecated RealVector.sparseIterator.
...
The documentation now explicitly states that entries not iterated above
are the zero ones.
This is part of Apache Commons Math reconsidering support for sparse
linear algebra.
JIRA: MATH-875
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1570510 13f79535-47bb-0310-9956-ffa450edef68
2014-02-21 10:16:52 +00:00
Luc Maisonobe
a9d0cc42fe
Relaxed specification for function mapping on vectors.
...
JIRA: MATH-821
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1570254 13f79535-47bb-0310-9956-ffa450edef68
2014-02-20 16:16:19 +00:00
Luc Maisonobe
1cd5a3229c
Continue un-deprecation of sparse methods.
...
JIRA: MATH-870
JIRA: MATH-803
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1570246 13f79535-47bb-0310-9956-ffa450edef68
2014-02-20 15:56:37 +00:00
Luc Maisonobe
4332119866
Added a test showing the limitation of sparse matrices implementation.
...
JIRA:MATH-870.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1570209 13f79535-47bb-0310-9956-ffa450edef68
2014-02-20 14:52:13 +00:00
Luc Maisonobe
fe0f518f50
computeXxx renamed getXxx in the Evaluation interface (leastsquares).
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1570206 13f79535-47bb-0310-9956-ffa450edef68
2014-02-20 14:35:14 +00:00
Luc Maisonobe
d19b226c54
Make QR the default in GaussNewtonOptimizer
...
Theoretically QR offers the best blend of speed and numerical stability.
Empirically the QR implementation is slightly faster than the Cholesky
implementation.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569907 13f79535-47bb-0310-9956-ffa450edef68
2014-02-19 20:32:43 +00:00
Luc Maisonobe
3c1bf79202
Add Cholesky option to GaussNewtonOptimizer
...
Since the normal matrix is symmetric positive (semi-)definite, the
Cholesky decomposition is theoretically faster.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569906 13f79535-47bb-0310-9956-ffa450edef68
2014-02-19 20:32:20 +00:00
Luc Maisonobe
1a6879a002
Make QR in GaussNewton faster and more accurate
...
Re-factored the code in GaussNewtonOptimizer so that the decomposition
algorithm sees the Jacobian and residuals instead of the normal
equation. This lets the QR algorithm operate directly on the Jacobian
matrix, which is faster and less sensitive to numerical errors. As a
result, one test case that threw a singular matrix exception now passes
with the QR decomposition.
The refactoring also include a speed improvement when computing the
normal matrix for the LU decomposition. Since the normal matrix is
symmetric only half of is computed, which results in a factor of 2 speed
up in computing the normal matrix for problems with many more
measurements than states.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569905 13f79535-47bb-0310-9956-ffa450edef68
2014-02-19 20:31:47 +00:00
Luc Maisonobe
499101c88c
The sparse vector and matrix classes have been un-deprecated.
...
This is a reversal of a former decision, as we now think we should adopt
a generally accepted behavior which is ... to ignore the problems of
NaNs and infinities in sparse linear algebra entities.
JIRA: MATH-870 (which is therefore NOT fixed)
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569825 13f79535-47bb-0310-9956-ffa450edef68
2014-02-19 17:19:59 +00:00
Luc Maisonobe
785ea269eb
Javadoc.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569380 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 15:11:46 +00:00
Luc Maisonobe
b0521ef7e0
Removed interfaces in the fluent API that do not add any value.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569363 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:33:57 +00:00
Luc Maisonobe
613a83c56a
Fixed checkstyle and compiler warnings.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569362 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:33:49 +00:00
Luc Maisonobe
b01933b17f
Expand Evaluation tests, use weighted values.
...
Added more test cases to EvaluationTest to test the other methods of
DenseWeightedEvaluation/UnweightedEvaluation.
Fixed a bug in DenseWeightedEvaluation.computeValue() where the the
weights were not applied to the return value.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569361 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:33:41 +00:00
Luc Maisonobe
9a012f530e
Qualify Evaluation in interfaces.
...
Use LeastSquaresProblem.Evaluation in the public interfaces for
readability.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569360 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:33:33 +00:00
Luc Maisonobe
57096ad696
JUnit directly executes least squares tests
...
Previously JUnit would make the call to test a specific optimizer, and
then that method would call all of the individual test cases relevant to
that optimizer.,Now JUnit will directly call each individual test case.
The same test coverage is preserved. The GaussNewtonOptimizerTest is
split into two classes, one for each decomposition algorithm it can use.
There is a significant amount of duplicated code between
GaussNewtonOptimizerWithLUTest and GaussNewtonOptimizerWithQRTest.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569359 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:33:28 +00:00
Luc Maisonobe
c12ae52424
Fixed errors introduced by few previous API changes.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569358 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:33:20 +00:00
Luc Maisonobe
46b2ce2ee0
Fix Javadoc and checkstyle errors.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569357 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:33:14 +00:00
Luc Maisonobe
8916830e8a
Clean up LeastSquaresBuilder
...
Provide methods for using old and new interfaces. Data is stored internally
using the new interfaces now.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569356 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:33:08 +00:00
Luc Maisonobe
4dcae270e6
Clean up LeastSquaresFactory
...
* There are now 3 factory methods: one using the previous interfaces, one using
the new interfaces with weights, and one using the new interfaces without
weights.
* Make model(...) method public.
* Fix javadoc typo
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569355 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:33:00 +00:00
Luc Maisonobe
0079828734
Use Real{Vector,Matrix} in LeastSquares interfaces
...
Covered all of the interfaces in the leastsquares package to use RealVector and
RealMatrix instead of double[] and double[][]. This reduced some duplicated code.
For example Evaluation.computeResiduals() was a complete duplication of
RealVector.subtract(). It also presents a consistent interface and allows data
encapsulation.
Lastly, this change enables [math] to "eat our own dog food." It enables the
linear package to be used in the implementation of the optimization algorithms.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569354 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:32:54 +00:00
Luc Maisonobe
a7a380f934
Use Evaluation instead of PointVectorValuePair
...
Use Evaluation instead of PointVectorValuePair in the ConvergenceChecker. This
gives the checkers access to more information, such as the rms and covariances.
The change also simplified the optimizer implementations since they no longer
have to keep track of the current function value.
A method was added to LeastSquaresFactory to convert between the two types of
checkers and a method added to LeastSquaresBuilder so that it can accept either
type. I would have prefered to do this through method overloading, but
overloading doesn't play well with generics.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569353 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:32:44 +00:00
Luc Maisonobe
3e18e999c7
Use enum for LU or QR in GaussNewtonOptimizer
...
Changed the boolean useLu prarameter to an enum. This is benificial because:
1. user code is easier to read: new GNO(Decomposition.QR) instead of new GNO(false)
2. Allows other algorithms to be added in the future
3. developer code is easier to read. One less if statement in optimize()
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569352 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:32:36 +00:00
Luc Maisonobe
49685c8bb4
Make infinite loop in GaussNewton explicit.
...
The main loop in GN could only be ended by convergence or exception. I made that
explicit with while(true) and removed an unreachable MathInternalError.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569350 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:32:28 +00:00
Luc Maisonobe
8b697afded
LevenbergMarquardtOptimizer is thread safe.
...
Converted the mutable fields to locals.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569349 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:32:23 +00:00
Luc Maisonobe
4cdfc143ea
Add Javadoc to LeastSquaresBuilder.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569348 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:32:17 +00:00
Luc Maisonobe
9444e28967
Fixup javadoc in LeastSquaresProblem
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569347 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:32:11 +00:00
Luc Maisonobe
fc9cb0ce16
Value and Jacobian evaluated in a single method.
...
A new interface MultivariateJacobianFunction lets the function value and
Jacobian be evaluated at the same time. This saves the user from having to cache
the result between calls to get the value and the jacobian.
A factory method was added to create LeastSquaresProblems from the new interface.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569346 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:32:06 +00:00
Luc Maisonobe
4158f97463
Clean up LeastSquaresProblemImpl
...
Reorder constructor parameters to match LeastSquaresFactory and remove an unused
method.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569345 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:31:59 +00:00
Luc Maisonobe
06d490a4bd
Implicit Weights
...
The weights are no longer implicit in LeastSquaresProblem.Evaluation. They are
already included in the computed residuals and Jacobian.
GN and LM multiplied the residuals by the weights immediately, so that was easy
to remove.
Created an AbstractEvaluation class which handles the derived quantitied (cost,
rms, covariance,...) and two implementations. UnweightedEvaluation uses the
straight forward formulas. DenseWeightedEvaluation delegates to an Evaluation
and multiples the residuals and Jacobian by the square root of the weight matrix
before returning them. Allowed me to remove the reference to the full weight
matrix.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569344 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:31:53 +00:00
Luc Maisonobe
567127c109
Immutable Optimizer configuration.
...
The GN and LM optimizers now use an immutable fields for their configuration
parameters and a fluent api. LM still has some mutable fields it uses a scratch
space.
This commit is a backport of Evan Ward github commit
https://github.com/wardev/commons-math/commit/157cdde
into the current development version.
Conflicts:
src/main/java/org/apache/commons/math3/fitting/leastsquares/GaussNewtonOptimizer.java
src/main/java/org/apache/commons/math3/fitting/leastsquares/LevenbergMarquardtOptimizer.java
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569343 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:31:43 +00:00
Luc Maisonobe
7460c082a3
Separate least squares algorithm from problem.
...
The least squares package now has two main interfaces LeastSquaresOptimizer and
LeastSquaresProblem, where the optimizer can be applied to the problem.
In this commit all of the test cases pass with one change (annotated) to
LevenbergMarquardt.testControlParameters(). The tests for Gauss Newton were
expanded to cover using the QR decomposition, which revealed a QR default
tolerance discrepancy.
A factory and a mutable builder were create for LeastSquaresProblem.
This commit is a backport of Evan Ward github commit
7e9a15efb5
into the current development version.
Conflicts:
src/main/java/org/apache/commons/math3/fitting/leastsquares/AbstractLeastSquaresOptimizer.java
src/main/java/org/apache/commons/math3/fitting/leastsquares/GaussNewtonOptimizer.java
src/main/java/org/apache/commons/math3/optim/AbstractOptimizer.java
src/test/java/org/apache/commons/math3/fitting/leastsquares/AbstractLeastSquaresOptimizerAbstractTest.java
src/test/java/org/apache/commons/math3/fitting/leastsquares/GaussNewtonOptimizerTest.java
src/test/java/org/apache/commons/math3/fitting/leastsquares/LevenbergMarquardtOptimizerTest.java
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1569342 13f79535-47bb-0310-9956-ffa450edef68
2014-02-18 14:31:34 +00:00
Thomas Neidhart
675d4c8fc8
Update test after adding new error message.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1568754 13f79535-47bb-0310-9956-ffa450edef68
2014-02-16 12:32:52 +00:00
Thomas Neidhart
e8d0d4c1dd
[MATH-749] Remove GrahamScan, GiftWrap, make MonotoneChain more robust wrt collinear points, add ConvergenceException in case the specified tolerance results in a non-convex hull.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1568752 13f79535-47bb-0310-9956-ffa450edef68
2014-02-16 12:19:51 +00:00
Luc Maisonobe
39430886ba
Rewrote completely the enclosing spherical cap computation on 2-sphere.
...
The previous version was based on Welzl algorithm, but it appeared this
algorithm really need some properties that hold in Euclidean spaces and
not on the sphere.
The current version is not perfect in the sense that some times the
enclosing spherical cap returned is not the smallest possible. It is
documented in the Javadoc.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1567599 13f79535-47bb-0310-9956-ffa450edef68
2014-02-12 11:12:45 +00:00
Thomas Neidhart
b9b73fbef5
Further improvements.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1567427 13f79535-47bb-0310-9956-ffa450edef68
2014-02-11 22:33:39 +00:00
Thomas Neidhart
7e6304ce63
Add zooming, center of enclosing ball.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1566774 13f79535-47bb-0310-9956-ffa450edef68
2014-02-10 22:35:10 +00:00
Thomas Neidhart
12ddf37f23
Simplify geometry examples by using piccolo2d.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1566450 13f79535-47bb-0310-9956-ffa450edef68
2014-02-09 22:10:04 +00:00
Luc Maisonobe
d41b96e58d
Added a warning about interfaces not implementable by users.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1566416 13f79535-47bb-0310-9956-ffa450edef68
2014-02-09 20:56:55 +00:00
Thomas Neidhart
517ff8cbe3
Revert unneeded serializationUID field.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1566396 13f79535-47bb-0310-9956-ffa450edef68
2014-02-09 20:36:24 +00:00
Luc Maisonobe
5ae01f1f99
Added a getEnclosingCap method for spherical polygons.
...
In simple cases (small polygon, one piece only, no holes), the enclosing
cap will be the smallest one, but this is not guaranteed in the general
case.
The enclosing cap can be used to speed up inside/outside points when the
region is small with respect to the sphere as with only one check of an
angular separation, most points of the sphere can be safely identified
as outside. The more time-consuming checks involving the full boundary
are therefore done only for a small portion of the sphere.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1566358 13f79535-47bb-0310-9956-ffa450edef68
2014-02-09 19:17:55 +00:00
Thomas Neidhart
2535320878
[MATH-749] Add changelog entry.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1566342 13f79535-47bb-0310-9956-ffa450edef68
2014-02-09 18:24:27 +00:00
Thomas Neidhart
996c0c164a
[MATH-1065] Fix EnumeratedRealDistribution.inverseCumulativeProbability. Thanks to matteodg and Phil.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1566274 13f79535-47bb-0310-9956-ffa450edef68
2014-02-09 11:21:28 +00:00
Thomas Neidhart
3f59a81a15
Add missing since tags.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1566092 13f79535-47bb-0310-9956-ffa450edef68
2014-02-08 18:48:29 +00:00
Thomas Neidhart
b957ee1646
Add missing serialVersionUIDs.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1566088 13f79535-47bb-0310-9956-ffa450edef68
2014-02-08 18:36:30 +00:00
Thomas Neidhart
42dffede43
[MATH-1050] Added changelog entry.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1566074 13f79535-47bb-0310-9956-ffa450edef68
2014-02-08 18:14:37 +00:00
Thomas Neidhart
3c644cf87e
[MATH-749] Change the way the line segments are computed as they can not be serialized. Use the array only as cache and create them as needed.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1566064 13f79535-47bb-0310-9956-ffa450edef68
2014-02-08 17:44:37 +00:00
Thomas Neidhart
c92f7d0c8f
[MATH-976] Add changelog entry.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1566047 13f79535-47bb-0310-9956-ffa450edef68
2014-02-08 16:54:45 +00:00
Thomas Neidhart
8dae299004
[MATH-990] Added changelog entry.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1566021 13f79535-47bb-0310-9956-ffa450edef68
2014-02-08 14:33:03 +00:00
Thomas Neidhart
51a7ec0633
Fix typo.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1566020 13f79535-47bb-0310-9956-ffa450edef68
2014-02-08 14:28:20 +00:00
Thomas Neidhart
d434c5d0cc
[MATH-1044] Clarify javadoc of DecompositionSolver#getInverse and corresponding implementations. Thanks to Sean Owen.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1566017 13f79535-47bb-0310-9956-ffa450edef68
2014-02-08 14:13:34 +00:00
Thomas Neidhart
b268dfbb82
Add missing AL header.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1565447 13f79535-47bb-0310-9956-ffa450edef68
2014-02-06 21:31:52 +00:00
Thomas Neidhart
de21905859
[MATH-749] Rename method, add/improve javadoc, better handle degenerate cases, improve unit tests.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1565444 13f79535-47bb-0310-9956-ffa450edef68
2014-02-06 21:27:20 +00:00
Thomas Neidhart
6b43922648
[MATH-749] Handle case that all points are identical.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1564954 13f79535-47bb-0310-9956-ffa450edef68
2014-02-05 22:10:22 +00:00
Thomas Neidhart
b353d07bcc
[MATH-749] Add GiftWrap algorithm as precursor for Chan's algorithm.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1564951 13f79535-47bb-0310-9956-ffa450edef68
2014-02-05 21:54:10 +00:00
Thomas Neidhart
e5dc3ad337
[MATH-749] Improve robustness for convex hull algorithms in case of identical / collinear points, added flag whether to include only extreme points or all points on the hull, improve unit tests.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1564934 13f79535-47bb-0310-9956-ffa450edef68
2014-02-05 21:21:31 +00:00
Luc Maisonobe
e5002ce3f6
Removed unfinished method.
...
The method was added by error.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1564922 13f79535-47bb-0310-9956-ffa450edef68
2014-02-05 20:46:43 +00:00
Luc Maisonobe
739708f1af
Added enclosing ball generator for 2-sphere.
...
On the 2-sphere, enclosing balls are sphericals caps.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1564921 13f79535-47bb-0310-9956-ffa450edef68
2014-02-05 20:42:58 +00:00
Luc Maisonobe
3d0e61ebe5
Fixed comments.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1564255 13f79535-47bb-0310-9956-ffa450edef68
2014-02-04 11:19:41 +00:00
Thomas Neidhart
3b50199358
Add missing Override tags.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1563714 13f79535-47bb-0310-9956-ffa450edef68
2014-02-02 20:55:14 +00:00
Luc Maisonobe
19c1c3bb9b
Fixed sphere generation in degenerated cases.
...
In almost coplanar / almost colinear cases, sphere generation could
diverge in such a way the support points did not belong to the sphere
anymore! This new implementation uses exact arithmetic for the
computation. It is much slower, but since very few balls should be
generated during the Welzl algorithm execution, this is probably
acceptable.
JIRA: MATH-1096
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1563712 13f79535-47bb-0310-9956-ffa450edef68
2014-02-02 20:52:49 +00:00
Thomas Neidhart
7897aa6a83
[MATH-749] Use new method Vector2D.crossProduct, fix typos, return Segment instead of Line in ConvexHull2D.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1563687 13f79535-47bb-0310-9956-ffa450edef68
2014-02-02 17:56:13 +00:00
Thomas Neidhart
0fa8bcc008
[MATH-749] Added crossProduct method to Vector2D as a replacement for getLocation, using MathArrays.linearCombination to improve accuracy.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1563684 13f79535-47bb-0310-9956-ffa450edef68
2014-02-02 17:51:06 +00:00
Thomas Neidhart
2933e5773b
Add EnclosingBall example, update convex hull.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1563409 13f79535-47bb-0310-9956-ffa450edef68
2014-02-01 12:50:41 +00:00
Thomas Neidhart
764f56955d
Apply @Override rules for java 1.5
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1563402 13f79535-47bb-0310-9956-ffa450edef68
2014-02-01 12:00:21 +00:00
Thomas Neidhart
9dc30fddc1
Make constructor package private for now to simplify potential future changes.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1563288 13f79535-47bb-0310-9956-ffa450edef68
2014-01-31 22:07:35 +00:00
Thomas Neidhart
bcba29320f
Improve tests.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1563285 13f79535-47bb-0310-9956-ffa450edef68
2014-01-31 22:06:49 +00:00
Thomas Neidhart
8f7c59ce88
[MATH-749] Add MonotoneChain implementation.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1563284 13f79535-47bb-0310-9956-ffa450edef68
2014-01-31 22:06:31 +00:00
Thomas Neidhart
ca22dac3f8
Rename to GrahamScan as the algorithm anyway is only defined for the 2D case.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1563246 13f79535-47bb-0310-9956-ffa450edef68
2014-01-31 20:24:02 +00:00
Luc Maisonobe
423371e790
USer should not provide space dimension, it should be automatic.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1563204 13f79535-47bb-0310-9956-ffa450edef68
2014-01-31 18:33:22 +00:00
Thomas Neidhart
310008f48c
Convex hull example for user guide.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1563008 13f79535-47bb-0310-9956-ffa450edef68
2014-01-30 22:48:22 +00:00
Thomas Neidhart
ea030e732e
[MATH-749] Add AklToussaintHeuristic as pre-processing step for convex hull generation.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1562999 13f79535-47bb-0310-9956-ffa450edef68
2014-01-30 22:16:59 +00:00
Thomas Neidhart
7bbba6995a
[MATH-749] Fix GrahamScan2D for colinear points, improve tests.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1562975 13f79535-47bb-0310-9956-ffa450edef68
2014-01-30 21:28:05 +00:00
Luc Maisonobe
796c8329d6
Most of the 3D errors were due to ... wrong tests.
...
The dimension was set to 2 instead of 3.
There is still one problem, so investigation continues.
JIRA: MATH-1096
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1562959 13f79535-47bb-0310-9956-ffa450edef68
2014-01-30 21:04:58 +00:00
Luc Maisonobe
faf997271b
Partly fixed MATH-1096.
...
The 2D cases seem to work now, but there are still problems with the 3D
cases.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1562882 13f79535-47bb-0310-9956-ffa450edef68
2014-01-30 16:31:08 +00:00
Luc Maisonobe
8025900b3a
Removed redundant throws
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1562755 13f79535-47bb-0310-9956-ffa450edef68
2014-01-30 09:37:08 +00:00
Thomas Neidhart
1e6915db87
[MATH-749] Convex hull support for two-dimensional space: GrahamScan2D.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1562624 13f79535-47bb-0310-9956-ffa450edef68
2014-01-29 22:57:04 +00:00
Thomas Neidhart
49642956cd
Fix typo.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1562610 13f79535-47bb-0310-9956-ffa450edef68
2014-01-29 22:17:16 +00:00
Luc Maisonobe
2a3b56daa0
Added tests for 3D smallest ball enclosing.
...
WARNING! These tests have revealed a bug in our implementation of the
smallest enclosing ball algorithm. So some tests are currently ignored
in order to avoid having lots of messages, but I am already working on
them. The problems should be fixed (and the tests activated) before 3.3
release.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1562573 13f79535-47bb-0310-9956-ffa450edef68
2014-01-29 20:19:20 +00:00
Luc Maisonobe
7ce5950963
Added ball generation from support points in 3D.
...
This can be used for applying Emo Welzl smallest enclosing ball
algorithm in the Euclidean 3D case.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1562571 13f79535-47bb-0310-9956-ffa450edef68
2014-01-29 20:18:32 +00:00
Luc Maisonobe
8dd48742c3
Fixed wrong javadoc
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1562384 13f79535-47bb-0310-9956-ffa450edef68
2014-01-29 09:36:27 +00:00
Thomas Neidhart
7a2a276d76
Fix typo.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1562232 13f79535-47bb-0310-9956-ffa450edef68
2014-01-28 21:14:05 +00:00
Luc Maisonobe
672b58548c
Added Emo Welzl algorithm finding points smallest enclosing ball.
...
JIRA: MATH-1095
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1562220 13f79535-47bb-0310-9956-ffa450edef68
2014-01-28 20:29:27 +00:00
Thomas Neidhart
7029443e49
[MATH-985] Added changelog entry.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1561510 13f79535-47bb-0310-9956-ffa450edef68
2014-01-26 15:58:04 +00:00
Thomas Neidhart
38df46f944
Add missing since tag.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1561509 13f79535-47bb-0310-9956-ffa450edef68
2014-01-26 15:47:40 +00:00
Thomas Neidhart
91291520cf
[MATH-1072] Added constructor for AbstractListChromosome that does not copy the input argument.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1561508 13f79535-47bb-0310-9956-ffa450edef68
2014-01-26 15:46:49 +00:00
Luc Maisonobe
6a6c06acdf
Extract classes out of SphericalPolygonsSet source file.
...
None of these classes required private access to the
SphericalPolygonsSet class, so they can be outside, simplifying the
source.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1561506 13f79535-47bb-0310-9956-ffa450edef68
2014-01-26 15:31:18 +00:00
Luc Maisonobe
7cfbc0da48
Fixed error when splitting an arc close to its end.
...
fixes: MATH-1093
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1561047 13f79535-47bb-0310-9956-ffa450edef68
2014-01-24 16:03:44 +00:00
Gilles Sadowski
fbd429f2d7
Javadoc.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1560956 13f79535-47bb-0310-9956-ffa450edef68
2014-01-24 11:58:00 +00:00
Gilles Sadowski
d42fcbdb2f
Enable choice of RNG, so that the unit test can be run with a
...
seed that makes it always succeed.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1560953 13f79535-47bb-0310-9956-ffa450edef68
2014-01-24 11:55:25 +00:00
Luc Maisonobe
fde06bb6b6
Removed spurious @Override.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1560928 13f79535-47bb-0310-9956-ffa450edef68
2014-01-24 09:58:43 +00:00
Thomas Neidhart
c9b7b57d3c
Add missing AL header.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1560551 13f79535-47bb-0310-9956-ffa450edef68
2014-01-22 22:35:21 +00:00
Thomas Neidhart
58693fbcb3
[MATH-970] Add a method isSolutionOptimal to SolutionCallback.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1560541 13f79535-47bb-0310-9956-ffa450edef68
2014-01-22 22:12:42 +00:00
Thomas Neidhart
c58e2abfe5
Fix typo.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1560532 13f79535-47bb-0310-9956-ffa450edef68
2014-01-22 22:05:37 +00:00
Thomas Neidhart
842351710e
[MATH-1038] Refactor code as agreed on the mailinglist.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1560531 13f79535-47bb-0310-9956-ffa450edef68
2014-01-22 22:00:37 +00:00
Luc Maisonobe
1f8d874895
Updated user guide for geometry.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1560390 13f79535-47bb-0310-9956-ffa450edef68
2014-01-22 15:55:03 +00:00
Luc Maisonobe
1fc112d053
improved javadoc
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1560336 13f79535-47bb-0310-9956-ffa450edef68
2014-01-22 12:39:14 +00:00
Luc Maisonobe
e02b8f8a5a
typo in a function name ...
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1560335 13f79535-47bb-0310-9956-ffa450edef68
2014-01-22 12:39:06 +00:00
Luc Maisonobe
43ef84b729
BSP tree now provide an API to compute a global signed distance.
...
The distance is defined from a test point to the region. It is positive
if the point is outside of the region, negative if the point is inside,
and zero when the point is at the boundary. The distance is continuous
everywhere, so it can be used with a root solver to identify accurately
boundary crossings. This API is available for all BSP trees, in
Euclidean and spherical geometries, and in all dimensions.
Fixes MATH-1091
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1560115 13f79535-47bb-0310-9956-ffa450edef68
2014-01-21 17:49:13 +00:00
Luc Maisonobe
5b71c17c81
Javadoc fix.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1560114 13f79535-47bb-0310-9956-ffa450edef68
2014-01-21 17:48:16 +00:00
Luc Maisonobe
01e1ca4bfd
IntervalsSet now implements Iterable<double[]>.
...
Fixes MATH-1090
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1559746 13f79535-47bb-0310-9956-ffa450edef68
2014-01-20 15:34:41 +00:00
Luc Maisonobe
b1e3f391b5
Javadoc fix.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1559745 13f79535-47bb-0310-9956-ffa450edef68
2014-01-20 15:34:02 +00:00
Gilles Sadowski
145cc675d3
MATH-1089
...
Slightly simpler implementation.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1559067 13f79535-47bb-0310-9956-ffa450edef68
2014-01-17 10:53:00 +00:00
Thomas Neidhart
e91d0f0510
[MATH-1089] Precision.round(double, ...) will return negative zero for negative values rounded to zero.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1558933 13f79535-47bb-0310-9956-ffa450edef68
2014-01-16 22:11:00 +00:00
Thomas Neidhart
c9181d3b05
[MATH-1088] Add missing changelog entry.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1558922 13f79535-47bb-0310-9956-ffa450edef68
2014-01-16 21:39:03 +00:00
Gilles Sadowski
63d88c74b7
MATH-1088
...
Ensure that bad usage will raise an exception.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1558833 13f79535-47bb-0310-9956-ffa450edef68
2014-01-16 15:26:29 +00:00
Luc Maisonobe
2c9438da23
Fixed an issue with noisy functions for ODE events detection.
...
The issue was not detected in Apache Commons Math but in similar code in
Orekit (see https://www.orekit.org/forge/projects/orekit/issues/160 ).
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1558462 13f79535-47bb-0310-9956-ffa450edef68
2014-01-15 16:48:25 +00:00
Luc Maisonobe
4fc2d43205
Removed development bits.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1558150 13f79535-47bb-0310-9956-ffa450edef68
2014-01-14 18:27:02 +00:00
Luc Maisonobe
9b3a46e205
Fixed problem for spherical polygons with holes.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1558149 13f79535-47bb-0310-9956-ffa450edef68
2014-01-14 18:26:32 +00:00
Luc Maisonobe
692142457a
Don't advertise an assumption we may remove soon.
...
We will probably extend the circle class to also represent small circles
on the 2-sphere, not only great circles. This would introduce an
aperture angle that could be different from \pi/2. In this case, the
part of a circle inside another circle may exist or not (small circles
can be disjoint), and may have a length either shorter or longer than
\pi.
This change is not done yet, but could happen any time soon, even before
3.3 is out.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1557981 13f79535-47bb-0310-9956-ffa450edef68
2014-01-14 08:55:40 +00:00
Luc Maisonobe
ac7733fd69
Improved tests coverage.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1557716 13f79535-47bb-0310-9956-ffa450edef68
2014-01-13 13:55:53 +00:00
Luc Maisonobe
cfee716182
Removed too tight link between edges and BSP tree.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1557693 13f79535-47bb-0310-9956-ffa450edef68
2014-01-13 12:42:40 +00:00
Luc Maisonobe
0f13370f35
Fixed an error introduced by a wrong fix...
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1557609 13f79535-47bb-0310-9956-ffa450edef68
2014-01-12 20:41:34 +00:00
Luc Maisonobe
bb2dc86de1
Fixed area computation on non-convex spherical polygons.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1557543 13f79535-47bb-0310-9956-ffa450edef68
2014-01-12 14:56:04 +00:00
Luc Maisonobe
638def643f
Fixed missing last iteration in a loop.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1557514 13f79535-47bb-0310-9956-ffa450edef68
2014-01-12 11:13:05 +00:00
Luc Maisonobe
5f0fcfce89
Removed spurious @Override.
...
As we are still targeting Java 5, @Override should not be used for mere
interface implementation.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1557424 13f79535-47bb-0310-9956-ffa450edef68
2014-01-11 17:18:21 +00:00
Gilles Sadowski
aad194a346
MATH-923
...
Implementation of Kohonen's Self-Organizing Feature Map (SOFM).
New package "o.a.c.m.ml.neuralnet" contains base functionality for implementing
different map types, i.e. methods that project a high-dimensional space onto one
with a low dimension (typically 1D or 2D).
The SOFM-specific code is in "o.a.c.m.ml.neuralnet.sofm".
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1557267 13f79535-47bb-0310-9956-ffa450edef68
2014-01-10 22:01:27 +00:00
Luc Maisonobe
0a75cbc380
Improved robustness of 1-sphere regions (ArcsSet) at 0/2\pi crossing.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1556880 13f79535-47bb-0310-9956-ffa450edef68
2014-01-09 17:08:00 +00:00
Luc Maisonobe
f2db15c31f
Fixed errors in spherical polygons build from vertices.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1555871 13f79535-47bb-0310-9956-ffa450edef68
2014-01-06 15:45:43 +00:00
Luc Maisonobe
dfc232415a
Deprecating geometry constructors without tolerance setting.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1555176 13f79535-47bb-0310-9956-ffa450edef68
2014-01-03 18:07:59 +00:00
Luc Maisonobe
aaa0eafa09
Undeprecated methods.
...
Deprecating methods that are overridden with different signature was not
really a good idea. We can keep both methods in parallel without
problems.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1555175 13f79535-47bb-0310-9956-ffa450edef68
2014-01-03 18:07:22 +00:00
Luc Maisonobe
2a67133805
Generalized use of customizable tolerance in BSP trees.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1555174 13f79535-47bb-0310-9956-ffa450edef68
2014-01-03 18:06:20 +00:00
Luc Maisonobe
3839da6580
Fixed javadoc.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1555173 13f79535-47bb-0310-9956-ffa450edef68
2014-01-03 18:05:04 +00:00
Luc Maisonobe
bb014c3ebf
Fixed SubCircle behaviour in parallel circles case.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1555088 13f79535-47bb-0310-9956-ffa450edef68
2014-01-03 13:47:35 +00:00
Luc Maisonobe
3491906594
Fixed missing deep copy.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1555050 13f79535-47bb-0310-9956-ffa450edef68
2014-01-03 11:22:04 +00:00
Luc Maisonobe
4345758ddc
Test for 2-sphere hyperplane, i.e. Circle.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554907 13f79535-47bb-0310-9956-ffa450edef68
2014-01-02 20:40:42 +00:00
Luc Maisonobe
c8c94b8a1f
Removed unneeded method.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554906 13f79535-47bb-0310-9956-ffa450edef68
2014-01-02 20:40:09 +00:00
Luc Maisonobe
18a6d9c773
Un-deprecated a widely used method.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554905 13f79535-47bb-0310-9956-ffa450edef68
2014-01-02 20:39:38 +00:00
Luc Maisonobe
2b24ae34b7
Improved 1-sphere to provide methods useful for the 2-sphere.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554658 13f79535-47bb-0310-9956-ffa450edef68
2014-01-01 17:33:39 +00:00
Luc Maisonobe
292eefa57c
Fixed javadoc.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554657 13f79535-47bb-0310-9956-ffa450edef68
2014-01-01 17:31:21 +00:00
Luc Maisonobe
0faf0131f6
Finalized 1-sphere.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554656 13f79535-47bb-0310-9956-ffa450edef68
2014-01-01 17:30:58 +00:00
Luc Maisonobe
169a316003
Improved navigation within sub-arcs.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554655 13f79535-47bb-0310-9956-ffa450edef68
2014-01-01 17:30:34 +00:00
Luc Maisonobe
d83cdb9133
Simplified 1-sphere case.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554654 13f79535-47bb-0310-9956-ffa450edef68
2014-01-01 17:30:06 +00:00
Luc Maisonobe
57eff0d0c3
Avoid NullPointerException in some corner cases.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554653 13f79535-47bb-0310-9956-ffa450edef68
2014-01-01 17:29:18 +00:00
Luc Maisonobe
83444ebe71
Intermediate, partially working stuff on the 1-sphere.
...
Chord/SubChord are most probably not the appropriate classes. They are
too complex and should be replaced by something simpler and more
0-dimension, like OrientedPoint in Euclidean 1-D.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554652 13f79535-47bb-0310-9956-ffa450edef68
2014-01-01 17:28:51 +00:00
Luc Maisonobe
ed73c356c7
Fixed some Clirr errors.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554651 13f79535-47bb-0310-9956-ffa450edef68
2014-01-01 17:27:48 +00:00
Luc Maisonobe
a3e4cbe0bb
Added BSP for spherical geometry.
...
This is work in progress! It is not tested yet.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554650 13f79535-47bb-0310-9956-ffa450edef68
2014-01-01 17:26:54 +00:00
Luc Maisonobe
37115c5788
Javadoc typos.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554649 13f79535-47bb-0310-9956-ffa450edef68
2014-01-01 17:26:10 +00:00
Luc Maisonobe
13188390f3
Starting work on BSP trees for spheres.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554648 13f79535-47bb-0310-9956-ffa450edef68
2014-01-01 17:24:37 +00:00
Luc Maisonobe
65ada834ee
Typo.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554647 13f79535-47bb-0310-9956-ffa450edef68
2014-01-01 17:23:28 +00:00
Luc Maisonobe
6c4f513542
We don't need the full Vector API for BSP trees.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554646 13f79535-47bb-0310-9956-ffa450edef68
2014-01-01 17:22:53 +00:00
Thomas Neidhart
8fac2db60a
[MATH-1082] Add missing change entry.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554545 13f79535-47bb-0310-9956-ffa450edef68
2013-12-31 15:41:30 +00:00
Thomas Neidhart
edf56632b8
Rename local variable to avoid masking a member variable.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554544 13f79535-47bb-0310-9956-ffa450edef68
2013-12-31 15:40:35 +00:00
Luc Maisonobe
9d4d7150eb
Fixed missing licenses.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554036 13f79535-47bb-0310-9956-ffa450edef68
2013-12-29 15:18:59 +00:00
Luc Maisonobe
76a5cd998b
Checkstyle warnings.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1554035 13f79535-47bb-0310-9956-ffa450edef68
2013-12-29 15:17:45 +00:00
Gilles Sadowski
8e23b250a4
Javadoc.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1553855 13f79535-47bb-0310-9956-ffa450edef68
2013-12-28 15:55:24 +00:00
Phil Steitz
1220f2f7ba
Javadoc fix.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1553598 13f79535-47bb-0310-9956-ffa450edef68
2013-12-26 22:18:02 +00:00
Thomas Neidhart
fa027a4685
[MATH-1082] Improve cutOff mechanism in SimplexSolver, adapt unit tests.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1552792 13f79535-47bb-0310-9956-ffa450edef68
2013-12-20 19:33:03 +00:00
Thomas Neidhart
881a4ee8db
[MATH-1079] Further improvements to SimplexSolver.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1552046 13f79535-47bb-0310-9956-ffa450edef68
2013-12-18 17:41:26 +00:00
Thomas Neidhart
af858a6ca2
[MATH-1079] Improve performance of SimplexSolver.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1551735 13f79535-47bb-0310-9956-ffa450edef68
2013-12-17 22:11:45 +00:00
Thomas Neidhart
68fa81123a
Fix javadoc.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1551360 13f79535-47bb-0310-9956-ffa450edef68
2013-12-16 21:13:59 +00:00
Thomas Neidhart
b285f17023
[MATH-1080] LinearConstraintSet returns now the LinearConstraints in the same order as they have been added.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1551355 13f79535-47bb-0310-9956-ffa450edef68
2013-12-16 21:05:01 +00:00
Thomas Neidhart
f7222ca6c3
Rename enum to uppercase, make test deterministic.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1551058 13f79535-47bb-0310-9956-ffa450edef68
2013-12-15 21:15:21 +00:00
Thomas Neidhart
05aae985d9
Small improvement.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1551014 13f79535-47bb-0310-9956-ffa450edef68
2013-12-15 10:56:49 +00:00
Thomas Neidhart
721730b00b
Formatting, use List instead of ArrayList.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1550977 13f79535-47bb-0310-9956-ffa450edef68
2013-12-14 22:07:02 +00:00
Thomas Neidhart
f3a785108f
[MATH-842] Added support for different pivot selection rules to SimplexSolver.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1550975 13f79535-47bb-0310-9956-ffa450edef68
2013-12-14 21:50:33 +00:00
Thomas Neidhart
7ebbaea90e
Remove some debug code.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1549985 13f79535-47bb-0310-9956-ffa450edef68
2013-12-10 22:13:14 +00:00
Thomas Neidhart
ab0a2f761f
Add some documentation.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1549984 13f79535-47bb-0310-9956-ffa450edef68
2013-12-10 22:10:43 +00:00
Thomas Neidhart
e9ea52189a
Improve ImageEvolutionExample, add test images.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1549977 13f79535-47bb-0310-9956-ffa450edef68
2013-12-10 21:40:32 +00:00
Thomas Neidhart
1cdc902f3d
Add ImageEvolution example for genetics package.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1549696 13f79535-47bb-0310-9956-ffa450edef68
2013-12-09 22:34:28 +00:00
Thomas Neidhart
7573e9eec0
Small performance improvement.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1549094 13f79535-47bb-0310-9956-ffa450edef68
2013-12-08 18:23:44 +00:00
Thomas Neidhart
d944333d01
Fix typo.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1549093 13f79535-47bb-0310-9956-ffa450edef68
2013-12-08 18:23:09 +00:00
Thomas Neidhart
a34be55b9b
Add dependency to commons-lang3 for userguide examples.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1549092 13f79535-47bb-0310-9956-ffa450edef68
2013-12-08 18:20:58 +00:00
Thomas Neidhart
c823ac5673
Add HelloWorld example for genetics package.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1549090 13f79535-47bb-0310-9956-ffa450edef68
2013-12-08 18:18:13 +00:00
Thomas Neidhart
e42da5d9d2
[MATH-1068] Changed integer calculations with potential overflows to long.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1548907 13f79535-47bb-0310-9956-ffa450edef68
2013-12-07 13:08:06 +00:00
Thomas Neidhart
8e5867eda8
[MATH-1070] Fix Precision.round(float, int, int) for RoundingMode ROUND_UP. Thanks to Oleksandr Muliarevych.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1547649 13f79535-47bb-0310-9956-ffa450edef68
2013-12-03 23:50:14 +00:00
Thomas Neidhart
ba3c2201c6
[MATH-1059] Use FastMath instead of Math.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1547633 13f79535-47bb-0310-9956-ffa450edef68
2013-12-03 23:03:06 +00:00
Thomas Neidhart
b12610d35e
[MATH-1068] Avoid overflow in Kendalls correlation for large input arrays.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1546840 13f79535-47bb-0310-9956-ffa450edef68
2013-12-01 19:17:22 +00:00
Gilles Sadowski
aff82362cf
MATH-1067
...
Avoid infinite recursion. Thanks to Florian Erhard.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1546350 13f79535-47bb-0310-9956-ffa450edef68
2013-11-28 11:41:12 +00:00
Gilles Sadowski
c1ba07bb65
MATH-1014
...
"PolynomialCurveFitter" as replacement of "PolynomialFitter". Some tests have
been obsoleted by the refactoring (which hides the optimizer and thus avoids
some potential misuses).
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1543906 13f79535-47bb-0310-9956-ffa450edef68
2013-11-20 18:57:53 +00:00
Thomas Neidhart
54a7796ff2
[MATH-970] Added SolutionCallback to SimplexSolver to retrieve the best solution found.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1543169 13f79535-47bb-0310-9956-ffa450edef68
2013-11-18 21:24:32 +00:00
Thomas Neidhart
3a45bc5b6d
[MATH-1031] Added new ClusterEvaluation base class and refactored code in MultiKMeansPlusPlusClusterer.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1542545 13f79535-47bb-0310-9956-ffa450edef68
2013-11-16 18:48:48 +00:00
Thomas Neidhart
65646ba8bd
Fix typos.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1542541 13f79535-47bb-0310-9956-ffa450edef68
2013-11-16 17:48:36 +00:00
Phil Steitz
1e1365c7b4
Replaced deprecated method.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1541354 13f79535-47bb-0310-9956-ffa450edef68
2013-11-13 02:04:32 +00:00
Phil Steitz
763b37de5d
Dropped some ancient history.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1541350 13f79535-47bb-0310-9956-ffa450edef68
2013-11-13 01:34:10 +00:00
Phil Steitz
04078798c0
Miscellaneous updates / fixes
...
* Drop mention of Maven 2 (was distinguishing from Maven 1, which no longer really exists)
* Remind people to make diffs from top level project directory
* Don't tell people to make Wiki pages (not open access any more)
* Drop (now false) statement that all exceptions inherit from MRE
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1541347 13f79535-47bb-0310-9956-ffa450edef68
2013-11-13 01:24:17 +00:00
Phil Steitz
5df86e5cb2
Removed reference to deprecated class.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1540802 13f79535-47bb-0310-9956-ffa450edef68
2013-11-11 18:51:38 +00:00
Phil Steitz
7cff45f1d7
Refer to MathIllegalArgumentException; formatting; remove false commitment.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1540751 13f79535-47bb-0310-9956-ffa450edef68
2013-11-11 15:20:28 +00:00
Phil Steitz
b3b5e6c869
Fixed some errors; changed to use standard terminology.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1540566 13f79535-47bb-0310-9956-ffa450edef68
2013-11-10 22:19:10 +00:00
Phil Steitz
1b4f1ef040
Fixed typo.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1540561 13f79535-47bb-0310-9956-ffa450edef68
2013-11-10 22:04:58 +00:00
Phil Steitz
909105bf55
Fixed spelling errors.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1540531 13f79535-47bb-0310-9956-ffa450edef68
2013-11-10 19:59:15 +00:00
Phil Steitz
064634efda
Removed unused import.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1540514 13f79535-47bb-0310-9956-ffa450edef68
2013-11-10 18:55:52 +00:00
Phil Steitz
0801455213
Replaced deprecated method.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1540513 13f79535-47bb-0310-9956-ffa450edef68
2013-11-10 18:54:32 +00:00
Phil Steitz
78504bde01
Changed to use InsufficientDataException when the model does not contain sufficient data for the number of regerssors; fixed error in precondition statement.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1540502 13f79535-47bb-0310-9956-ffa450edef68
2013-11-10 18:03:41 +00:00
Phil Steitz
fdd505d985
Added InsufficientDataException. JIRA: MATH-1061
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1540498 13f79535-47bb-0310-9956-ffa450edef68
2013-11-10 17:45:38 +00:00
Phil Steitz
5d61fcddd4
Replaced deprecated method.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1540418 13f79535-47bb-0310-9956-ffa450edef68
2013-11-09 22:34:10 +00:00
Phil Steitz
b72f31c6bd
Clarified contracts re NaNs, IAEs and when constructor arguments are necessary.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1540395 13f79535-47bb-0310-9956-ffa450edef68
2013-11-09 21:32:06 +00:00
Phil Steitz
eca87abcee
Added test to verify that zero variance in either array leads to NaN.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1540392 13f79535-47bb-0310-9956-ffa450edef68
2013-11-09 20:31:52 +00:00
Phil Steitz
d252a811a2
Fixed unintended integer division error in PoissonDistribution sampling method.
...
JIRA: MATH-1056
Reported and patched by Sean Owen.
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1540217 13f79535-47bb-0310-9956-ffa450edef68
2013-11-08 23:27:49 +00:00
Thomas Neidhart
5ee76f095e
[MATH-1059] Replace Math with FastMath.
...
git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1540167 13f79535-47bb-0310-9956-ffa450edef68
2013-11-08 20:00:08 +00:00