Content deleted Content added
Jitse Niesen (talk | contribs) clarify and format |
Jitse Niesen (talk | contribs) add some stuff, mostly on symplectic |
||
Line 1:
In mathematics, the '''
== Setting ==
Given a pair of [[differential equation]]s of the form▼
:<math> {dx \over dt} = v(t) </math>▼
:<math> {
where ''f'' and ''g'' are given functions. Here, ''x'' and ''v'' may be either scalars or vectors. The equations of motion in [[Hamiltonian mechanics]] take this form if the Hamiltonian is of the form
:<math> (x_0,v_0), \quad</math>▼
the Euler-Cromer algorithm produces an approximate [[Discrete mathematics|discrete]] solution by iterating▼
The differential equations are to be solved with the initial condition
:<math> v_{n+1} = v_n + a_n \Delta t \quad</math>▼
:<math>
where <math> \Delta t </math> is the timestep and <math>a_n = a(x_n,v_n,t_n)</math> is the acceleration at the current timestep.▼
▲
Note the difference from the Euler method: <math>x_{n+1}</math> depends on <math>v_{n+1}</math> rather than <math>v_n</math>.▼
:<math> x_{n+1} = x_n + g(t_n, v_{n+1}) \, \Delta t \quad</math>
▲where <math> \Delta t </math> is the
▲
The Euler–Cromer method is a [[Numerical ordinary differential equations#Consistency and order|first-order integrator]], just as the standard Euler method. This means that it commits an global error of the order of Δt. However, the Euler–Cromer method is a [[symplectic integrator]], unlike the standard method. As a consequence, the Euler–Cromer method almost conserves the energy (when the Hamiltonian is time-independent). Often, the energy decreases steadily when the standard Euler method is applied, making it far less accurate.
== Example ==
Line 29 ⟶ 39:
:<math> {dv \over dt} = -{k \over m}x. \quad</math>
The
:<math>v_{n+1} = v_n - {k \over m}x_n\Delta t \quad</math>
:<math>x_{n+1} = x_n + v_{n+1} \Delta t. \quad</math>
▲== See also ===
== References ==
Line 56 ⟶ 63:
| url = http://www.physics.udel.edu/~jim/Ordinary%20Differential%20Equations/Euler-Cromer%20Method.htm
| accessdate = 2007-03-03}}
* {{cite book |last= Vesely
|first= Franz J.
|title= Computational Physics: An Introduction
|edition= 2nd edition
|publisher= Springer
|year= 2001
|isbn= 978-0-306-46631-1
|pages=page 117}}
[[Category:Numerical differential equations]]
|