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

learn more… | top users | synonyms (3)

0
votes
2answers
103 views
0
votes
0answers
64 views

How to solve the heat flow PDE for the constant source term

I have the two dimensional heat flow equation solved for a two dimensional reagion over time. That is an instance I found in the internet. What I am looking for is a method how to determine the heat ...
0
votes
1answer
103 views

How to make the plot smooth

There are some stranges point which cause the figure isn't smooth. I think that the reason is the method of numericial integration. Here is my code, it's pleasure that one can revise the drawbacks in ...
0
votes
0answers
47 views

Piecewise NDSolveValue: Nested Variable Iteration

I am attempting to make the variable Rc a piecewise-function of [z] and have it update as NDsolve iterates through the range of 'z' such as {z,0,Le), but to no avail. The following code is an attempt ...
2
votes
1answer
59 views

Simplifying the result of DSolve

I have a system of differential equations that can be solved with DSolve. However, the coefficients are very long there are like terms which can be combined. I used //FullSimplify in my code but the ...
-1
votes
1answer
116 views

Problem with NDSolve and If

If T=T1, program can calculate. But, when T = T1*If[Abs[q2[t] - q2d] < e1 && Abs[q2'[t]] < e1, 0, 1], program can ...
0
votes
1answer
30 views

Using NDSolve initial conditions as parameters for a function and then a replacement rule

I am trying to make a function based on two initial conditions of a set of differential equations: ...
4
votes
1answer
253 views

Using ParametricNDSolve and NMinimize to find accurate interplanetary trajectory arrival periapse radius

I have an interplanetary trajectory simulation that calculates the required velocity (using a Lambert solver) and escape angle for a spacecraft to travel from Earth to Mars. This model does not use a ...
0
votes
0answers
81 views

How to remove error at large time in NDSolve

I am working with solutions of a linearly damped wave equation. In the following code I use a "transparent" boundary condition at the end, which allows waves to pass through the specified boundary so ...
6
votes
1answer
81 views

“ParametricSensitivity” in ParametricNDSolve

"ParametricSensitivity" is listed as a Method in the documentation for ParametricNDSolve, ...
0
votes
0answers
34 views

How to plot multiple numeric ODE solutions in phase space

I have a system of four coupled ODEs whose solution (and solution process) are sensitive to the value of a parameter $a$. $$\bar X '(t)=\bar F(\bar X, t, a)$$ If possible, I would like to create a ...
0
votes
0answers
76 views

Calculating 15 coupled differential equations

I have 15 coupled differential equations linear in time that need to be solved. Rewriting the equations in a matrix form, they can be expressed following as a single equation, $\frac{d ...
0
votes
0answers
38 views

Error with ND Solve

I am new to Mathematica, and I am having some issues solving a homework problem of a differential equation. Here is the code: ...
-2
votes
0answers
37 views

How to assign values to constants inserted in a solution by DSolve

I am trying to solve first order ODE with DSolve, but it didn't pan out. How can I solve for the inserted variable K[1]? Your ...
1
vote
0answers
45 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 ...
2
votes
0answers
360 views

Solving two-component two-dimensional differential Equation with NDSolve (Brusselator Model)

I'm trying to solve a two-component two-dimensional reaction-diffusion differential equation system with Mathematica. The background of the model is the so called "Brusselator Model" where one can ...
2
votes
0answers
32 views

Solving a differential equation with a complex (independent) varible

I'm trying to plug in complex values in the numerical solutions of ODEs without success. For instance y[I] /. NDSolve[{y'[x] == 0, y[0] == 3}, y, {x, -10, 10}] ...
0
votes
1answer
91 views

Nonlinear differential equation: numerical solution

I have to find and plot a numerical solution for this second order differential equation: u''[x] + (u'[x]/x) - (u[x]/(x^2)) + u[x] - u[x]^3 = 0 where 0 <= x ...
0
votes
1answer
58 views

DSolve Error 3D Navier Stokes (z,r,t)

I am essentially wanting to solve Navier Stokes in the [z,r,t] dimensions (2D+Unsteady Flow) for pressure driven flow. However, I keep getting an error I am unable to resolve in my Dsolve such as: ...
1
vote
2answers
62 views

Condition on Inside of Region

How do I handle boundary conditions present in the region. Mathematica complains about the condition v [1 , t ] == u [1,t]. The condition should be given to this ...
1
vote
1answer
92 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 ...
1
vote
1answer
54 views

How do I restrict the range of an interpolating function in NDSolve?

I have a numerical solution for a differential equation. I know that the gray dotted solution is unphysical. Is there a way I can tell mathematica to ignore the gray dotted solution (e.g. restrict the ...
8
votes
1answer
179 views

SymplecticPartitionedRungeKutta shows strange error

Bug introduced in 9.0 or earlier and persisting through 10.2 or later I tried to solve Hamiltonian system ($Q$ is a vector of all generalized coordinates, $P$ - of generalized momentum) $$ ...
0
votes
1answer
68 views

How to solve time dependent coupled differential equations? [closed]

I am trying to solve time dependent coupled differential equations with know initial conditions. I am just a beginner in terms of coding so would really appreciate if someone can give me an example of ...
1
vote
1answer
96 views

How can I use NDSolve with a variable parameter?

I'm a new user and I can't understand how to solve this function for variable values of vr (for example vr from 0 to 5 in steps ...
3
votes
0answers
705 views

Solving a diffusion equation

I need to solve a particular diffusion equation with NO boundaries (see eqn. (2.10) in: Ann. Rev. Astron. Astrophys. 19:137-62 (1981).) with nu = cost. ...
1
vote
1answer
42 views

Getting the message NDSolve::underdet:

I am solving the wave equation with initial position and velocity function: ...
0
votes
1answer
59 views

NDSolve does not satisfy initial conditions

For the problem I'm facing, I have three coupled diff eqns that I'm trying to solve ...
0
votes
1answer
80 views

Improving NDSolve computation speed for 3D stationary PDE

Continuing my last question, I am trying to solve 3D Schrodinger equation (with mass equals to 1) and with no potential (I will add a potential later). The analytical solution for this equation is ...
0
votes
2answers
80 views

How to solve a pair of coupled 2nd order equations using shooting method

I have a pair of equations for x[t] and y[t]. Both are 2nd order and they are coupled. Now say that I know the following ...
0
votes
2answers
125 views

NDSolve issue with initial and boundary conditions

While solving the heat equation in one spatial variable $u_t = u_{xx} $ (x goes from 0 to L) with the initial temperature distribution $T_0 \frac{x(L-x)}{L^2}$ , and with neumann boundary conditions ...
0
votes
0answers
131 views

Boundary value problem: complicated functionals

I am trying to solve a non-linear boundary value problem where the differential equation is a convoluted function of the variable I am trying to solve for. The equation below presents the final form ...
2
votes
1answer
100 views

Equal flow boundary conditions

I'm having the following issue that can not find a solution , by using this boundary condition v[0, t] == u[1, t] that Mathematica does not understand, someone ...
0
votes
0answers
33 views

Boundary condition [duplicate]

I'm having the following issue that can not find a solution , by using this boundary condition v[0, t] == u[1, t] that Mathematica does not understand, someone ...
7
votes
2answers
115 views

Extending NDSolve beyond a singularity

The $\tan$ function satisfies the following IVP: $$y'=1+y^2 ,\quad y(0)=0 $$ and has simple poles at the points $x=\pi/2+ \pi n$ for integer $n$. When trying to get $\tan$ via numerical ...
4
votes
4answers
191 views

How should I deal with messages being produced by my Manipulate?

I have made a knockoff of John Polking's dfield for a web-embedded CDF (via Enterprise Mathematica). My code extends that from Belisarius who last year showed me how to use ...
0
votes
1answer
99 views

How to speed up NonlinearModelFit applied on a NDSolve solution?

I'm trying to perform fittings of a model defined through a system of ODEs to data consisting of time courses of a measured quantity. As described in a previous question, the system of ODEs is as ...
5
votes
2answers
446 views

NDSolve: ProcessEquations and Reinitialize with Piecewise functions

I am having trouble with using NDSolve`Reinitialize when the system consists of a piecewise function. If we define the ODE system ...
10
votes
3answers
621 views

Only final result from NDSolve

Finally, I started to play with differential equations in Mathematica. And I have faced the problem, which seems to me so basic that I'm afraid this question is going to be closed soon. However, ...
0
votes
2answers
96 views

Convert DE to first order?

I have the following set of second-order differential equations: ...
4
votes
2answers
245 views

NMinimize Constraints on Interpolating Functions

I have the following piece of code and am trying to use NMinimize (the last line in the following chunk of code) to minimize ...
0
votes
1answer
56 views

Problems with solving two coupled lorenz equation with NDsolve

I have a system of two coupled lorenz equations and I'm to integrate it: ...
8
votes
1answer
155 views

Using a Mathematica index as a DiscreteVariable in NDSolve when solving a coupled set of ordinary differential equations

Context Since the explanation below of the problem to be solved is lengthy, let me preamble this by saying that I have code that works to solve the problem, but I don't know whether (1) it's ...
5
votes
2answers
94 views

How do I programatically set up an NDSolve with lots of equations?

I'd like to set up... NDSolve[x1'[t]==2,x1[0]==0, x2'[t]==2,x2[0]==0, x3'[t]==2,x3[0]==0, x4'[t]==2,x4[0]==0, x5'[t]==2,x5[0]==0, ... etc Can I somehow use ...
6
votes
1answer
235 views

Second order differential equation with boundary conditions solving repeatedly

I want to solve a second order differential equation in the interval[-1:1], which does not have a analytic solution, \begin{eqnarray} y''(x) &=& k \phi^2(x)y(x) \\ \phi(x) &=& ...
7
votes
1answer
446 views

Modeling neural excitation with a non-linear differential equation

I think I have a special problem and I am not sure how to search for an answer, so I thought I would try here. I am working with the so called FitzHugh-Nagumo model which describes very simple ...
8
votes
0answers
2k views

Integro-differential equation [closed]

I have to numerically solve a nonlinear partial integro-differential equation using Mathematica. This is my equation, $$\frac{\partial y(x,t)}{\partial t}=\int_{-\infty}^\infty K_0(|x-u|) ...
1
vote
1answer
109 views

non linear Least Squares with model function given by ODE's

I have to fit to experimental data a model function given by a linear combination of functions y1(t) and y2(t) a1*y1(t) + a2*y2(t) with a1 and a2 ...
2
votes
1answer
202 views

How can I invoke the solution of NDSolve to determine a parameter in my equation just inside NDSlove?

I am trying to solve a differential equation by NDSlove for $h(x,t)$. It reads $$h_t=h_{xx}-V_h-\lambda(t)$$ where $V_h$ is a given function of $h(x,t)$ denoted by ...