(*^
::[ Information =
"This is a Mathematica Notebook file. It contains ASCII text, and can be
transferred by email, ftp, or other text-file transfer utility. It should
be read or edited using a copy of Mathematica or MathReader. If you
received this as email, use your mail application or copy/paste to save
everything from the line containing (*^ down to the line containing ^*)
into a plain text file. On some systems you may have to give the file a
name ending with ".ma" to allow Mathematica to recognize it as a Notebook.
The line below identifies what version of Mathematica created this file,
but it can be opened using any other version as well.";
FrontEndVersion = "Macintosh Mathematica Notebook Front End Version 2.2";
MacintoshStandardFontEncoding;
fontset = title, inactive, noPageBreakBelow, nohscroll, preserveAspect, cellOutline, groupLikeTitle, center, M18, O486, R65535, e8, 24, "Calculus";
fontset = subtitle, inactive, noPageBreakBelow, nohscroll, preserveAspect, groupLikeTitle, center, M18, O486, bold, R21845, G21845, B21845, e6, 12, "Calculus";
fontset = subsubtitle, inactive, noPageBreakBelow, nohscroll, preserveAspect, groupLikeTitle, center, M18, O486, R21845, G21845, B21845, e6, 10, "Calculus";
fontset = section, inactive, noPageBreakBelow, nohscroll, preserveAspect, groupLikeSection, grayBox, M18, O486, bold, R21845, G21845, B21845, a10, 12, "Calculus";
fontset = subsection, inactive, noPageBreakBelow, nohscroll, preserveAspect, groupLikeSection, blackBox, M18, O486, bold, R21845, G21845, B21845, a10, 12, "Calculus";
fontset = subsubsection, inactive, noPageBreakBelow, nohscroll, preserveAspect, groupLikeSection, whiteBox, M18, O486, bold, R21845, G21845, B21845, a10, 12, "Calculus";
fontset = text, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M18, O486, 12, "Calculus";
fontset = smalltext, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M18, O486, B65535, 12, "Calculus";
fontset = input, noPageBreakInGroup, nowordwrap, preserveAspect, groupLikeInput, M36, N23, O486, bold, L-5, 12, "Courier";
fontset = output, output, inactive, noPageBreakInGroup, nowordwrap, preserveAspect, groupLikeOutput, M36, N23, O486, L-5, 12, "Courier";
fontset = message, inactive, noPageBreakInGroup, nowordwrap, preserveAspect, groupLikeOutput, M18, N23, O486, R65535, L-5, 12, "Courier";
fontset = print, inactive, noPageBreakInGroup, nowordwrap, preserveAspect, groupLikeOutput, M18, N23, O486, L-5, 12, "Courier";
fontset = info, inactive, noPageBreakInGroup, nowordwrap, preserveAspect, groupLikeOutput, M18, N23, O486, B65535, L-5, 12, "Courier";
fontset = postscript, PostScript, formatAsPostScript, output, inactive, noPageBreakInGroup, nowordwrap, preserveAspect, groupLikeGraphics, M18, O486, l34, w351, h314, 12, "Courier";
fontset = name, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M18, O486, italic, 10, "Geneva";
fontset = header, inactive, noKeepOnOnePage, preserveAspect, M18, O486, 12, "Times";
fontset = leftheader, inactive, M18, O486, L2, 12, "Times";
fontset = footer, inactive, noKeepOnOnePage, preserveAspect, center, M18, O486, 12, "Times";
fontset = leftfooter, inactive, M18, O486, L2, 12, "Times";
fontset = help, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M18, O486, 10, "Times";
fontset = clipboard, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M18, O486, 12, "Times";
fontset = completions, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M18, O486, 12, "Times";
fontset = special1, inactive, nohscroll, noKeepOnOnePage, preserveAspect, whiteBox, M18, O486, bold, R21845, G21845, B21845, 12, "CalcMath";
fontset = special2, inactive, nohscroll, noKeepOnOnePage, preserveAspect, center, M18, O486, R21845, G21845, B21845, 12, "CalcMath";
fontset = special3, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M18, O486, 12, "Times";
fontset = special4, inactive, nohscroll, noKeepOnOnePage, preserveAspect, center, M18, O486, 10, "Courier";
fontset = special5, inactive, nohscroll, noKeepOnOnePage, preserveAspect, M18, O486, 10, "Courier";
paletteColors = 256; automaticGrouping; currentKernel;
]
:[font = title; inactive; preserveAspect; fontName = "CalcMath"; startGroup]
Working Within the Parameters
:[font = subtitle; inactive; preserveAspect]
Graphing through the use of parameters
:[font = subsubtitle; inactive; preserveAspect; fontSize = 12]
by Jim Mann, Sheldon H.S.
:[font = subsubsection; inactive; initialization; Cclosed; preserveAspect; center; fontSize = 9; startGroup]
Mathematica 2.1 initializations
:[font = input; initialization; preserveAspect; endGroup]
*)
Off[General::spell1];
Off[Plot::plnr];
Needs["Graphics`Colors`"];
(*
:[font = section; inactive; Cclosed; preserveAspect; startGroup]
Note to instructors
:[font = text; inactive; preserveAspect; endGroup]
Personally, the use of parameters is one of the subjects that I do not emphasize enough. I know that I expect my students to deal with this subject when they are enrolled in my Physics course, however, parameters are not often covered in my Math courses. Hence, I intend to use this notebook to help bridge the gap.
:[font = section; inactive; Cclosed; preserveAspect; startGroup]
Introduction
:[font = smalltext; inactive; preserveAspect]
In most of our previous experiences, we have considered two different types of variables, independent and dependent variables. For example, when considering y=mx+b, we originally graphed it by putting in values of x (independent variable), and finding values of y (dependent variable).
;[s]
5:0,0;95,1;106,0;111,1;120,0;292,-1;
2:3,26,19,Calculus,0,12,0,0,65535;2,26,19,Calculus,1,12,0,0,0;
:[font = smalltext; inactive; preserveAspect]
Another method of graphing is by using a third variable, called a parameter. We will now make the x and y-coordinates into functions of this third variable (t, for lack of a better choice).
;[s]
3:0,0;71,1;80,0;196,-1;
2:2,26,19,Calculus,0,12,0,0,65535;1,26,19,Calculus,1,12,0,0,0;
:[font = smalltext; inactive; preserveAspect]
When we use this parameter, t becomes the independent variable. The functions x = x[t] and y = y[t] define x and y as being dependent on t. Different points are located by varying the value of t.
:[font = smalltext; inactive; preserveAspect; endGroup]
Now that we have the basic idea of what parameters are, let's look at some examples of how graphs we know and love can be put in terms of parameters.
:[font = section; inactive; Cclosed; preserveAspect; startGroup]
Graphing a Line Using Parameters
:[font = smalltext; inactive; preserveAspect]
While it is easier to simply view the graphing of a line in the way that we have done it previously, we will graph lines using a parameter. This will enable you to get a better idea of how to change over to functions of this outside variable.
:[font = smalltext; inactive; preserveAspect]
Enabling us to concentrate on the properties of the functions and graphs through the use of Mathematica will first require a definition of the plot function.
;[s]
3:0,0;95,1;107,0;161,-1;
2:2,26,19,Calculus,0,12,0,0,65535;1,26,19,Calculus,2,12,0,0,65535;
:[font = input; preserveAspect]
Clear[par,x,y,mi,ma]
par[x_,y_,mi_,ma_]:=ParametricPlot[{x,y},{t,mi,ma},
AspectRatio->Automatic,
PlotStyle->{Blue,
Thickness[0.005]},
AxesOrigin->{0,0}];
:[font = smalltext; inactive; preserveAspect]
Now, just what does this whole mess boil down to????
;[s]
5:0,0;52,3;53,2;54,1;55,0;56,-1;
4:2,26,19,Calculus,0,12,0,0,65535;1,45,32,Calculus,0,24,0,0,65535;1,38,27,Calculus,0,20,0,0,65535;1,36,26,Calculus,0,18,0,0,65535;
:[font = smalltext; inactive; preserveAspect]
This is a function for Mathematica which gives it the means which to plot using parametric functions as we will define them.
;[s]
3:0,0;26,1;37,0;129,-1;
2:2,26,19,Calculus,0,12,0,0,65535;1,26,19,Calculus,2,12,0,0,65535;
:[font = input; preserveAspect]
par[x_,y_,mi_,ma_] this is our plot function, working on four
variables:
x_ this is our function x[t]
y_ this is our function y[t]
mi_ minimum value for t
ma_ maximum value for t
The basics of parameters, and the Mathematica functions are
in place, so let's look at the graphs of some lines.
;[s]
13:0,0;18,1;19,2;111,0;115,2;160,0;162,2;209,0;212,2;252,0;255,2;312,3;323,2;394,-1;
4:5,7,10,Courier,1,12,0,0,0;1,18,16,CalcMath,0,12,0,0,0;6,18,16,CalcMath,0,12,0,0,65535;1,18,16,CalcMath,2,12,0,0,65535;
:[font = subsection; inactive; preserveAspect; startGroup]
Examples of Lines
:[font = smalltext; inactive; preserveAspect]
First, let's look at the graph of y=x from x = -2 to 2. We want x and y equal to each other, so let's set them equal to the same thing, t.
x[t] = t
y[t] = t
Therefore, our instruction to Mathematica is:
;[s]
5:0,0;164,2;202,0;233,1;244,0;249,-1;
3:3,26,19,Calculus,0,12,0,0,65535;1,26,19,Calculus,2,12,0,0,65535;1,26,19,Calculus,1,12,0,0,0;
:[font = input; preserveAspect; startGroup]
par[t,t,-2,2];
:[font = postscript; PICT; formatAsPICT; output; inactive; preserveAspect; pictureLeft = 34; pictureWidth = 314; pictureHeight = 314; endGroup; pictureID = 18002]
:[font = smalltext; inactive; preserveAspect]
A valid question would be: How do we graph a line of slope not equal to 1 using parameters (i.e. y=mx)?
:[font = subsubsection; inactive; preserveAspect; startGroup]
Think carefully before uncovering this answer
:[font = smalltext; inactive; preserveAspect]
If you said that the slope should be in front of the x function, just as in y=mx, well..... that's not correct. Think about the meaning of a line having slope m. For each unit that we change "x", there should be a change of m units in "y". Consequently, we should put the coefficient with y[t]. How about some examples:
x[t] = t
y[t] = 2t
;[s]
4:0,0;229,1;230,0;342,1;376,-1;
2:2,26,19,Calculus,0,12,0,0,65535;2,26,19,Calculus,1,12,0,0,0;
:[font = input; preserveAspect; startGroup]
par[t,2t,-2,2];
:[font = postscript; PICT; formatAsPICT; output; inactive; preserveAspect; pictureLeft = 34; pictureWidth = 157; pictureHeight = 314; endGroup; pictureID = 14109]
:[font = smalltext; inactive; preserveAspect]
Yep, that gives us a slope of 2, but what if we put the coefficient with x[t]. Think about the answer before you activate the function.
:[font = input; preserveAspect; startGroup]
par[2t,t,-2,2];
:[font = postscript; PICT; formatAsPICT; output; inactive; preserveAspect; pictureLeft = 34; pictureWidth = 351; pictureHeight = 175; endGroup; pictureID = 15954]
:[font = smalltext; inactive; preserveAspect; endGroup]
After looking at this graph, it should be obvious as to why the coefficient is with y[t]. At this point take some time to graph some other lines.
:[font = subsubsection; inactive; Cclosed; preserveAspect; startGroup]
What about y-intercepts?
:[font = smalltext; inactive; preserveAspect]
After working with y=mx, our next step is to work with y=mx+b. Again, the question is: to affect the y-intercept, should we put the value with x[t] or y[t]?
:[font = smalltext; inactive; preserveAspect]
To answer, we need to consider what we want out of a y-intercept in terms of the graph.
:[font = smalltext; inactive; preserveAspect]
The y-intercept is the value of y when x=0, or it is the number of units that we add after finding mx in y=mx+b. From the parametric point of view, it would be the number of units that we would add after finding mt, which indicates that the y-intercept should be part of y[t].
:[font = smalltext; inactive; preserveAspect]
Therfore, when we consider both slope and y-intercept, our two functions will look like:
x[t] = t
y[t] = mt + b (m=slope,b=y-intercept)
Let's look at some examples:
First, y=3x-2, from -3 to 3
x[t] = t
y[t] = 3t - 2
;[s]
5:0,0;109,1;110,2;148,0;255,2;295,-1;
3:2,26,19,Calculus,0,12,0,0,65535;1,26,19,Calculus,1,12,0,0,65535;2,26,19,Calculus,1,12,0,0,0;
:[font = input; preserveAspect; startGroup]
par[t,3t-2,-2,2];
:[font = postscript; PICT; formatAsPICT; output; inactive; preserveAspect; pictureLeft = 34; pictureWidth = 104; pictureHeight = 314; endGroup; pictureID = 11189]
:[font = smalltext; inactive; preserveAspect; endGroup; endGroup; endGroup]
Sure enough, we get a slope of 3, and a y-int of -2. You should graph some functions of your own, considering combinations of slopes and y-intercepts with both postitive and negative values.
:[font = section; inactive; Cclosed; preserveAspect; startGroup]
Parabolas
:[font = subsection; inactive; Cclosed; preserveAspect; startGroup]
Looking at Parabolas and Parameters
:[font = smalltext; inactive; preserveAspect]
In graphing parabolas using parametric equations, we will again be forced to consider (think about) what we want out of our x and y coordinates. All of which is working toward graphing any parabola in standard form [(y-k)=4p(x-h)Û or (x-h)=4p(y-k)Û] using parametric equations.
:[font = smalltext; inactive; preserveAspect]
Let's start with a simple parabola y = xÛ. In building the parametric equations, look at a specific example: if the x-cooordinate were 2, the y-coordinate would be 2Û (or 4). Consequently, as functions of t they should look like:
x[t] = t
y[t] = tÛ
;[s]
2:0,0;246,1;276,-1;
2:1,26,19,Calculus,0,12,0,0,65535;1,26,19,Calculus,1,12,0,0,0;
:[font = input; preserveAspect]
par[t,t^2,-2,2];
:[font = smalltext; inactive; preserveAspect]
What if we wanted to graph x = yÛ?
:[font = subsubsection; inactive; Cclosed; preserveAspect; startGroup]
Think before you open this answer
:[font = smalltext; inactive; preserveAspect]
For this graph, we need to reverse the roles of x and y. Therefore, we need to exchange the functions to get the desired parabola:
x[t] = tÛ
y[t] = t
;[s]
2:0,0;147,1;176,-1;
2:1,26,19,Calculus,0,12,0,0,65535;1,26,19,Calculus,1,12,0,0,0;
:[font = input; preserveAspect]
par[t^2,t,-2,2];
:[font = smalltext; inactive; preserveAspect; endGroup; endGroup]
Again, by carefully considering our parametric equations, we were able to obtain the correct graph.
:[font = subsection; inactive; Cclosed; preserveAspect; startGroup]
Making changes in the Parabola
:[font = smalltext; inactive; preserveAspect]
Once we have these two "basic" parabolic equations, we can make three types of changes to the graph: 1) change the coordinates of the vertex (h,k), 2) change the width of the parabola (adjust 4p), and 3) change the direction by multiplying by -1.
:[font = subsubsection; inactive; Cclosed; preserveAspect; startGroup]
Changing the vertex
:[font = smalltext; inactive; preserveAspect; endGroup]
In the parabolas that were previously graphed in this section, we located the vertex at (0,0). Now, we want to change the values of h and k to "move" the vertex.
Let's take the example y=(x-1)Û: Remember that tÛ should be in y[t]. The remaining important question would be: which function should the 1 be with? How do we structure the parametric functions to make this so?
:[font = subsubsection; inactive; Cclosed; preserveAspect; startGroup]
Answer and graph 1
:[font = smalltext; inactive; preserveAspect]
The equations should be set up as:
:[font = smalltext; inactive; preserveAspect; plain; bold; fontColorBlue = 0]
x[t] = t+1
y[t] = tÛ
:[font = smalltext; inactive; preserveAspect]
One rationale would be to consider that when y[t]=0 (hence, t=0), we want x[t]=1 (t+1).
:[font = smalltext; inactive; preserveAspect]
Let's see if it works:
:[font = input; preserveAspect]
par[t+1,t^2,-2,2];
:[font = smalltext; inactive; preserveAspect; endGroup]
Great!! Now, how would we get the graph of the parabola with the equation (x+3)=(y-2)Û. Experiment with different functions for x[t] and y[t] to graph it correctly.
:[font = subsubsection; inactive; Cclosed; preserveAspect; startGroup]
Answer and graph 2
:[font = smalltext; inactive; preserveAspect]
If we learned a lesson from Problem 1, it should have been that we put the value of h with x[t], and the value k with y[t]. The trick here is that we need to square t before subtracting 3. (Also, remember this parabola is in the form x=yÛ).
x[t] = tÛ-3
y[t] = t+2
;[s]
2:0,0;259,1;290,-1;
2:1,26,19,Calculus,0,12,0,0,65535;1,26,19,Calculus,1,12,0,0,0;
:[font = input; preserveAspect; endGroup]
par[(t)^2-3,t+2,-3,3];
:[font = subsubsection; inactive; Cclosed; preserveAspect; startGroup]
Changing the width of the Parabola
:[font = smalltext; inactive; preserveAspect]
In the standard equation of a parabola, the width of the parabola is determined by the value of 4p. By adjusting this value, we can make the parabola wider or narrower. Once again, the challenge is to change the functions x[t] and y[t].
:[font = smalltext; inactive; preserveAspect; endGroup]
What would be the parametric functions that would correspond to the parabola y=2xÛ?
:[font = subsubsection; inactive; Cclosed; preserveAspect; startGroup]
Answer and graph
:[font = smalltext; inactive; preserveAspect]
This parabola is narrow, in that we want the value of y to increase twice as much as it would in y=xÛ. Therefore, our functions should look as such:
x[t] = t
y[t] = 2tÛ
;[s]
2:0,0;170,1;205,-1;
2:1,26,19,Calculus,0,12,0,0,65535;1,26,19,Calculus,1,12,0,0,0;
:[font = input; preserveAspect]
par[t,2t^2,-2,2];
:[font = smalltext; inactive; preserveAspect; endGroup]
Multiplying y by a coefficient (greater than 1) gives us a "narrow" parabola. What should we do to get a "wide" parabola?
;[s]
3:0,0;17,1;18,0;128,-1;
2:2,26,19,Calculus,0,12,0,0,65535;1,26,19,Calculus,1,12,0,0,0;
:[font = subsubsection; inactive; Cclosed; preserveAspect; startGroup]
Answer and graph 2
:[font = smalltext; inactive; preserveAspect]
There are two approches we could take to accomplish this goal. One, would be to multiply x by a coefficient greater that one. The other, would be to multiply y by a coefficient less than one. Either will work efficetively. Here is an example done by the first method. Experiment on your own using both methods.
;[s]
5:0,0;95,1;96,0;165,1;166,0;324,-1;
2:3,26,19,Calculus,0,12,0,0,65535;2,26,19,Calculus,1,12,0,0,0;
:[font = input; preserveAspect; endGroup]
par[2t,t^2,2,-2];
:[font = subsubsection; inactive; Cclosed; preserveAspect; startGroup]
Changing the direction of the parabola
:[font = smalltext; inactive; preserveAspect]
Thus far, we have only worked with parabolas that open in the positive direction. In terms of our parametric funcitons, how would we make changes to get a parabola that opens in the negative direction.
:[font = smalltext; inactive; preserveAspect]
The question is whether to put the negative with the squared function. The answer is yes, because we want to square the value first, then multiply by the negative. Consequently, the parabola x=-yÛ would be:
x[t] = -tÛ
y[t] = t
;[s]
2:0,0;229,1;265,-1;
2:1,26,19,Calculus,0,12,0,0,65535;1,26,19,Calculus,1,12,0,0,0;
:[font = input; preserveAspect]
par[-t^2,t,-2,2];
:[font = smalltext; inactive; preserveAspect]
The same idea would work when attempting to get a parabola that opens down.
:[font = input; preserveAspect; endGroup]
par[t,-t^2,-2,2];
:[font = subsubsection; inactive; Cclosed; preserveAspect; startGroup]
Putting it all together
:[font = smalltext; inactive; preserveAspect]
For our final parabolic trick, we will now put together all three of the changes we have discussed into one graph. Let's graph (y-2)=-3(x+3)Û. The parametric funcitons will be:
x[t] = t - 3
y[t] = -tÛ + 2
;[s]
2:0,0;193,1;232,-1;
2:1,26,19,Calculus,0,12,0,0,65535;1,26,19,Calculus,1,12,0,0,0;
:[font = input; preserveAspect]
par[t-3,-3t^2+2,-1,1];
:[font = smalltext; inactive; preserveAspect; endGroup; endGroup; endGroup]
This gives us the desired direction, width, and vertex location. You should now experiment on your own to see if you can create the appropriate functions to graph what you desire.
:[font = section; inactive; Cclosed; preserveAspect; startGroup]
Circles
:[font = smalltext; inactive; preserveAspect]
One of the more familiar uses of parameters you may have previously seen, is the graphing of circles. The standard form of the equation of a circle is (x-h)Û+(y-k)Û=rÛ, where (h,k) is the coordinates of the center of the circle. In terms of parameters, we can look at a circle in this manner:
x[t] = Cos[t]
y[t] = Sin[t], t= [0, 2 Pi]
;[s]
3:0,0;315,1;357,0;373,-1;
2:2,26,19,Calculus,0,12,0,0,65535;1,26,19,Calculus,1,12,0,0,0;
:[font = input; preserveAspect]
par[Cos[t],Sin[t],0,2 Pi];
:[font = subsection; inactive; Cclosed; preserveAspect; startGroup]
Changes in the graph of a circle
:[font = smalltext; inactive; preserveAspect]
We will consider two types of changes in the graph of a circle. First, are changes in the radius of a circle. Second, are changes in the location of the center.
:[font = subsubsection; inactive; Cclosed; preserveAspect; startGroup]
Changing the radius
:[font = smalltext; inactive; preserveAspect; endGroup]
As before, we need to decide what needs to be done in order to change the radius of the circle. We know that at t=0, the value of Cos[t] is 1, and the value of Sin[t] is 0. Consequently, at t=0 we have the point (1,0). Let's say we want a radius of 3, can we get a value of Cos[t] that is 3?
:[font = subsubsection; inactive; Cclosed; preserveAspect; startGroup]
Answer
:[font = smalltext; inactive; preserveAspect]
Get real! We know that Cosine has a range of [-1,1]. The way to get a radius of 3 is to first take the trig function, then multiply by 3:
x[t] = 3 Cos[t]
y[t] = 3 Sin[t]
:[font = input; preserveAspect]
par[3 Cos[t],3 Sin[t],0,2 Pi];
:[font = smalltext; inactive; preserveAspect; endGroup]
Work with other circles on your own. (Question: what would happen if you put negative coefficients with the Sin and Cos functions?)
:[font = subsubsection; inactive; Cclosed; preserveAspect; startGroup]
Changing the center of the circle
:[font = smalltext; inactive; preserveAspect; endGroup]
If you remember how to move the vertex of a parabola, changing the center of a circle should be a piece of cake. Use the same line of reasoning. Think about what you want to do to the Cos or Sin function to change the coordinates. With this in mind, write the parametric functions for a circle of radius 1 with its center at (1,-2).
:[font = subsubsection; inactive; Cclosed; preserveAspect; startGroup]
Answer
:[font = smalltext; inactive; preserveAspect]
In standard form, this would look like (x-1)Û+(y+2)Û=1. The parametric functions would be:
x[t] = Cos[t] + 1
y[t] = Sin[t] - 2
;[s]
2:0,0;112,1;163,-1;
2:1,26,19,Calculus,0,12,0,0,65535;1,26,19,Calculus,1,12,0,0,0;
:[font = input; preserveAspect]
par[Cos[t]+1,Sin[t]-2,0,2 Pi];
:[font = smalltext; inactive; preserveAspect; endGroup; endGroup; endGroup]
Choose some values for the radius, and coordinates for the center. After doing this, create the parametric funcitons for these values. Adjust the functions until you get the graph to match these values.
:[font = section; inactive; Cclosed; preserveAspect; startGroup]
Ellipses
:[font = smalltext; inactive; preserveAspect]
After developing the parametric functions for a circle, it becomes an easy step to create the graph of an ellipse. To do this, we need only to have a different coefficient with each of the trig functions. An example is:
x[t] = 2 Cos[t]
y[t] = 3 Sin[t]
;[s]
2:0,0;242,1;289,-1;
2:1,26,19,Calculus,0,12,0,0,65535;1,26,19,Calculus,1,12,0,0,0;
:[font = input; preserveAspect]
par[2 Cos[t], 3 Sin[t],0,2 Pi];
:[font = smalltext; inactive; preserveAspect]
This gives us an ellipse with major axis = 6 (3 X 2),and minor axis = 4 (2 X 2). Play with the fucntions, changing the coefficients to get ellipses with different shapes. The only qualification is that the two coefficients must be different. What would happen if the two coefficients were the same?
:[font = subsection; inactive; Cclosed; preserveAspect; startGroup]
Moving the center of the ellipse
:[font = smalltext; inactive; preserveAspect]
In changing the coordinates of the center of the ellipse, we can again use the example of the circle. Therefore, how would define the parametric functions for an ellipse whose center is at (1,2), major axis = 4, and minor axis = 2?
:[font = subsubsection; inactive; Cclosed; preserveAspect; startGroup]
Answer
:[font = smalltext; inactive; preserveAspect]
The functions should be defined as:
x[t] = Cos[t] + 1
y[t] = 2 Cos[t] + 2
:[font = input; preserveAspect]
par[Cos[t]+1,2 Sin[t]+2,0,2 Pi];
:[font = smalltext; inactive; preserveAspect; endGroup; endGroup; endGroup]
The question of another solution to this problem may arise. The answer is that there is another solution to this problem because it was not specified whether the major axis should be parllel to the x-axis or the y-axis.
Again, using different centers, and different measures for the major and minor axes, see if you can make the ellipse into any dimensions you choose.
:[font = section; inactive; Cclosed; preserveAspect; startGroup]
Converting funcitons from polar coordinates to parameters
:[font = smalltext; inactive; preserveAspect]
Any function that is written for polar coordinates can be converted to rectangular coordinates (hence, parametric functions) using the following:
x[t] = r Cos[t]
y[t] = r Sin[t]
;[s]
2:0,0;166,1;213,-1;
2:1,26,19,Calculus,0,12,0,0,65535;1,26,19,Calculus,1,12,0,0,0;
:[font = subsection; inactive; Cclosed; preserveAspect; startGroup]
The cardioid
:[font = smalltext; inactive; preserveAspect]
One example of a cardioid is given by r=1+Sin[t]. We can define this function, and use the information from above to complete our parametric functions.
:[font = input; preserveAspect]
r=1+Sin[t];
par[r Cos[t],r Sin[t],0,2 Pi];
:[font = smalltext; inactive; preserveAspect; endGroup]
This looks like an upside-down heart. What would you need to do to make the "heart" look correct.
:[font = subsection; inactive; Cclosed; preserveAspect; startGroup]
Roses
:[font = smalltext; inactive; preserveAspect]
Roses are created when there is a polar equation where r=Cos[qt] or Sin[qt]. The number of leaves in the rose is determined by the value of q. After running the two examples below, experiment with several of your own (all you need to do is change the value of q). Then see if you can find the relationship between q and the number of leaves.
:[font = smalltext; inactive; preserveAspect; fontColorRed = 65535; fontColorBlue = 0]
3-leaved rose
:[font = input; preserveAspect]
par[Cos[t] Sin[3t],Sin[t] Sin[3t],0,2 Pi];
:[font = smalltext; inactive; preserveAspect; fontColorRed = 65535; fontColorBlue = 0]
4-leaved rose
:[font = input; preserveAspect; endGroup; endGroup; endGroup]
par[Cos[t] Sin[2t],Sin[t] Sin[2t],0,2 Pi];
^*)