Math 210 Assignment 6
Due: Friday, February 15, 2013
The homework comes in two parts, A & B. Each part will be graded
out of ten points.
Part A answers are to be written by hand and submitted to the instructor during the Friday lecture.
Part B is to be
Math 210 Assignment 1
Due: Friday, January 11, 2013
The homework comes in two parts, A & B. Each part will be graded
out of ten points.
Part A answers are to be written by hand and submitted to the instructor during the Friday lecture.
Part B is to be
Solving Differential Equations Numerically in Maple
O restart;
Let's remind ourselves of how to solve DEs analytically with Maple.
We are still remaining in the scalar, autonomous DE case.
O de1 d diff u t , t = u t
2
;
de1 :=
d
u t =u t
dt
2
(1)
(1)
O ic
Lesson 2: Variables, Assignment and Equations
Maple has extensive graphics capabilities. Here's a graph of a function.
plot(x^2 - 3*x - 4, x = -2 . 5);
6
4
2
0
1
2
3
x
A 3-dimensional graph:
plot3d(x^2 - y^2, x = -2 . 2, y = -2 . 2);
4
5
An animation:
plo
Finding Roots of Vector Systems
Doing one Vector Newton Step
Eigenanalysis
O restart
Let's consider roots of the following system
O f d x2 $y5 K x5 $y2 C exp x$y K 1 ;
f := x2 y5 K x5 y2 C ex y K 1
(1)
(1)
O g d x$y3 C x2 $y2 C x3 $y K 3;
g := x y3 C x2 y
Investigating Iterative Maps in Maple
and an introduction to Maple procedures
O restart;
Simple example of an iterative map, considered on [0,1]
O g d x/x2 ;
g := x/x2
(1)
Graph it along with the line y=x
O with plots :
O Curves d plot x, g x , x = 0 .1,
Lesson 8: Iteration: cycles and basins
restart;
@ and $
The @ that we used for iterating a function can also be used for higher derivatives in the D style.
Just as ([email protected])(x) is g(g(g(x), ([email protected])(f) is D(D(D(f), i.e. the third derivative of the
function f. Fo
Lesson 6: Iteration
> restart;
Iteration
Newton's method is a particular case of an iteration method. In general, iteration deals with a
sequence defined by
for some function . The study of iterations, also called discrete
dynamical systems, is a very act
Lesson 9: Basins of attraction
Since the Plot component turned out not to be completely reliable (at least on my computer), here's
another attempt using an animation that should be more reliable.
restart;
with(plots):
stair:= x -> ([x,x],[x,g(x)]);
stairc
Maple and Math Courses
Here are examples of some typical problems from some 200 and 300 level Math courses
at UBC, and how Maple might be used to help solve them.
Math 200
Let D be the region inside the polar curve
following integral:
and above the x axis
Lesson 11: Systems and resultants
restart;
Real solutions of a system
We were looking at the system of equations
p1 := 2*x^4 - 2*y^3 + y ;
p2 := 2 * x^2 * y + 3*y^4 -
, where
2*x ;
(1.1)
(1.1)
We had found all the solutions using solve.
S:= solve([p1 = 0,
Lesson 7: Iteration and Stability
restart;
with(plots):
Iteration
We were looking at the logistic map, with various values of the parameter .
g:= x -> r*(x - x^2);
(1.1)
(1.1)
r:= 2.5;
(1.2)
Iteration starts out with a particular value
sequence
and repeat
Lesson 12: More Systems
restart;
A geometry problem
Here's a nice little application of resultants to a geometrical problem. We're given two concentric
circles with radii and . From a given point P at a distance from the centre of the circles, we
want to
Lesson 10: Polynomials
restart;
Factoring polynomials
The Fundamental Theorem of Algebra says that a polynomial of degree n in one variable x (with
coefficients that are complex numbers) can be written as
where the complex numbers
are the roots
of the pol
Lesson 14: Domain of attraction
restart;
with(VectorCalculus,Jacobian):
with(plots):
How close is "close enough"?
If you start Newton's method at a point close enough to a solution, it should converge rapidly to that
solution. But how close? We were looki
Lesson 5: Newton's method
restart;
Newton's method
Newton's method is a method of approximately solving an equation, say
. We start with
an initial guess , and Newton's method produces a sequence of numbers , , . that converges
very rapidly to a solution
Maple Commands to Solve Differential Equations
Solving the logistic equation
O logistic d diff u t , t = u t $ 1 K u t ;
d
logistic :=
u t =u t
dt
1Ku t
(1)
O dsolve logistic, u t ;
ut =
1
t
1 C eK _C1
In the expression above, _C1 is an arbitrary constant
More Maple Commands - II
First, a few things from last time.
O f d x6 C 5;
f := x6 C 5
(1)
(1)
Notation for higher derivatives of expressions
O diff f, x$2 ;
30 x4
(2)
(2)
Taylor series
O taylor exp x , x = 1, 2 ;
eC e x K 1 C O
xK1
In the lecture, we wil
Math 210, Spring 2010
Computer Lab #5 Solutions
O restart
Q #1
Standard dsolve using the numeric option
O de d diff u t , t = exp sin u t ;
de :=
d
u t = esin
dt
ut
(1)
O ic d u 0 = 1;
ic := u 0 = 1
(2)
(2)
Save the result for use in #3
O numsol d dsolve
Math 210 Computer Lab #6
Tuesday, February 26, 2013
This is a test environment. Do not send e-mail while doing the lab.
You may consult any internet sites, your notes and books and access
any online help les.
Do all four questions below in a maple work
Math 210 Computer Lab #7
Tuesday, March 5, 2013
This is a test environment. Do not send e-mail while doing the lab.
You may consult any internet sites, your notes and books and access
any online help les.
Do all four questions below in a maple workshee
Math 210 Computer Lab #8
Tuesday, March 12, 2013
This is a test environment. Do not send e-mail while doing the lab.
You may consult any internet sites, your notes and books and access
any online help les.
Submit the MATLAB .m les requested in the two
Math 210 Computer Lab #9
Tuesday, March 19, 2013
This is a test environment. Do not send e-mail while doing the lab.
You may consult any internet sites, your notes and books and access
any online help les.
Submit the MATLAB .m les requested in the thre
Math 210 Computer Lab #11
Tuesday, April 2, 2013
This is a test environment. Do not send e-mail while doing the lab.
You may consult any internet sites, your notes and books and access
any online help les.
Submit the MATLAB .m les requested in the two
Math 210, Spring 2013
Computer Lab Quiz #6 Solutions
Q#1
Enter the equations and then solve.
Note that a matrix vector specification of the problem can also be done
O eq1 d s C t C u C v = 1;
eq1 := s C t C u C v = 1
(1)
(1)
O eq2 d s C 2$ t C 3$ u C v =
Math 210, Spring 2013
Computer Lab Quiz #7
Q#1
This is pretty standard - enter f and g, find the Jacobian matrix, do the eigenanalysis of the matrix.
O f d 2$x K y C 3$ x2 K y2 C 2$x$y;
f := 2 x K y C 3 x2 K 3 y2 C 2 x y
(1)
(1)
O g d x K 3$y C 3$ x2 K y2
Introduction to Maple
Maple is a very powerful Computer Algebra system that can do many of the calculations that you might
encounter in many branches of mathematics, science and engineering. We'll look at some of its
capabilities.
We're looking at a Maple
Math 210 Computer Lab #10
Tuesday, March 26, 2013
This is a test environment. Do not send e-mail while doing the lab.
You may consult any internet sites, your notes and books and access
any online help les.
Submit the MATLAB .m les requested in the thr
Roots of Functions, Differentiation and Plotting: Part II
Bisection Method, first look
Bisection method to find the square root of 2, with a=1 and b=2 bracketing the root
O a d 1;
a := 1
(1)
O b d 2;
b := 2
(2)
3
2
(3)
(3)
Compute the midpoint of the inte