Stack Exchange Network

Stack Exchange network consists of 175 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 [differential-equations]

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

2
votes
2answers
52 views

System of coupled differential equations

I am trying to solve the following system of equations, but I get as the output the command itself. ...
2
votes
1answer
69 views

Help in advection-dispersion equation using NDSolveValue

i have the advection-dispersion equation: Dz = 0.0000738739; as = 2.21622*10^-6; Dz*D[u[z, t], z, z] - as*D[u[z, t], z] == D[u[z, t], t] The boundary and ...
0
votes
0answers
42 views

Issues solving system of differential equations [on hold]

d = NDSolve [{x''[t] == (x [t] + a[t])/(-2), a''[t] == -x''[t]/2, x[0] == 0, x'[0] == 1, a[0] == 0, a'[0] == 0}, {x, y}, {t, 20}] Keeps returning the error "To ...
7
votes
1answer
155 views

How to add solutions from potential flow calculations (including circulation)?

Now we have the finite element method how do you combine potential functions appropriately? A classic problem is to calculate the lift on an aerofoil by adding circulation to a potential flow ...
1
vote
1answer
76 views

Conditional evaluation: black hole cross section

I'm trying to calculate the collision cross section of black holes, more precisely, I want the critical impact parameter $b_{\text{crit}}$ for a given initial velocity $v$ such that, at this speed, ...
0
votes
1answer
44 views

Update initial conditions recursively/sequentially within ParallelTable using NDSolve

I am modelling 3D motion of particles inside a force-field using second-order coupled PDEs, which I solve from time t=t0 to t=t1 with initial conditions x0,y0,z0. I have a total number of "particles" ...
2
votes
2answers
49 views

Finding the amplitude of function solved using ParametricNDSolve

I have been trying to find the peaks of a function I have plotted using ParametricNDSolve. I have to find these peaks to calculate the amplitude of all the various waves in the observed output. By ...
3
votes
2answers
100 views

Heat equation with variable conductivity

Let us consider the (very simple) problem $\qquad \partial_x[k(x)\,\partial_xu]=0,\quad x\in [0,1]$ $\qquad u(0)=0,\ u(1)=1,$ with $l\in(0,1)$ $\qquad k(x)=\left\{\begin{array}{l}k_1^{},x<l\\k_2^...
3
votes
1answer
105 views

How to specify non-reflective boundary conditions when NDSolving two coupled first order PDEs?

Due to a lack of fruitful answers after 3 days, this question has been reformulated in a more direct way compared to its first version. Consider the telegraph equation problem expressed as a system ...
4
votes
1answer
95 views

Concerning the origin of four terms in DSolve's hyperbolic solution to an ODE

Typing DSolve[{g''[y] - k^2/Gy g[y] == 0}, g[y], y] where $k$ and $G_y$ are constants gives $$\left\{\left\{g(y)\to C_1 \exp\left(\frac{k y}{\sqrt{G_y}}\right)+...
1
vote
0answers
27 views

Analytic solution of a system of six ODEs [duplicate]

I have a system of six ODEs for six function. I want to get the analytic solution of the system. I have used DSolve, but it can not solve it. The code is: ...
1
vote
1answer
86 views

How to show the Chebyshev polynomials in the solution of a differential equation?

In the following code I solved a differential equation on Mathematica 11. The solution has two arbitrary constants, which, if set to 0 and 1, in previous versions of Mathematica used to give as the ...
3
votes
2answers
84 views

How to solve these ODEs using NDSolve?

I have six odes and I cannot use DSolve. So I tried NDSolve. But it says there may be some errors.The code is such like this: ...
1
vote
1answer
39 views

Use ParametricNDSolveValue for system of equations

I'm trying to use ParametricNDSolveValue for a system of equations. I want to have it create a function that takes in a single input and outputs a list. Here is my code thus far. ...
3
votes
1answer
531 views

Undershoot/Overshoot Method for this differential equation?

I have tried to solve this equation for some weeks and I am not capable. I have read in articles that it is easy with an undershoot/overshoot method, but I don't know how to do it. $y''+\frac{3}{x}y'-...
-1
votes
1answer
141 views

Working with motion equations

I'm trying to solve some Lagrange differential equations of motion, where $L = T - U$. Also, how can I use the solution for each x1, x2, x3, ..., xn? Here is my code: ...
2
votes
1answer
350 views

NDSolve going outside of the range of the interpolating function

I am trying to solve a differential equation that contains some interpolating functions as input, and for reasons unknown to me I am encountering an error which makes Mathematica use extrapolation. I ...
0
votes
2answers
50 views

Dealing with Infinite expression errors

I'm currently trying to generate a plot showing what happens to a damped oscillator when it's critically damped using the following code: ...
0
votes
1answer
48 views

I am trying to solve these Chemotaxis Equations but I can't seem to make it work

I am trying to solve a a pair of coupled partial differential equations but it doesn't seem to work. I am getting the error 'Length of the derivative order is not u1[t,x]the same as the number of ...
0
votes
1answer
67 views

Why does my SIR differential equation solver not work?

I'm trying to solve a system of SIR differential equations with Mathematica. My code is: ...
0
votes
0answers
45 views

DSolve leads to an equation that is different from paper solution

I'm following the method in the two images in an attempt to obtain a value for $\beta$. I know that there's a mistake in (4.36) from here so I used Mathematica's solution to continue the solution. I ...
2
votes
2answers
58 views

Extra constant in solution of ODE using DSolve [on hold]

A paper that I have states that the solution of the ODE $$-\frac{\left(\frac{\pi k}{a}\right)^2 Y(y)}{G_y}+\frac{Y''(y)}{G_x}+\frac{8 \theta }{\pi k}=0$$ is $$Y=A\sinh\left(\frac{k\pi\mu}{a}y\right)+...
0
votes
0answers
62 views

Need help solving ODE

Can I solve the given equation using Mathematica? A = Log[a]; H = 1/a*D[a[t], t]; DSolve[{1/H*H'''[A] - 20*H == 0}, H[A], A] I am facing difficulties to solve ...
3
votes
1answer
273 views

1st-order linear ODE system gives inaccurate/biased solutions

Consider an ODE eigensystem $$ t(y+\frac{1}{s})a(y)+[(q+\frac{1}{2}+\frac{s}{2}y)+s(y\partial_y+\frac{1}{2})]b(y)=\lambda a(y)\\ t(y+\frac{1}{s})b(y)+[(q+\frac{1}{2}+\frac{s}{2}y)-s(y\partial_y+\frac{...
0
votes
0answers
63 views

Solve a system of coupled partial differential equations in 2D

I am new at Mathematica and I am trying to solve this system of coupled partial differential equations in 2D in cylindrical coordinates, where the model is axysimmetric, around the z axis. $\frac{1}...
0
votes
1answer
44 views

Solve differential equations with matrix exponential [closed]

I wanted to solve a differential equations by matrix exponential ...
1
vote
1answer
68 views

Problem finding constants after using DSolve

I have to solve a relatively simple PDE: $$\frac{\phi_{xx}(x,y)}{A}+\frac{\phi_{yy}(x,y)}{B}=-2 \theta$$ where $A$, $B$, and $\theta$ are constants. The code that I used was ...
-1
votes
0answers
63 views

Analytic solution for two coupled Partial Differential Equations using DSolve [closed]

I am looking for an analytic solution to the following two coupled equations for $v(x,t)$ and $u(x,t)$: $$\frac{\partial v}{\partial x}=-m \frac{\partial u}{\partial t}$$ $$\frac{\partial u}{\partial ...
2
votes
1answer
180 views

ODE of an eccentric circle

How can we simplify the solution in: DSolve[ {Sqrt[ 1 - (r[t] - T^2/r[t])^2/(2 a)^2]/(r[t] - T^2/r[t])/(2 a) == r'[t]/ r[t], r[0] == T}, r, t] (r,t) are polar ...
2
votes
1answer
26 views

Trouble using ParametricNDSolve in Manipulate

I have troubles to understand how to use Manipulate and ParametricNDSolve to have modulable parameters inside my models. I ...
2
votes
1answer
45 views

Eliminating Discontinuities When Using Mod with NDSolve and Plot for Oscillators

I have found similar questions to mine, but dealing with piecewise and parametric plots instead and unfortunately the answers don't seem to extend to my case. I have a solution from ...
0
votes
1answer
62 views

Solving Coupled system of differential equation with NDSolve

I am solving a system with coupled system of differential equation to obtain the time evolution of two vectors. The problem stated here is equivalent to solving Landau Lifschitz Gilbert equationLLG ...
3
votes
2answers
131 views

Bifurcation diagram of nonlinear system of ODE [duplicate]

Welcome to all, I try to apply most suggestion codes of a plot bifurcation diagram but I could not, I got an error. Is there anyone who can help me to understand how I can plot a bifurcation diagram ...
1
vote
2answers
1k views

How to make a bifurcation diagram of the Lorenz system under a varying parameter value?

I'm trying to represent the behaviour of the system $\color{red}{r}$ varies from $\color{red}{1}$ to $\color{red}{100}$ statically (for instance something similar to a bifurcation graph)? \begin{...
2
votes
1answer
72 views

Having trouble using WhenEvent with NDSolve

First of all, this is my first time on this forum. Please be patient with me because if I make some mistakes in this post. I'm not used to doing this! I'm trying to modify a parameter during ...
10
votes
1answer
1k views

How to change a parameter dynamically inside NDSolve

I have no idea how to dynamically update a parameter inside NDSolve. For example consider following first-order DE: ...
0
votes
1answer
82 views
1
vote
0answers
167 views

Solving an ODE using shooting method [duplicate]

I have been trying to solve the following nonlinear ordinary differential equation: $$-\Phi''-\frac{3}{r}\Phi'+\Phi-\frac{3}{2}\Phi^{2}+\frac{\alpha}{2}\Phi^{3}=0$$ with boundary conditions $$\Phi'(...
4
votes
1answer
352 views

DSolve, Partial equations, The arguments should be ordered consistently

How do I solve a differential equation when one of the arguments requires that the value of one variable is equal to the value of the other variable, when I try this I get this error: "DSolve::conarg:...
1
vote
1answer
64 views

Solve Euler Lagrange equation of motion DSolve

I'm trying to find Euler Lagrange equation of motion. then DSolve the equation for list of variable x1,x2,x3,x4 Here is my code: ...
0
votes
1answer
1k views

How to obtain differential equations of motion using Lagrangian dynamics?

I'm confused to find a set of differential equations of motion of a pair of masses, m1 and m2 joined by a spring of constant <...
2
votes
2answers
181 views

NDSolve error in 2-D heat equation

I'm trying to solve the following PDE by Mathematica in 2-D case in the unit disk using polar cordinates, where $\Omega$ is a bounded domain of $\mathbb{R}^n$, $\Gamma =\partial \Omega$ is the ...
2
votes
1answer
1k views

Laplace PDE in a polar coordinate system

I want to solve a Laplace PDE in a polar coordinate system with finite difference method, but I have a problem with boundary conditions at r = 0. Here is what I ...
1
vote
0answers
73 views

How can I improve and accelerate my 2 D algorithm?

I implemented the algorithm descussed here in the 1 D case (when $g$ is one variable function). Using a relaxation parameter the algorithm became very fast and converges in few iterations (n = 5, 6, , ...
0
votes
2answers
101 views

Transform expression into a certain standard form for an ODE

I'm using Mathmatica 11.1 on Windows. Given an expression containing a differntial equation of the form $\qquad A\, x'(z) = C\, x''(z) - B\, x(z)$ Or ...