Skip to main content

Numerical methods challenge: Summary

During October (2017) I wrote a program per day for some well-known numerical methods in both Python and Julia. It was intended to be an exercise, then don't expect the code to be good enough for real use. Also, I should mention that I had almost no experience with Julia, so it probably is not idiomatic Julia but more Python-like Julia.


This post is a summary of that challenge. For the source code you can check the repository.

The verdict

Since the challenge is with myself, and the main purpose was to learn some Julia the verdict is: success. Nevertheless, I failed during day 26 with the Boundary Element Method.

The list of methods

Day Numerical method
01 Bisection
02 Regula falsi
03 Newton
04 Newton multivariate
05 Broyden
06 Gradient descent
07 Nelder-Mead
08 Newton for optimization
09 Lagrange interpolation
10 Lagrange interpolation with Lobatto sampling
11 Lagrange interpolation using Vandermonde matrix
12 Hermite interpolation
13 Spline interpolation
14 Trapezoid quadrature
15 Simpson quadrature
16 Clenshaw-Curtis quadrature
17 Euler integration
18 Runge-Kutta integration
19 Verlet integration
20 Shooting method
21 Finite differences with Jacobi method
22 Finite differences for eigenvalues
23 Ritz method
24 Finite element method in 1D
25 Finite element method in 2D
26 Boundary element method
27 Monte-Carlo integration
28 LU factorization
29 Cholesky factorization
30 Conjugate gradient
31 Finite element method with solver


  • This was an exercise of code-kata to learn some of the details of Julia for scientific computing. As such, it was really useful for me to get my hands dirty with Julia.
  • Implementing the Boundary Element Method in one day seems to be rough. I knew this beforehand, but I gave it a try anyways ... without succcess.
  • Julia syntax is somewhat in a sweetspot between Python and MATLAB. This makes it really easy to use, although the documentation of some packages is at an arcane stage right now.
  • I won't take a challenge like this in a while. It takes a lot of atttention to get it done.


Comments powered by Disqus