2
* Licensed to the Apache Software Foundation (ASF) under one or more
3
* contributor license agreements. See the NOTICE file distributed with
4
* this work for additional information regarding copyright ownership.
5
* The ASF licenses this file to You under the Apache License, Version 2.0
6
* (the "License"); you may not use this file except in compliance with
7
* the License. You may obtain a copy of the License at
9
* http://www.apache.org/licenses/LICENSE-2.0
11
* Unless required by applicable law or agreed to in writing, software
12
* distributed under the License is distributed on an "AS IS" BASIS,
13
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
* See the License for the specific language governing permissions and
15
* limitations under the License.
18
package org.apache.commons.math.ode;
21
* This class implements the 3/8 fourth order Runge-Kutta
22
* integrator for Ordinary Differential Equations.
24
* <p>This method is an explicit Runge-Kutta method, its Butcher-array
25
* is the following one :
31
* |--------------------
36
* @see EulerIntegrator
37
* @see ClassicalRungeKuttaIntegrator
39
* @see MidpointIntegrator
40
* @version $Revision: 620312 $ $Date: 2008-02-10 12:28:59 -0700 (Sun, 10 Feb 2008) $
44
public class ThreeEighthesIntegrator
45
extends RungeKuttaIntegrator {
47
/** Integrator method name. */
48
private static final String methodName = "3/8";
50
/** Time steps Butcher array. */
51
private static final double[] c = {
52
1.0 / 3.0, 2.0 / 3.0, 1.0
55
/** Internal weights Butcher array. */
56
private static final double[][] a = {
62
/** Propagation weights Butcher array. */
63
private static final double[] b = {
64
1.0 / 8.0, 3.0 / 8.0, 3.0 / 8.0, 1.0 / 8.0
67
/** Simple constructor.
68
* Build a 3/8 integrator with the given step.
69
* @param step integration step
71
public ThreeEighthesIntegrator(double step) {
72
super(c, a, b, new ThreeEighthesStepInterpolator(), step);
75
/** Get the name of the method.
76
* @return name of the method
78
public String getName() {