Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [stability]

The study of the propagation of errors in a numerical algorithm.

2
votes
1answer
60 views

Generate high n quantum harmonic oscillator states numerically

How can I generate the higher $n$ quantum harmonic oscillator wavefunction (in position space) numerically? Here, higher means around $n=500$, or say $n=2000$, where $n$ is the $n$th oscillator ...
5
votes
0answers
106 views

Any way to avoid catastrophic cancellation when computing the discriminant of a quadratic function?

Homework disclaimer... The task: We are using the following algorithm to solve the quadratic equation $x^2+2px+q=0$: $x_1=|p|+\sqrt{p^2-q}\mathtt{;}$ $\mathtt{if}\,p>0\,\mathtt{then}\,...
3
votes
2answers
75 views

1+x not backwards stable?

If you compute 1+x for x less than the machine precision, the answer will be 1 which is the ...
5
votes
2answers
100 views

Fast and Numerically Stable Pairwise Distance Algorithms

I'm looking for resources on fast, numerically stable pairwise euclidean distance algorithms. In particular, suppose $A \in \mathbb{R}^{M \times D}$ and $B \in \mathbb{R}^{N \times D}$ are two sets of ...
2
votes
1answer
75 views

Stability Analysis

The partial differential equation, \begin{align} \dfrac{\partial f}{\partial x} + a(x)\dfrac{\partial f}{\partial y} = 0 \qquad & f(0,y) = f(L_1,y) = c_0e^{-y} \\ & f(x,0) = c_0 \;,\; f(x,L_2) ...
4
votes
0answers
63 views

Automatic differentiation of barycentric rational functions

By a barycentric rational interpolant we understand a function of the form \begin{align*} r(t) := \frac{\sum_{i=0}^{n-1} \frac{w_i y_i}{t-t_i} }{ \sum_{i=0}^{n-1} \frac{w_i}{t-t_i}} \end{align*} In ...
4
votes
2answers
154 views

Why is my simulation of a first-order wave equation not stable?

According to the equation $$ \frac{\partial y}{\partial t} = -a\frac{\partial y}{\partial x} $$ I simulated this in python. I used center differentiation, and I determined step size based on Von-...
2
votes
1answer
106 views

Von Neumann's stability analysis on non linear and coupled equations

I'd like to know if is possible to make a Von Neumann's stability analysis on an system of coupled equations, featuring quadratics: $$\begin{aligned} \frac{\partial u_1}{\partial t}&=D_1\Delta ...
0
votes
1answer
153 views

Numerical Sensitivity in Density of States of Tight-binding model

I'm working with the tight-binding model, and I'm trying to learn the basics of how to compute the Density of States (DOS) $N(E)$ numerically. The DOS is given by $$N(E) = \frac{1}{N}\sum_k \delta(...
1
vote
1answer
15 views

Implementation of a ratio with a well-defined limit

I'm implementing a function $f(x_1, x_2, \dots x_n)$ given by the ratio of two closed form equations. $$ f(x_1, x_2, \dots, x_n) = \frac{g(x_1, x_2, \dots, x_n)}{h(x_1, x_2, \dots, x_n)} $$ ...
1
vote
0answers
32 views

Stability of different quadrature rules in 1st-kind Volterra integral equation

I am dealing with a integral equation $$ f'(t) = -\int_0^t K(s) f(t-s)\quad t\in [0,t_\max] \tag{1}$$ in which $f(t)$ and $f'(t)$ are known, well-behaved functions of $t$ and $K(t)$ is the unknown. In ...
4
votes
0answers
83 views

Crank-Nicolson integrator: oscillations with complex matrix

I'm working on a Real-Time TDDFT implementation and I am currently comparing different propagation schemes for the propagation of the Kohn-Sham wave function, $$ \phi(t+\Delta t) = \hat{\mathcal{U}}\...
9
votes
2answers
245 views

Lagrange multipliers space is too rich in a mathematical view

Background: Lagrange multiplier method has been employed in numerous fields, such as contact problems, material interfaces, phase transformation, stiff constraints or sliding along interfaces. It is ...
1
vote
0answers
50 views

Detecting stability in solutions to coupled nonlinear equations in aerodynamics,

I'm studying a quasi-steady force model (published in a fluid dynamics journal) that consists of coupled, nonlinear ODEs that describe unsteady aerodynamics -- recently, my advisor and I have found ...
1
vote
1answer
165 views

Method to solve linear, first order ODE of generalized matrix matrix form

The equation and its meaning: Consider two sets $(A)_{l=0,...,m_a},$,$(B)_{l=0,...,m_b}$ of hermitian matrices and a set of positive semidefinite matrices $(C)_{l=0,...,m_c}$. Each matrix has the ...
3
votes
0answers
184 views

Von Neumann analysis for coupled PDE's

I am interested in understanding how to perform stability analysis for coupled (to keep things do-able, lets say linear) PDE's In the case of a single PDE, i understand the logic behind the VN ...
4
votes
1answer
167 views

Clenshaw-type recurrence for derivative of Chebyshev series

The naive summation of a Chebyshev series \begin{align*} f(x) = \frac{c_0}{2} + \sum_{k=1}^{n-1} c_{k}T_{k}(x) \end{align*} which employs the three-term recurrence for evaluation of the Chebyshev ...
0
votes
1answer
385 views

Finite Difference Method Limitations/Stability Criteria

Is it possible to solve an equation with only a single derivative such as: $$\frac{\partial U(x,t)}{\partial t} = A - BU(x,t)$$ with finite difference methods? I ask as I am trying to solve the ...
2
votes
2answers
163 views

von Neumann stability analysis for spatial variable flux

Can we use the von Neumann stability analysis to investigate the stability of the discrete form of the following problem? $$u_t+\frac{\partial(x^2u)}{\partial x}=S(u,x)\ .$$ Please give some hint ...
6
votes
1answer
83 views

Stable computation of ratio of sums of large numbers

I have two sets of large positive numbers $a_1,\ldots,a_n$ and $b_1,\ldots,b_n$. By 'large' I mean of the order of $10^{10}$. I want to calculate the ratio $$R = \frac{a_1 - a_2 + \cdots +(-1)^{n+1}...
4
votes
1answer
124 views

Stability of PDE Discretizations with Multistep Time Discretizations

Let's pretend we have a spatially discretized PDE of the following form: \begin{align} \frac{\partial^2 \boldsymbol{u}^k}{\partial t^2} = D\boldsymbol{u}^k \end{align} where $D$ can be any form for ...
5
votes
1answer
507 views

Von Neumann stability analysis with a constant term

I have a question concerning the von Neumann stability analysis of finite difference approximations of PDEs. There seem to be a wealth of online source explaining the application of this stability ...
10
votes
2answers
335 views

How much regularization to add to make SVD stable?

I've been using Intel MKL's SVD (dgesvd through SciPy) and noticed that results are are significantly different when I change precision between ...
1
vote
0answers
216 views

Stability of nonlinear partial differential equation

I want to find an expression for the stability of the nonlinear Poisson equation. I know about von Neumann stability analysis which applies to linear equations as far as I know. Any suggestion how to ...
1
vote
0answers
79 views

Kahan Summation for Three-Term Recurrences

Kahan summation applies to summation problems, but not to three-term recurrence relations. However, a three-term recurrence shares many of the features of a summation-albeit with a rescaling step at ...
6
votes
1answer
760 views

What is the origin of the spurious oscillations in the Crank-Nicolson scheme?

I was reading about the Crank-Nicolson method, and it is often said that it can produce "spurious oscillations" or that this method is prone to "ringing", especially for large time step and stiff ...
1
vote
1answer
492 views

Improve numeric stability of subtraction in C++ [closed]

I'm writing a matrix library in c++. After some debugging I found that a simple double difference is not zero for two "equals" numbers. This is due how double are represented in a computer of course. ...
8
votes
1answer
314 views

CFL condition in polar coordinates

In this question, I suggested that the Couran-Friedrichs-Lewy (CFL) condition for the wave equation in polar coordinates reads $$C = 2c\frac{\Delta t}{\Delta r \Delta \phi} \leq C_\max \enspace ,$$ ...
4
votes
1answer
80 views

Finding Numerical Stability of Simple System with Integral Term Due to Low Pass Filter

As a toy problem, I was looking at a classical second order system of the following form: \begin{align} \ddot{x}(t) + c \dot{x}(t) + k x(t) = 0 \end{align} Instead of the basic system above, I want ...
4
votes
2answers
116 views

In numerical methods, eg, finite differencing approaches, does there exist convergent schemes that are not both consistent and stable?

In a book that our course is following this semester, the theorem given is only in one direction: if the scheme is both consistent and stable, then the scheme is convergent. However, since this ...
6
votes
3answers
2k views

What is the meaning of stability in numerical analysis? How to deterimne the stability of a numerical method?

My question may be so general and simple but I'm really confused about the meaning of the "stability". I look that up in the Internet but there was no general answer to this question. Can anyone help ...
0
votes
0answers
122 views

how to do von neuman stability analysis for given equation

I have two coupled differential equations. Their implicit schemes were given below. is there anyone who will do "von neuman stability analysis". because i need to know in which conditions my solution ...
0
votes
1answer
543 views

How to choose the relaxation time in the Lattice Boltzmann Method?

We know that the relaxation time is very important in LBM. I have searched lost of papers, but can't find some systematic introductions about the choice of relaxation time in SRT LBM. Could you give ...
1
vote
0answers
112 views

Stability of the explicit MacCormack Scheme to solve the Navier Stokes equations with Wilcox's K-Omega Turbulence Model

I am solving turbulent pipe flow with an explicit MacCormack scheme and Wilcox k-omega model. The laminar version of the code had three distinct stability criteria which worked fine after ...
0
votes
1answer
201 views

Runge-Kutta Stability Regions

Based on this link, in particular Figure 1, what is the exact meaning of the plot? To my understanding, it implies that for a given differential equation: $$ \frac {dy}{dt} = \lambda y $$ that the ...
1
vote
0answers
73 views

Methods to approximate discretized derivatives in PDEs

When solving a general PDE such as $$ \frac {\partial ^2 E}{\partial t ^2} = \frac {\partial ^2 E}{\partial z ^2} - \frac {\partial E}{\partial z} $$ this equation can be solved by the method of ...
2
votes
2answers
110 views

How to support or contradict a hypothesis on unconditional stability using numerical optimization

The main motivation behind my next question is that I think I derived a higher order numerical scheme for linear advection equation that is unconditionally stable using Von Neumann stability analysis. ...
2
votes
1answer
177 views

What does it mean for a finite difference scheme to be $L^1$-stable?

I am trying to answer a question about a finite difference scheme. I need to show that the method is stable in the L1-norm. I can't find a single definition of what that means, so does anyone have a ...
1
vote
1answer
113 views

Stability condition for explicit/implicit via non negative coefficients

To make stability proofs simpler, I can consider an explicit scheme written as $$V(n+1,i)=aV(n,i-1)+bV(n,i)+cV(n,i+1)$$ and one can show that if $a,b,c\ge 0$ and $a+b+c\le1$, then the explicit method ...
1
vote
1answer
276 views

More Smearing with decreasing timestep in advection problems

I find it kind of counter intuitive, that the result of an advection gets more smeared out at the borders when decreasing the timestep (which should make it more accurate). Let there be a equally ...
4
votes
0answers
184 views

Stability analysis for a hyperbolic PDE on staggered grid

I am trying to understand the stability of a finite difference equation on the staggered grid. I could understand the Von Neumann stability analysis for the collocated grid for a simple acoustic ...
-1
votes
2answers
267 views

Stability of matrix equations in MATLAB

Is there a method to check for unconditional stability or positive-definiteness of large matrices in MATLAB? For example, I know that matrices with property M (positive main diagonal elements and ...
5
votes
0answers
106 views

Using entropy functions for increasing numerical stability

Regarding the numerical stabilization of two-dimensional advection equation, \begin{equation} \dfrac{\partial f}{\partial t} + \Big(\dfrac{d\varepsilon_1(k)}{dk}\Big)\dfrac{\partial f}{\partial z} - \...
3
votes
1answer
189 views

Stability Criterion for this Explicit Scheme

I am solving an unsteady flow using the dual-time Navier-Stokes equation in which I write my momentum equation as: $$\frac{\partial u}{\partial \tau} + \frac{\partial u}{\partial t} + \frac{\partial u^...
-1
votes
1answer
461 views

Stability analysis for coupled nonlinear system of partial differential equations

I'm trying to solve a nonlinear partial differential equation \begin{equation} L(u_{xxtt},u_{xx}u_{tt},u_{xt}^2,u_{xt},u_{tt})=0 \end{equation} using finite difference methods. In order to remove the ...
1
vote
1answer
189 views

Calculate inverse of dense matrix with entries of very different magnitude

I need to calculate the inverse of a dense matrix, with some elements taking values as high as 1e9 and some around 1e2. What would be the best method to do it? Note: I am more concerned about the ...
9
votes
2answers
974 views

What does the Von Neumann's stability analysis tell us about non-linear finite difference equations?

I am reading a paper [1] where they solve the following non-linear equation \begin{equation} u_t + u_x + uu_x - u_{xxt} = 0 \end{equation} using finite difference methods. They also analyse the ...
16
votes
1answer
200 views

Usefulness of elements with mesh-dependent stability

After doing some mathematics related to the stability of elements in 3D Stokes problem I was slightly shocked to realize that $P_2-P_1$ is not stable for an arbitrary tetrahedral mesh. More precisely, ...
1
vote
0answers
36 views

Stability in Discretization of 1D Stationary Boltzmann equation

I want to discretize and numerically solve the following PDE: \begin{equation} v(k)\dfrac{\partial f}{\partial x} + E(x)\dfrac{\partial f}{\partial k} = S\{f\} \end{equation} using finite volume (box ...
3
votes
1answer
166 views

Stability in discretization of a PDE

Suppose I want to numerically solve for $f(x,k)$ the one-dimensional Boltzmann equation for electrons in steady-state condition, given as: \begin{equation} \left( \dfrac{\hbar k}{m} \right) \dfrac{\...