Questions tagged [differential-equations]

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

Filter by
Sorted by
Tagged with
0
votes
0answers
17 views

Optimal way to approximate initial condition for PDE?

I have a Fokker-Planck PDE \begin{align} \frac{\partial p}{\partial L}(L,\eta) = \eta^2\frac{\partial^2 p}{\partial\eta^2}(L,\eta) +(1-2\eta)\frac{\partial p}{\partial\eta}(L,\eta)+\frac{2(\eta-1)}{\...
0
votes
0answers
35 views

NDSolve issue, potential singularity or stiff system

I have the following parameters, equations, and NDSolve solution set up as such: ...
2
votes
1answer
35 views

Numerical Issues Using Results of NDSolveValue

I am solving Laplace's Eqn. (Cartesians) in 2D in a region which is infinite in x, semi-infinite in y, and bounded by a function of x (h[x] in my code) close to y=0....
0
votes
1answer
60 views

How to plot solution of first order time dependent differential equations with other parameter not with time

I am trying to plot the solution given in the code with respect to "delc", not w.r.t time "t". I don't know what to do for getting the plot between solution and value "delc" which vary 0 to 2. The ...
0
votes
1answer
71 views

Calculate sensitivities of differential algebraic equation

I would like to calculate sensitivities for a DAE. The DAE can be solved in Mathematica by: ...
2
votes
1answer
39 views

AppendTo inside ParallelMap

I think this question has never been fully answered. In here the problem has already been mentioned, but let me give a MWE. I will solve a given ODE for a wide range of initial conditions and I want ...
1
vote
0answers
68 views
+50

The NDSolvevalue of MMA can not be used to solve the finite element problems according to the stress boundary conditions

The NDSolvevalue of MMA can well solve the finite element problems according to the displacement boundary conditions ...
1
vote
1answer
96 views

A system of differential equations [closed]

Consider the following system of differential equations: $$x'(t) = a\, x(t) - b \,x(t) y(t),$$ and $$ y'(t) = c\, x(t) y(t) - d \,y(t),$$ with $$ x(0) = x_0, y(0) = y_0$$ For example, we may have: <...
0
votes
0answers
50 views

Ground state Of Gross Pitaevskii Equation

I want to plot the ground state of Gross-Pitaevskii equation using NDSolve. I am using the following code: ...
4
votes
2answers
97 views

NDSolve and Euler method

I would like to solve $y'(x)=x^2-y^2,y(0)=4$ with two ways, NDSolve and Euler method, and with Runge-Kutta maybe. Then, I 'll try to plot all of them in one graph. I had with NDSolve: ...
0
votes
1answer
52 views

Shooting with updating BC's

So I have a 'fairly simple' problem that needs to be 'solved'. I have been able to solve this running 2 loops in Matlab but I am sure Mathematica should be able to handle this. I have the ODE $$F'(x)+\...
3
votes
1answer
70 views

Solving a system of coupled ODEs

I am trying to solve these 9 coupled ODEs ...
0
votes
0answers
28 views

NDSolve error when integrating two second order coupled ODEs

I want to plot a solution for a system of two second order coupled ODEs: ...
1
vote
1answer
49 views

Adjusting PrecisionGoal and AccuracyGoal when solving my equation using NDSolve?

Thanks for paying attention to my question and modifying my terrible formatting[facepalm], now I think I've found the answer. The point is the selection ...
2
votes
1answer
62 views

Plotting a two parameter function evaluated at a specific point

I am trying to solve the following problem: given the differential equation $$\frac{d^2y}{dx^2}+\bigg(a+b\frac{2}{\pi}\tan^{-1}x\bigg)y=0$$ subjected to two different initial condition we get two ...
0
votes
0answers
63 views

DSolve function is not working for Hypergeometric Function

I am trying to get the solution of second order differential equation, but it is not working. Any idea about it will help me a lot. ...
1
vote
1answer
42 views

Error message when trying to solve 2 coupled PDEs using NDSolve

I'm currently facing a problem when trying to solve 2 coupled PDEs. I get the warning messages: NDSolve::fembdcc: Cross-coupling of dependent variables in DirichletCondition[IPF==IPB/10,z==5.] is not ...
0
votes
0answers
21 views

NDSolve::ndnum: Encountered non-numerical value for a derivative at x == 0 [closed]

sol = NDSolve[{y''[x] == -(9.8/5)*sin[y[x]], y[0] == 25 Degree , y'[0] == 0}, y, {x, -10, 10}]
0
votes
0answers
37 views

Error while giving initial condition in NDSolve [closed]

I am trying to solve following differential equation $$\frac{d^2y}{dx^2}+(a+b \frac{2}{\pi}\tan^{-1} x)y=0$$ with the initial condition $y(-10)=e^{10i\sqrt{a+b}}$ and $y'(-10)=-i\sqrt{a+b}e^{10i\sqrt{...
5
votes
1answer
91 views

Nonlinear differential equation with unknown parameter and integral form boundary condition

I'm trying to solve numerically a non-linear problem in order to determine the velocity field ($U$) and the film thickness ($h$) of a non-Newtonian fluid over an inclined plane. The equations are, $$\...
3
votes
1answer
105 views

Why can't MMA solve this system of differential equations?

This system of differential equations can be solved in order to obtain the expression of x[t] y[t] z[t] ...
2
votes
1answer
54 views

Maximizing Output from ParametricNDSolve [closed]

Given a system of differential equations that are dependent on two parameters, such as the system below (the equation below is not that important, I am interested in a general procedure given a ...
1
vote
0answers
33 views

Unexpected stiff system error [closed]

Let there be the following functions ya[t_, x_] := Cosh[t*x] za[t_, x_] := Sinh[t*x] wa[t_, x_] := x*Sinh[t*x]^2 One can verify that the following PDE's hold <...
0
votes
0answers
44 views

Heat transport with Neumann bc in older Mathematica versions [duplicate]

Im trying to solve a simple heat transfer equation: $\partial_t T-\beta \partial_{xx}T=0$ for a finite system $x\epsilon <0;L>$ along with initial/boundary conditions: 1) $T(x,t)=0$ for $t<...
1
vote
1answer
66 views

“Fewer dependent variables than equations, so the system is overdetermined” without any BC's

Consider this system of PDEs. eqn1 = D[u[x, t], x] + 5 D[u[x, t], x, x] + D[v[t], t, t] - 4 == 0 eqn2 = D[v[t], t] + D[u[x, t], t, t] + v[t] == 0 I would like to ...
4
votes
1answer
99 views

Solving Laplace's equation in 2D using region primitives

I was looking at examples of solving problems in electromagnetism and ran across this question, which was a great example of just that. However, looking at the Dirichlet condition, both answers define ...
1
vote
1answer
41 views

NDSolve with Events that reevaluate with different Discrete Variables

I have the following problem: I have a set of ODEs and some discrete variables which I can solve successfully. Now I want mathematica to check at every $0.1 \,t$ time step, wether it would increase ...
0
votes
0answers
67 views

A system of linear differential equations with variable (time-dependent) coefficients

I have searched almost all similar pages discussing a system of differential equations, but none of them discussed the case of variable coefficients. My problem is a bit more complicated, because ...
1
vote
0answers
78 views

find ODE solutions and suitable initial conditions to get solution

DSolve[2.56 x''[t] == -0.32 x'[t] - x[t] - 0.05 x[t]^3 + 2.5 Sin[t], x[t], t] I want to find the solution and find two initial conditions such that their ...
-2
votes
2answers
80 views

Manipulate NDsolve 1D-reaction diffusion equation

I want to solve the following 1D-reaction diffusion equation: $$\frac{\partial}{\partial t}u(t,x)=\alpha\,\frac{\partial^{2}}{\partial x^{2}}u(t,x)+a\,u(t,x)$$ $$u(t,0)=0\,\,\,\,\,\text{et}\,\,\,\,\,u(...
0
votes
0answers
64 views

Fit a three-pulse sequence

I am wondering how to properly fit the three-pulse sequence shown below. I have tried a method which is fitting the three pulses with three polynominal functions seperately and then finding the x-...
0
votes
0answers
27 views

Using VariationalD on previously defined functions [closed]

Do you know whether there is a way to get around the following problem? Say we define a very simple function: f[t] = 2 y[t] and want to use the ...
1
vote
1answer
67 views

solving coupled differential equations

I am solving 6 differential equations in matrix form as: ...
3
votes
1answer
96 views

Solving Piecewise Differential Equation using NDSolve (coupling at BC)

I am having some issues in dealing with a system of differential equations. I would like to solve a 1D diffusive heat equation across several regions with different material properties. I now have a ...
1
vote
1answer
75 views

Solving Nonlinear Heat Equation with initial Conditions

I have the following setup for the linear heat equation on an infinite rod (see below). This is a pretty standard setup and the initial condition is $e^{-x^2}$. This initial condition is not special, ...
0
votes
0answers
76 views

Ways to decrease computational time

I have created a 2D axisymmetric simulation of the motion of charged particles in an electric field. The electric field is created by a needle attached to a top plate both of which are at -3800V with ...
0
votes
1answer
126 views

Solving a Reaction-diffusion system

I'm just a beginner in Mathematica software. I have version 12. I am looking for a program that will solve a prey-predator system with diffusion. My problem is that I tried a previously posted ...
3
votes
2answers
75 views

Extracting data from InterpolatingFunction 2D surface plot

I would like to directly extract the surface plot data from the solution to a differential equation (using NDSolve). While there are many examples of this I haven't been able to find an example in 2D. ...
0
votes
0answers
57 views

NDSolve with Functions Depending on time and time dependent Functions

EDIT: following the advice of using Raw Input Form, the equations have the following form ...
1
vote
0answers
51 views

Plotting PDE Solution With Changing Parameter

I have a Fokker-Plank equation I'm trying to solve the Fokker-Planck equation $$\frac{\partial p}{\partial L}(L, \eta)= \frac{1}{L_{loc}}\frac{\partial}{\partial \eta}\left[\left(\eta^{2}-1\right) \...
4
votes
1answer
116 views

How to get DAE representation from equations?

Update2: Thank you for all of your answers. I would like to clarify the question as I did a bit of research on DAE representations and their applications in software. There are 2 representations used ...
3
votes
1answer
239 views

2D Oseen equations

Background info: https://en.wikipedia.org/wiki/Oseen_equations ...
1
vote
1answer
68 views

Parametric plot of data from NDSolve

I have been trying to plot the solution of a set of differential equations solved used NDSolve. Now, in one of the cases, I have the find a parametric plot of the ...
5
votes
1answer
134 views

NDSolve::femcmsd: The spatial derivative order of the PDE may not exceed two

I was in the impression that V12 can now handle higher order PDES but for this particular case it fails to produce any solution. ...
0
votes
1answer
63 views

Plot a family of solutions of ODE with singularity

In the post Use Mathematica to plot the flow of an ODE with discontinuity, the following ODE with discontinuous coefficient was solved ...
0
votes
2answers
52 views

Delay in the beginning of solution for two ODEs

I have two couple ODEs and the second one has a delay in the time for starting. I mean, the first ODE starts at t=0 and the second one at t=20. How can I solve the second one in the correct time ...
2
votes
0answers
91 views

Model 1D Vlasov Equation

Vlasov Equation The non-relativistic form of the Vlasov equation is given by: $$ \partial_{t} f\left( \mathbf{x}, \mathbf{v}, t \right) + \mathbf{v} \cdot \nabla f\left( \mathbf{x}, \mathbf{v}, t \...
3
votes
1answer
86 views

Solution of convection dominated PDE with conditions only on the interior of the domain

I'm Trying to solve the following PDE: $$ \frac{1}{20}\left(2 x_1^2+x_2^2\right) -25\left( \begin{bmatrix} 0\\ \frac{6 \cos(x_1)}{-37 + 3 \cos(2 x_1)} \end{bmatrix}^\intercal \nabla_{x_1,x_2}V(x_1,...
0
votes
0answers
38 views

How to use Parallel computing on Manipulate option on ParametricNDSolveValue

My aim is to use Manipulate option on the ParametricNDSolveValue. When ever i run my code "Manipulate" option runs very slow and some time shows Aborted when check for that value of parameter it works ...
0
votes
0answers
56 views

how to solve the integral diffenertial equation with convolution? [closed]

several days ago i have put up the question as this and links are as this enter link description here and i have simplify the question and questions are as this my question is as this and i want ...