Preface
This is a tutorial made solely for the purpose of education and it was designed for students taking Applied Math 0330. It is primarily for students who have very little experience or have never used Mathematica before and would like to learn more of the basics for this computer algebra system. As a friendly reminder, don't forget to clear variables in use and/or the kernel.
Finally, the commands in this tutorial are all written in bold black font, while Mathematica output is in regular fonts. This means that you can copy and paste all comamnds into Mathematica, change the parameters and run them. You, as the user, are free to use the scripts to your needs for learning how to use the Mathematica program, and have the right to distribute this tutorial and refer to this tutorial as long as this tutorial is accredited appropriately.
Return to computing page for the second course APMA0340
Return to Mathematica tutorial for the second course APMA0330
Return to Mathematica tutorial for the first course APMA0340
Return to the main page for the course APMA0340
Return to the main page for the course APMA0330
Return to Part II of the course APMA0330
Orthogonal Trajectories
Example. (Orthogonal trajectories) Given the family of curves x*y=c, where c is a constant. These are hyperbolas in quadrants 1 and 3 for c>0 or quadrants 2 and 4 for c<0, having the axes as asymptotes. They are rectengular hyperbolas because their asymptotes are perpendicular. The differential equation of the family is x y' + y =0, or dy/dx = -y/x . The orthogonality condition says that the equation of the orthogonal curves should be - dx/dy = -y/x or dy/dx = y/x . The latter has the general solution (after separation of variables): y^2 = x^2 +c. Now we plot these curves.
x y == -1, x y == -0.2, x y == -0.5, x y == -1.5}, {x, -2, 2}, {y, -2, 2}]
x^2 == y^2 - 1, x^2 == y^2 - 0.1, x^2 == y^2 - 1.9}, {x, -2, 2}, {y, -2, 2}]

Example 2.11.2.
The differential equation Exp[y] dy = Sin[x] dx defines its
family of solutions: Exp[y] == Sin {x] +c .
The orthiogonal trajectories are ln | Tan[x/2] = Exp[y] +c.
Exp[y] + Cos[x] == 2, Exp[y] + Cos[x] == 0.5,
Cos[x] + Exp[y] == 1.5, Cos[x] + Exp[ y] == -2,
Cos[x] + Exp[y] == -0.2, Cos[x] + Exp[ y] == -0.5,
Cos[x] + Exp[y] == -1.5}, {x, -2, 2}, {y, -2, 2}]
Log[Tan[x]] == Exp[-y] + 0.1, Log[Tan[x]] == Exp[-y] + 0.9,
Log[Tan[x]] == Exp[-y] - 1, x Log[Tan[x]] == Exp[-y] - 0.1,
Log[Tan[x]] == Exp[-y] - 3.9}, {x, -2, 2}, {y, -2, 2}]
First Order ODEs
Plotting Solutions to ODEs
Direction Fields
Separable Equations
Equations Reducible to the Separable Equations
Equations with Linear Fractions
Exact Equations
Integrating Factors
Linear Equations
RC circuits
Bernoulli Equations
Riccati Equations
Existence and Uniqueness
Qualitative Analysis
Bifurcations
Orthogonal Trajectories
Population Models
Applications
Return to Mathematica page
Return to the main page (APMA0330)
Return to the Part 1 (Plotting)
Return to the Part 2 (First Order ODEs)
Return to the Part 3 (Numerical Methods)
Return to the Part 4 (Second and Higher Order ODEs)
Return to the Part 5 (Series and Recurrences)
Return to the Part 6 (Laplace Transform)