From c004c9daea8983fd92df9cea63be08b03251e966 Mon Sep 17 00:00:00 2001 From: Sebastien Brisard Date: Thu, 8 Sep 2011 05:59:22 +0000 Subject: [PATCH] Removed call to double[][] solve(double[][]) from initializeHighOrderDerivatives. git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@1166533 13f79535-47bb-0310-9956-ffa450edef68 --- .../commons/math/ode/nonstiff/AdamsNordsieckTransformer.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/main/java/org/apache/commons/math/ode/nonstiff/AdamsNordsieckTransformer.java b/src/main/java/org/apache/commons/math/ode/nonstiff/AdamsNordsieckTransformer.java index 74c9eb191..46e50d604 100644 --- a/src/main/java/org/apache/commons/math/ode/nonstiff/AdamsNordsieckTransformer.java +++ b/src/main/java/org/apache/commons/math/ode/nonstiff/AdamsNordsieckTransformer.java @@ -30,6 +30,7 @@ import org.apache.commons.math.linear.FieldMatrix; import org.apache.commons.math.linear.MatrixUtils; import org.apache.commons.math.linear.QRDecomposition; import org.apache.commons.math.linear.QRDecompositionImpl; +import org.apache.commons.math.linear.RealMatrix; /** Transformer to Nordsieck vectors for Adams integrators. *

This class is used by {@link AdamsBashforthIntegrator Adams-Bashforth} and @@ -289,8 +290,8 @@ public class AdamsNordsieckTransformer { // solve the rectangular system in the least square sense // to get the best estimate of the Nordsieck vector [s2 ... sk] QRDecomposition decomposition = new QRDecompositionImpl(new Array2DRowRealMatrix(a, false)); - return new Array2DRowRealMatrix(decomposition.getSolver().solve(b), false); - + RealMatrix x = decomposition.getSolver().solve(new Array2DRowRealMatrix(b, false)); + return new Array2DRowRealMatrix(x.getData(), false); } /** Update the high order scaled derivatives for Adams integrators (phase 1).