# Tag Info

Accepted

### Why do we solve non-linearity in hyperbolic PDEs that way?

The good thing about the conservative form is that this comprises multiple models, such as Shallow Water Equations, Euler Equations or traffic models. An essential feature of hyperbolic equations is ...
Accepted

### How to solve the problem without using symbolic computation

You can solve this numerically in Python without symbolic computation. from __future__ import print_function, division import numpy as np from numpy import exp from scipy.integrate import quad from ...

### Limitations with dynamical systems vs. PDEs?

PDEs are a form of dynamical system where there is another continuous variable. Usually this is space, so you're looking at how things over time and space instead of just over time. Here's an ...

### Jacobians with automatic differentiation

Julia has a whole ecosystem for generating sparsity patterns and doing sparse automatic differentiation in a way that mixes with scientific computing and machine learning (or scientific machine ...

### Solving a linear equation system with pure Neumann condition

Pure Neumann problem is unique up to a constant. My two favourite solution strategies: Modifying the equation $-\Delta u = f$ to $-\Delta u + \varepsilon u = f$ for some small $\varepsilon>0$. If ...
Accepted

Accepted

### treating "almost linear" nonlinear least-squares problems

If you change variables to optimize for the residual of the linear part, then the Hessian will be a low-rank update to the identity. Then L-BFGS would work very well. Specifically, your problem takes ...
Accepted

### GMRES vs Newton-GMRES for Solving nonlinear PDE's

The reason is that GMRES can only be used for solving linear equations, i.e. equations of the form $Ax=b$, where $A$ is some matrix and $x,b$ are vectors. What GMRES does, essentially, is it ...

### What are systematic ways of approximating a non-smooth (non-continuously differentiable) system dynamic to be n-smooth?

Two systematic ways of smoothing a function $h$ would be: 1. Join the piecewise smooth parts of your function using Hermite interpolation so that the derivatives are matched to your satisfaction. 2. ...
Accepted

### 2d Euler manufactured solutions

This 2004 paper by Roy et. al in Int. J. Numer. Meth. Fluids 2004; 44:599–620 (DOI: 10.1002/d.660) should contain exactly what you're looking for: ftp://ftp.demec.ufpr.br/CFD/bibliografia/...
Accepted

### What is the preferred method for evolving the Nonlinear Schrödinger Equation?

You won't find universal agreement among experts on a single best way to solve this equation. On the other hand, since it is a PDE in one spatial dimension there are many approaches that will give ...
Accepted

### Pseudo Code for non linear power function fit needed

Chapter 10 of Numerical Analysis (Richard L. Burden, J. Douglas Faires) gives good readable pseudo code for Newtons method. The start parameters are taken from the solution of the linear problem of ...
Accepted

### What would be a good approach to solving this large data non-linear least squares optimisation

I don't know much about tracking implicit surfaces, so I'm just going to start with the optimization problem and go from there. The optimization problem is, at the core, nonlinear least squares, and ...
Accepted

### Discrete-time Algebraic Riccati Equation (DARE) solver in C++

If you want a ten-line solution that is decently fast and stable, you can implement yourself the structured doubling algorithm: set up the coupled iteration $A_0 = A, G_0 = G = BR^{-1}B^T, H_0 = Q$ ...
Accepted

### Numerically solving a non-linear PDE

First off, the PDE can be rewritten instead as $$\frac{\partial C}{\partial t} = \frac{\partial}{\partial x}C\frac{\partial C}{\partial x}$$ or, by applying the product rule in reverse again, as \...
Accepted

### Solving system of nonlinear vector functions

If you have a single vector equation $\vec{F}(\vec{x})=0$ then you solve it by representing that state vector $\vec{x}$ as a set of amplitudes $[x_0,x_1,...,x_{n-1}]$ after discretization by your ...

### Spot redundant equations within nonlinear system of equations

In the example you give, the two equations are not redundant. Each of the two equations describes a set of lines in the 2d plane, and the lines happen to be tangential at a specific point -- which is ...
Accepted

### Algorithm for solving system of quadratic equations and linear equations

Quadratically constrained quadratic programming (QCQP) focuses on convex inequalities because those preserve the convexity of the problem. Quadratic equalities do not, so this problem is much harder. ...

### Solving a linear equation system with pure Neumann condition

Including even one Dirichelt condition changes the problem you are trying to solve and will not give you the correct solution! You must fulfil the Discrete Compatibility Criteria, see e.g. first and ...
Accepted

### Methods of solving non-linear advection-diffusion systems beyond Newton-Raphson?

I'm assuming the limitation in 2D and 3D is storing the Jacobian. One option is to retain the time derivatives and use an explicit "pseudo" time-stepping to iterate to steady state. Normally the CFL ...
Accepted

### Evolving nonlinear Schrodinger equation with higher-order algorithms?

Your added edit to the question points exactly the way this needs to be done: You first evolve your field using a half-step with the $\hat D$ operator, then a full step with the $\hat N$ operator, and ...

### Solving ODE with multiple equilibriums

There are a couple of questions implicit in your post: How does one deal with non-uniqueness of the algebraic equations generated by any implicit numerical method? Typically you have a very good ...