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

learn more… | top users | synonyms (3)

1
vote
1answer
60 views

DSolve - Complex Number Solutions

some of you know that I have been working on my dissertation of Game-Theoretic Modelling of Cybersecurity (Thank you again to everyone who has helped me with Mathematica so far). The differential ...
0
votes
1answer
53 views

Problem with solving an optimal control system with Shooting Method

I try to solve a system of differential equation by shooting method. I looked at questions asked on the site but I could not find that could help me. My functions are ; ...
4
votes
1answer
211 views

Solving the Frenet Serret equations for non-constant curvature and torsion, obtaining parametric equations

I wish to solve for the curvature and torsion functions $k_1 = \dfrac{1}{1+s^2}, k_2 = \dfrac{s}{1+s^2}$ using the Frenet Serret system and obtain the parametric equations for the curve. I need the ...
-1
votes
0answers
21 views

When we solve PDEs by the method of lines in NDSolve, can we control the temporal steps?

A method of NDSolve for solving time-dependent PDEs is the method of lines. According to its documentation, we have some control about the spatial grid, as in the ...
0
votes
0answers
93 views

Phase space of a system of differential equation [on hold]

I have a system of three Coupled nonlinear equation of a physical system and i would like to plot the phase space. My system is a chaotic system dependant of three variable dependant of time (l1, ...
3
votes
0answers
47 views

WhenEvent and Resetting of Variable in PDE when operation succeeds

I have had success in using WhenEvent to reset or change a variable within NDSolve with ordinary differential equations. My ...
0
votes
0answers
21 views

NDSolve::ivar error when trying to solve DE [on hold]

I am getting this error: NSolve::ivar: 0 is not a valid variable, when attempting to solve the following problem. ...
8
votes
1answer
63 views

Working Precision in nonlinear control systems

When simulating a nonlinear control system using StateResponse , do the options WorkingPrecision, ...
1
vote
1answer
97 views

How to handle a special Neumann-like boundary condition in NDSolve?

How to solve the following nonlinear ODE with two algebraic equations and one boundary condition? ...
2
votes
2answers
77 views

Reaction-diffusion PDE with NDSolve: either very slow or very inaccurate

I am struggling to have Mathematica 10.3 solve a system of PDE's (with periodic boundary conditions and random initial conditions), but either it produces a set of very noisy InterpolatingFunction ...
3
votes
1answer
91 views

NDSolve for optimal control theory

For an optimal control problem, I need to solve a differential equation in which (a) the system is formulated according to a function and (b) initial/terminal conditions are discontinuous. Here is an ...
1
vote
0answers
89 views

NDSolve: Indeterminate expression 0. ComplexInfinity encountered?

The following code give errors that I don't understand. Could you please suggest a method to solve these differential equations? ...
2
votes
1answer
153 views

Simple code to write differential equations in a matrix formulation

Is there a simple code to transform the following differential system equations : ...
2
votes
0answers
101 views

Schrödinger equation for Hydrogen atom

I'm trying to solve Schrödinger 1D equation for hydrogen atom but I found several difficulties. To get in context I want to solve this equation For Z and l real and arbitraries. To start with I ...
9
votes
0answers
86 views

Differential equations with rational functions as solution

I have some families of nonlinear, first order differential equations. When I try to use DSolve, I usually get a mess (if anything at all) in terms of ...
0
votes
0answers
50 views

NDSolve: problem due to boundary conditions

I am trying to solve a 2nd order ordinary linear differential equation (DE==0). Here is the code: ...
1
vote
1answer
58 views

Partial differential equation with infinity limit

How do I get Mathematica to solve the following partial differential equation $$ \frac{\partial u(y,t)}{\partial t} = \nu \frac{\partial^2 u(y,t)}{\partial y^2}+\frac{\partial U_0(t)}{\partial t}$$ ...
2
votes
1answer
72 views

Solve and plot differential equation

I want to solve this differential equation $\qquad y'(x)=\frac{x-y(x)}{1-y(x)-x}$ and plot it's solution. But DSolve doesn's work. ...
17
votes
4answers
2k views

How do I solve a PDE with a strange boundary condition?

How do I solve the PDE with boundary value like this $$u(t,x,y)=0, \textrm{when } F(x,y)=0$$ using DSolve? As a specific example, I want to solve heat equation $$\frac{\partial u}{\partial ...
0
votes
0answers
33 views

System of ODE's in NDSolve [on hold]

To begin with, I understand that this is quite a common question, with a lot of documentation from Wolfram and answered questions on this stackexchange. I have been looking over them, I really have, ...
1
vote
1answer
56 views

To find a limit cycle with period 1 in NDSolve

I am trying to find a limit cycle with period 1 of an ode system. The idea is to compare the values of the system during two periods, for example, ...
0
votes
1answer
48 views

Multiple stopping constraints in NDSolve

I need to numerically solve several differential equations, with several constraints, like this : ...
1
vote
1answer
58 views

Differential Equations and Unit Notation

What do I get the Syntax::sntxi: Incomplete expression; more input is needed . error when I try to use the math palette for derivatives? What does the dot in 10. Farad Micro Volt mean? ...
12
votes
1answer
373 views

How to numerically solve a 1-d time-independent Schrodinger equation?

The point is to solve the eigensystem of the given Hamiltonian. I tried ParametricNDSolve combined with FindRoot to search for ...
0
votes
1answer
76 views

How to solve the following GR PDE?

Someone could help me for solving the following GR PDE? (this code do not work yet) ...
-1
votes
0answers
33 views

Boundary Conditions that depend on each other [on hold]

I have to numerically solve some 4th order differential equations: B''''(r)=f(r,B,B',B'',B''',S,S'), S''(r)=g(r,B,B',S,S') I'm trying to use the shooting method ...
2
votes
1answer
171 views

Strange WhenEvent Behavior

Bug introduced in 10.3 or earlier and persisting through 10.3.1 or later Given: ...
2
votes
0answers
57 views

NDeigensystem returns error due to mesh discretization when calculating vibrations of a cantilever

There was an transcription error in the code I provided in a previous post: NDeigensystem returns complex non-hermitian error for the calculation of vibrations of a cantilever This resulted in it ...
1
vote
1answer
93 views

NDSolve memory usage

I am trying to solve numerically a system of linear ODEs with some quickly varying driving functions. The basic command is: ...
2
votes
1answer
67 views

How to solve two ODE differential equations, numerically, with four dependent boundary condition

I have two ODE differential equations(DE) and four dependent B.C. $$y_1''(x)=-\frac{1}{2} \left(x-y_1(x)\right)$$ $$y_2''(y)=-\frac{1}{4} \left(y-y_2(y)-5\right)$$ $$y_1(0)=y_2(1)$$ $$y_1(1)=y_2(0)$$ ...
3
votes
1answer
375 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 ...
0
votes
0answers
56 views

How to define an exclusion zone for NDSolve

I need to numerically integrate a differential equation and define two exclusion zones to stop the integration. The Mathematica code looks like this : ...
11
votes
3answers
470 views

Using NDSolve to find particle trajectory

I'm trying to simulate a particle in an electric and magnetic fields, but numerically instead of analytically. This is basically solving the equation $$q \cdot \left(p'\times B\right) + q\cdot E = m ...
1
vote
1answer
70 views

Estimating error in NDSolve

I would like to give a theoretical estimation of local truncation error (and then for the global one) for a solution to a numerical initial value problem by ...
-2
votes
0answers
53 views

NDeigensystem returns complex non-hermitian error for the calculation of vibrations of a cantilever [duplicate]

We are trying to use NDEigensystem to solve for the vibration of a cantilever with a triangular cross-section. The relevant PDE is $\mu \nabla^2 \vec u + (\lambda + \mu) \nabla(\nabla \cdot \vec u) = ...
3
votes
0answers
50 views

Weird behaviour for a vector InterpolatingFunction inside an NDSolve

I have run into some weird behaviour on the part of NDSolve which I find pretty bizarre and which I would like to understand better. Suppose, for the sake of ...
4
votes
1answer
87 views

System of equations is solved by NDSolve over just a tiny domain

I'm solving numerically a system of differential equations with the use of NDSolve. The numerical integration works only a very small interval of the argument. I'm ...
0
votes
0answers
53 views

Fourier-style solutions to differential equations, not piecewise polynomials

NDSolve returns piecewise polynomials. Is there any way I can get a single (non piecewise) function consisting of sines and cosines instead? Sort of a "Fourier approximation" to the solution of my ...
2
votes
1answer
110 views

solving coupled differential equations with parameters subject to optimization problem

I have an equation, but I don’t know how to program it in Mathematica: x[0]==1; y[0]==1; x'[t]==(a+b) x[t] y[t]; y'[t]==a b y[t]/x[t]; where ...
1
vote
1answer
375 views

Numerical solutions of Gross-Pitaevskii equation [closed]

I am trying to solve the Gross-Pitaevskii equation numerically and using NDSolve, but this seems to be a dead end. The problem is boundary and initial conditions ...
4
votes
0answers
50 views

Numerical instabilities of a convection-(non-)diffusion equation when shrinking from a square to a triangular domain

I am trying to evaluate a parameter-dependent indefinite integral using a PDE-based scheme I described here, and I'm having some trouble when I try and cut down the domain from a square to a triangle. ...
4
votes
1answer
70 views

How can I numerically pre-compute an indefinite integral with a parameter?

Suppose I have a function $f(t)$, and I want to compute its indefinite integral $$F(t)=\int_0^tf(\tau)\mathrm d\tau.$$ Moreover, suppose that, for any of a number of reasons, I require this integral ...
1
vote
1answer
32 views

Issue plotting PDE solution with manipulate

I am trying to plot the solution to the following PDE with the help of mathematica, however, when trying to employ manipulate to animate the behavior, I find that if I try this: ...
0
votes
0answers
55 views

Implicit differentiation dx/dt?

I am trying to find $\frac{\partial t}{ \partial y}$ as a function of $x$, $y$ and $\frac{\partial t}{\partial x}$ if both $x$ and $y$ depend on $t$ for the function ...
3
votes
1answer
62 views

Split Boundary Value Problems win Algebraic Equations

Is it possible at all to solve with NDSolve (or other built in function) a split boundary value problem with algebraic equations? Please look at the following example: ...
1
vote
1answer
94 views

Differential equation in two variables

I have a system of second order differential equations, with two independent variables, which represents a trajectory. I tried solving this system using NDSolve and ...
0
votes
0answers
19 views

Solving a simple ODE [duplicate]

I am trying to solve $y(x)' = \sqrt{y(x)}$ with initial condition $y(0)=0$ for $x\in \mathbb{R}$. I have tried this: DSolve[{y'[x] == Sqrt[y[x]], y[0] == 0}, y[x], x] but this gives {{y[x] -> ...
3
votes
2answers
240 views

Rotating an Interpolating Function

I have used the following code to generate eigenfunctions of a PDE: ...
42
votes
2answers
1k views

Numerically solving Helmholtz equation in 3D for arbitrary shapes

Context While studying manifold Learning I got interested in finding the eigenvectors of the Laplacian. (also in connection to this problem of solving the heat equation) Following this and that ...