A message from our CEO about the future of Stack Overflow and Stack Exchange. Read now.

# Tag Info

26

There are a few ways to conserve energy during ODE integration. Method 1: Symplectic Integration The cheapest way that is to use a symplectic integrator. A symplectic integrator solves the ODE on a symplectic manifold if it comes from one, and so if the system comes from a Hamlitonian system, then it will solve on some perturbed Hamiltonian trajectory. ...

10

You'll get everyone to give different answers to this question, and maybe that's alright. Here are some of my favorite ones: Taylor's theorem that a function (of sufficient smoothness) equals its Taylor expansion plus a remainder term. One can consider the Bramble-Hilbert lemma as a variation of Taylor's theorem, but it has different applications and is ...

4

Crank-Nicolson is a very good classical approach for parabolic PDE like the heat transfer PDE to which it was originally applied. It is relatively easy to understand and implement so it is often presented in basic courses on numerical methods for PDE. pdepe is also very well-suited to this class of PDE (the second "p" in pdepe stands for parabolic). It has ...

3

A search for the specific coefficients listed led me to the method ROS3PRL from J. Sieber, Konvergenzanalyse und Numerische Tests für die Prothero–Robinson–Gleichung (Master thesis), TU Darmstadt, 2014. I can't seem to find this thesis online, but the method is mentioned in the following which may be of interest. Rang, Joachim. "Improved traditional ...

2

Since this is a question with pretty subjective answers, I'll add a couple to Prof. Bangerth's very good list. the theorem of adjoint/dual operators and spaces is pretty crucial to Computational Science. We know that dual-consistent discretizations of the PDEs can obtain superconvergence which is a nice property. But I think the more commonly used outcomes ...

1

After thinking about this some more, I can answer this one myself! I don't think the complex plane makes the log-sum-exp trick appreciably different, at least in Cartesian coordinates. In particular, if $z=u+iv$ then $e^z=e^{u+iv}=e^u (\cos v + i\sin v).$ Notice the $v$ part has magnitude 1 by construction, so overflow or underflow is principally caused ...

1

Following @njuffa, I used the arbitrary precision R package Rmpfr to compute a golden test reference, with 1024 bits of precision. Here is a plot of relative error, for both the straightforward definition, and the Taylor series (quintic polynomial) approximation (both using double-precision): The optimal $\delta$ is where the two curves cross, and is about ...

1

So I ran with my adjoint solver, but without a singularity on a sequence of refined meshes, and didn't see that behavior, as expected. My guess is as follows: If you think of the adjoint vector as a green's function, relating perturbations in the residual operator to a delta in the objective function (in this case weighted projections of pressure), I ...

Only top voted, non community-wiki answers of a minimum length are eligible