Questions tagged [differential-equations]

Questions on the symbolic (DSolve, DifferentialRoot) and numerical (NDSolve) solutions of differential equations in Mathematica.

4,241 questions
Filter by
Sorted by
Tagged with
2k views

Wrong answer from DSolve when solving a differential equation

Bug introduced in 12.0.0 I was trying to solve the following differential equation: $$\frac{dy}{dx}=x^2+y^2-1 \quad \text{and} \quad y(0)=1$$ and I used the code below: ...
38 views

Manipulate plot of a system of PDEs with NDSolve

Modeling 1D diffusion of an enzyme, e, through a sphere with substrate, s, I arrive at the below equations: I then pass these equations to NDSolve, Evaluate at a range of r and t and Plot and ...
91 views

Adding a limit in NDSolve to avoid division by zero

I'm trying to solve a set of differential equations in which one of the functions that describe the time derivative gets values which make it divide by zero ...
460 views

Solver for unsteady flow with the use of the Navier-Stokes and Mathematica FEM

There are many commercial and open code for solving the problems of unsteady flows. We are interested in the possibility of solving these problems using Mathematica FEM. Previously proposed solvers ...
74 views

Solution to eigenvalue BVP using NDEigensystem to high precision

I'm trying to solve linear (non-self-adjoint) boundary-value problems to as high precision as possible (optimally 1e-15). For example, the below code solves for the first 5 eigenvalues of the harmonic ...
63 views

Why doesn't Mathematica find solution for differential equation when Wolfram Alpha does?

I need to solve differential equation: dy/dx=tan(1/2*(Pi/2+arctan((|3tan(35*Pi/180)-x|)/(y+3)))), y(0)=0 Wolfram Alpha gives me the output in shape of plot and I need to get the formula used by ...
61 views

Why is NDSolve not working for the given system?

I'm trying to find the solution curves for a system of differential equations. In order to try to complete this task, I've attempted to use NDSolve, but I get an error that says that there are fewer ...
188 views

Boundary value problem for 2 coupled ODE's using NDSolve: “singularity or stiff system suspected”

I'm trying to solve a pair of coupled ODE's. I need to place four Dirichlet boundary conditions (at R = 0 and R = ∞ for each ...
63 views

Why does trying to plot the solution to this system of ODEs this way lead to errors?

I would like to plot the curve $\alpha(s) = (l(s), h(s))$, where $l$ and $h$ are the solutions to the system $l'^2 + h'^2 = 1$ and $l'h''-l''h'=h'\tan(l)$. Here's what I tried: ...
45 views

354 views

214 views

Solution of Burgers equation with some initial data

Consider the Burgers equation $$\partial_t u + \partial_x\left(u^2/2 \right) = 0, \quad u(0, x) = u_0(x).$$ eq = D[u[t, x], t] + D[u[t,x]^2/2, x] == 0 How ...
39 views

Maximizing an integral/Solving the associated Euler-Lagrange equation

Case 1 I have the following integral which I need to numerically maximize. Here $v = v(u)$. $$V = \int_{u_l}^{u_r} du\sqrt{\frac{4}{(1+uv)^2} \frac{(1-uv)^2}{(1+uv)^2}\frac{dv}{du}}$$ The ...
48 views

Plot solution of partial integro-differentiatial equation

I would like to plot solution to a differential equation using ParametricNDSolve3D. The indepedent variable f has arguments q and t where q represents angle between 0 and 2pi while t represents time. ...
70 views

Using ParametricNDSolve with n subscripted functions

I want to calculate trajectories of an n-pendulum. For the number n=1 it's just a pendulum, for n=2 a double pendulum , for n=3 a triple and so on. The Solver has to solve n equations for the angle. ...
143 views

Eigen value solution of coupled ODEs

I want an eigen value solution of following coupled ODEs: But the code showing errors. ...
29 views

Verify that a PDE is satisfied by a matrix consisting of functions satisfying a different PDE

My problem is as follows: I have two matrices $P$ and $Q$ which are made up of algebraic expressions of a function $q(x,t)$ which solves a somewhat complicated pde, and its derivatives, for example, ...
90 views

Eigenvalue dependent boundary conditions- mathematica

I am dealing with an eigenvalue problem whose boundary conditions are also eigenvalue dependent. Could anyone please comment whether Mathematica can numerically solve such a problem? For boundary ...
734 views

Finding terms of the perturbation solution

I've got a task to find first three terms of the perturbation series solution to: $$y' = 1 +(1+\epsilon)y^2,\quad y(0)=1, \quad t > 0,$$ for a small $\epsilon$. I am supposed to use Mathematica ...
86 views

How to solve this second order differential equation?

The equation is given by: $$\frac{dv}{du}\left(2 u\frac{1-uv}{1+uv} + u\right) = \frac{v}{2} \frac{d^2v}{du^2} + v\frac{1-uv}{1+uv}$$ I tried using DSolve for ...
453 views

Solving an integro-differential equation with Mathematica

I try to solve a nonlinear integro-differential equation with this code. Here i used a periodic condition. ...
163 views

378 views

63 views

Evaluating Hough functions by using NDEigensystem on the Laplace tidal equation

Currently I am looking into the use of Mathematica to solve the classical tidal equation of M. Laplace: $$\mathcal{F}\Theta+\gamma\Theta=0$$ whose eigenfunctions $\Theta$ are the Hough functions. ...
337 views

Using NDEigensystem to solve the Mathieu equation

To be able to apply the differential equation capabilities of Mathematica to my graduate thesis, I am trying to apply NDEigensystem to an eigenproblem whose solution I know, but I am having some ...
79 views

NDSolve ERROR: There are more dependent variables, than equations, so the system is underdetermined

I have a question concerning NDSolve and a system of differential equations. I have 4 variables and 4 equations. Why do I get this ERROR :There are more dependent variables, {f[j,p],U[j,p],(f^(0,1))[...
814 views

Choosing FEM element type and mesh refinement

I have only recently been introduced to Mathematica's(v10.0) FEM capabilities. I understand that for solving PDEs on non-uniform shapes via NDSolve, Mathematica ...
126 views

Solving 2D Reaction-Diffusion with Explicit Euler Method

I am trying to solve this following 2D-Diffusion equation (I wrote it in Word, so it looks nice) (Note: I am solving this for a 100x100 mesh point) I tried to solve the above equation using the ...
35 views

NDSolve outcome depends on system size?

I tried to solve a simple wave equation numerically and plot the result within the time range t=0...1. Now when I change the tmax in the NDSolve the outcome of my plot (I don't change anything else ...
107 views

Errors in solving coupled pdes

I am trying to solve following coupled PDEs: I am not sure about suitable BCs. ...
261 views

Using NDEigensystem to solve coupled eigenvalue problem

I want to find the Eigenvalues and Eigenfunctions for the following Eigenvalue problem I tried to solve this numerically ...
93 views

Solution of Riccati equation of y'[z]==R(z) y(z)^2+Q(z) y(z)+P(z) type

I have seen that for Riccati equation the solution can be done by DSolve[y'[z] == P[z] + Q[z] y[z] + R[z] y[z]^2, y[z], z] but for my case mathematica fails to ...
39 views

Is this second order D.E. is solvable

DSolve[{(2.248*10^12) x^2 y''[x] + (4.496 x - 50.535)*10^12 y'[ x] - (1.17977*10^32) (x^3 Exp[-2 x] y[x] == 0, y[10] == 10^-5.3}, y[x], x] You can use b.c. ...
61 views

Could not solve this equation by Solve and also get nearly correct plot by Wolfram|Alpha [closed]

Input: Solve[y'[x] == -(224.8 ((y[x]^2 - y[x]/10^11 - (0.000010385 x^3)/E^(2 x))/x^2)), y[x], x] Output: ...
815 views

Mathematica 3D Heat Equation Solution

I've been working on trying to analyze the Heat Equation in water both experimentally and theoretically. The model goes as: there's a cuboidal bath (of say, 15x7x5 inches) filled with water, and an ...