This project was created for Computational Physics course (118094) in The Department of Physics at Technion - Israel Institute of Technology under the guidance of Dr. Joan Adler.

In this project, a two dimensional system containing one massive and charged classical point particle which moves under the influence of harmonic potential and a constant in time and homogeneous in space magnetic field perpendicular to the plane of motion will be examined. The motion of the particle will be derived from Newton's second law and from the principle of least action using an Hamiltonian. The attempt to solve this problem with two different sets of equations is made to see if there is a fundamental performance difference in the solving process (because of reasons discussed below).

Apart from studying the dynamics of the physical system, a comparison between two numerical algorithms will be performed. One of the algorithms to be compared is the the fourth-order Runge-Kutta algorithm, and the second is a "Predictor-Corrector" algorithm which will be obtained by combining the explicit Adams-Bashforth four-step method to make a prediction and the Adams-Moulton three-step method to calculate the correction.

As there are two spatial dimensions in this problem, Newton's formalism produces two ordinary differential equations (ODEs) of second order which will then be reduced in order to get four ODEs of first order. In the Hamilton's formalism on the other hand, although there are four ODEs of first order as well, the equation on the conjugate momentum of the angle is homogeneous as the problem have an azimuthal symmetry - the conjugate momentum is a constant of motion. This leads to another check that will be made: what equations system is the more efficient to solve in terms of computation time and numerical accuracy.

The program has two goals. The first is to make a comparison between the two numerical algorithms in terms of time and accuracy. This will be performed by comparing the numerical solutions to the analytic solution which can be derived. The second goal is to produce an AViz data files so the motion of the particle could be visualized.

Next: The Physics ↬