Return-Path: Delivered-To: apmail-commons-user-archive@www.apache.org Received: (qmail 11489 invoked from network); 4 Jun 2009 21:53:16 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 4 Jun 2009 21:53:16 -0000 Received: (qmail 89251 invoked by uid 500); 4 Jun 2009 21:53:26 -0000 Delivered-To: apmail-commons-user-archive@commons.apache.org Received: (qmail 89145 invoked by uid 500); 4 Jun 2009 21:53:26 -0000 Mailing-List: contact user-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Commons Users List" Delivered-To: mailing list user@commons.apache.org Received: (qmail 89135 invoked by uid 99); 4 Jun 2009 21:53:26 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 04 Jun 2009 21:53:26 +0000 X-ASF-Spam-Status: No, hits=1.2 required=10.0 tests=SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: local policy) Received: from [194.206.126.239] (HELO smtp.nordnet.fr) (194.206.126.239) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 04 Jun 2009 21:53:16 +0000 Received: from lehrin (131.245.146.195.dynamic.adsl.abo.nordnet.fr [195.146.245.131]) by smtp.nordnet.fr (Postfix) with ESMTP id 36FAC34138 for ; Thu, 4 Jun 2009 23:52:53 +0200 (CEST) Received: by lehrin (Postfix, from userid 5001) id 393F44066; Thu, 4 Jun 2009 23:52:55 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.2.5 (2008-06-10) on lehrin.spaceroots.local X-Spam-Level: Received: from lehrin.spaceroots.local (lehrin.spaceroots.local [127.0.0.1]) by lehrin (Postfix) with ESMTP id 8F36C405D for ; Thu, 4 Jun 2009 23:52:51 +0200 (CEST) Message-ID: <4A284233.9040601@free.fr> Date: Thu, 04 Jun 2009 23:52:51 +0200 From: Luc Maisonobe User-Agent: Thunderbird 2.0.0.21 (X11/20090409) MIME-Version: 1.0 To: Commons Users List Subject: [math] Re: ODE Question References: <23878418.post@talk.nabble.com> In-Reply-To: <23878418.post@talk.nabble.com> X-Enigmail-Version: 0.95.7 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Virus-Checked: Checked by ClamAV on apache.org X-Old-Spam-Status: No, score=-1.4 required=5.0 tests=ALL_TRUSTED autolearn=failed version=3.2.5 Angelo Port a �crit : > Hi, Hello, First, please use a marker like [math] when posting to this list according to the commons component you use. This list is shared by several components, so it helps subscribers filter the messages. > > > > I am attempting to use the Dormand-Prince 54 integrator. I get the following > error: > > org.apache.commons.math.ode.IntegratorException: dimensions mismatch: ODE > problem has dimension 0, initial state vector has dimension 6 > at > org.apache.commons.math.ode.AdaptiveStepsizeIntegrator.sanityChecks(AdaptiveStepsizeIntegrator.java:177) > at > org.apache.commons.math.ode.EmbeddedRungeKuttaIntegrator.integrate(EmbeddedRungeKuttaIntegrator.java:179) > > Did I forget to set the dimension? If so, how is this done? The problem you pass to the integrator implements the FirstOrderDifferentialEquations interfaces, which has a getDimension() method. This method must provide the dimension of the set of differential equations it computes. In your case, I guess you should have: public int getDimension() { return 6; } This must be consistent with the dimension of the state vector. Luc > > > > Angelo > > --------------------------------------------------------------------- To unsubscribe, e-mail: user-unsubscribe@commons.apache.org For additional commands, e-mail: user-help@commons.apache.org