[WSG23] Daily Study Group: Solving ODEs and PDEs

A Wolfram U Daily Study Group on “Solving ODEs and PDEs” begins on Monday, August 8, 2023.

Join me and a cohort of fellow enthusiasts to learn about the techniques for solving ordinary differential equations (ODEs) and partial differential equations (PDEs) using Wolfram Language. Learn how to use the DSolve (for symbolic solutions) and the NDSolve (a general numerical differential equation solver) functions. Topics covered include the numerical method of lines, the finite element method (FEM), the use and construction of meshes, boundary value problems and eigenvalue problems.

Participate in live Q&A and review your understanding through interactive in-session polls. Complete quizzes at the end of the study group to get your certificate of program completion.

August 7-11, 2023, 11am-12pm CT (4-5pm GMT)

REGISTER HERE

Please feel free to use this thread to collaborate and share ideas, materials and links to other resources with fellow learners.

I look forward to seeing you online!

9 Likes

Thanks, @Luke Titus, for sharing your expertise at these upcoming Daily Study Group sessions!

3 Likes

This Daily Study Group offers a unique opportunity to learn about all aspects (symbolic, numerical, ODEs and PDEs) of differential equations in the Wolfram Language.

@Luke Titus is an outstanding instructor and has a deep understanding of this important area.

I strongly recommend the Study Group to everyone!

6 Likes

I am looking forward to attending the daily study group. I am currently a graduate student in Mathematics with a major in Applied Mathematics at the Hellenic Open University. Research interest in partial differential equations. You can see some of my projects in my profile here in the community.

1 Like

Hi..
I’m a complette outsider to this topic, but always interested in learning more about Wolfram Technologies and fields of application.
Thanks to the authors for putting this training together.
J!

I am Sehluko. I am looking forward to this study group.

Two classes so far, and I’m really finding the information useful. My thanks to Luke, Cassidy and Juan.

1 Like

Thank you for joining the study group. I hope your are finding this useful for your research.

2 Likes

Thank you for joining the study group. The content for this course is somewhat advance, but I hope that you are finding the topic of differential equations to be interesting.

Thanks for joining the study group.

Thank you very much for your comments and for joining the study group.

Thank you for sharing. It looks like that pet store is going to have a lot of rainbow fish!

1 Like

Thank you, Luke. Your presentation is very clear so far. Good job.

1 Like

I continued exploring the model for a while but at the end, I have a question as you will see. Could you explain to me why this is happening?

1 Like

Question:
Wolfram, in general, has, on various levels (math, software syntaxis, etc.) outstanding documentation. A Wolfram user goes through smooth calculations and attendant
great results. By most measures, a superior experience.

However, I would like to grow an appreciation for the “overload” brought about by increasing precision, for example.
Also, what are some of the complexities involved in attempting to get a plot right?
Where are these issues discussed?

Hi Athanasios. Thanks for sharing the notebook. There is a lot there so I may have missed something, but it appears to me that the growth rate is quite large. The results from DSolve have the term Exp[0.7*t] in them, which is going to make the population grow extremely fast. Considering just the birth rate, if you want there to be 0.7 births per year, I think what you want is the following

In[1]:= DSolve[{P'[t] == 0.7, P[0] == 30}, P[t], t] // Simplify
Out[1]= {{P[t] -> 30. + 0.7 t}} 
1 Like

I hope I was able to answer your question verbally during the class. The documentation link below talks about the maximum number that can be represented when doing arbitrary precision.

The documentation page for the various plotting functions, and the related tutorials found at the very bottom of the documentation page, are a good place to start when trying to get a plot to look the way you want it to.

2 Likes

In the second case, I have changed the
Growth rate : 0.7(1-\frac{P(t)}{750}).
Now I have used the NDSolve to solve the problem

eqn = {P'[t] == 0.7*(1 - P[t]/750)*P[t] - 20}
cond = {P[0] == 30}
sol = NDSolve[{eqn, cond}, P[t], {t, 0, 30}]

Then I calculated the equilibrium points

eqn = 0.7*(1 - P[t]/750)*P[t] - 20;
equilibriumPoints = Solve[eqn == 0, P[t]];  

And I have the following plot

p1 = Plot[P[t] /. sol, {t, 0, 20}, PlotStyle -> {Thick, Green}]

Now I am trying to solve with Euler’s Method:

sol1 = NDSolve[{P'[t] == 0.7*(1 - P[t]/750)*P[t] - 20, cond}, P[t], {t, 0, 20}, Method -> "ExplicitEuler", MaxSteps -> Infinity]
p2 = Plot[P[t] /. sol1, {t, 0, 30}, PlotStyle -> {Dashed, Red}]

And then I am trying to compare the two solutions

Show[p1, p2, PlotLabel -> "Comparison of Solutions"]

Here it is what I ask for an explanation.

I think it is because your second NDSolve call is only going out to 20, so the solution isn’t calculated past there. I’m getting the same result for both calculation:

eqn = {P'[t] == 0.7*(1 - P[t]/750)*P[t] - 20};
cond = {P[0] == 30};
sol = NDSolveValue[{eqn, cond}, P[t], {t, 0, 30}];
sol1 = NDSolveValue[{eqn, cond}, P[t], {t, 0, 30}, Method -> "ExplicitEuler", MaxSteps -> Infinity];
Plot[{sol, sol1}, {t, 0, 30}, PlotStyle -> {{Red}, {Dashed, Green}}]
1 Like