(************** Content-type: application/mathematica ************** CreatedBy='Mathematica 5.0' Mathematica-Compatible Notebook This notebook can be used with any Mathematica-compatible application, such as Mathematica, MathReader or Publicon. The data for the notebook starts with the line containing stars above. To get the notebook into a Mathematica-compatible application, do one of the following: * Save the data starting with the line of stars above into a file with a name ending in .nb, then open the file inside the application; * Copy the data starting with the line of stars above to the clipboard, then use the Paste menu command inside the application. Data for notebooks contains only printable 7-bit ASCII and can be sent directly in email or through ftp in text mode. Newlines can be CR, LF or CRLF (Unix, Macintosh or MS-DOS style). NOTE: If you modify the data for this notebook not in a Mathematica- compatible application, you must delete the line below containing the word CacheID, otherwise Mathematica-compatible applications may try to use invalid cache data. For more information on notebooks and Mathematica-compatible applications, contact Wolfram Research: web: http://www.wolfram.com email: info@wolfram.com phone: +1-217-398-0700 (U.S.) Notebook reader applications are available free of charge from Wolfram Research. *******************************************************************) (*CacheID: 232*) (*NotebookFileLineBreakTest NotebookFileLineBreakTest*) (*NotebookOptionsPosition[ 49677, 1378]*) (*NotebookOutlinePosition[ 51143, 1433]*) (* CellTagsIndexPosition[ 50956, 1422]*) (*WindowFrame->Normal*) Notebook[{ Cell["Rain Catchers", "Title", PageWidth->PaperWidth], Cell[TextData[StyleBox["Chapter 4, Sections 4 through 6", FontFamily->"Arial", FontWeight->"Bold"]], "Text", PageWidth->PaperWidth, FontSize->16], Cell[BoxData[{ \(\(<< Graphics`Arrow`;\)\), "\n", \(\(<< Graphics`FilledPlot`;\)\), "\n", \(\(Off[DiracDelta::"\"];\)\), "\[IndentingNewLine]", \(\(Off[General::spell];\)\), "\[IndentingNewLine]", \(\(Off[General::spell1];\)\), "\n", \(\(Off[NIntegrate::ploss];\)\), "\n", \(\(Off[NIntegrate::ncvb];\)\), "\[IndentingNewLine]", \(\(Off[FindRoot::"\"];\)\), "\[IndentingNewLine]", \(\(\(Off[NIntegrate::"\"];\)\(\n\) \)\)}], "Input", Editable->False, CellOpen->False, InitializationCell->True], Cell[BoxData[{ \(\(Clear[antidifferentiate];\)\), "\n", \(\(antidifferentiate[fnc_, tind_, to_, tf_, fncic_] := Module[{f, t}, \n rules = {DiracDelta[q_] \[Rule] 0, DiracDelta[t - q_] \[Rule] 0, DiracDelta[q_ - t] \[Rule] 0, DiracDelta[t + q_] \[Rule] 0, DiracDelta[q_ + t] \[Rule] 0, DiracDelta[0. ] \[Rule] 0, \(DiracDelta\^\[Prime]\)[q_] \[Rule] 0, \(DiracDelta\^\[Prime]\)[t - q_] \[Rule] 0, \(DiracDelta\^\[Prime]\)[q_ - t] \[Rule] 0, \(DiracDelta\^\[Prime]\)[t + q_] \[Rule] 0, \(DiracDelta\^\[Prime]\)[q_ + t] \[Rule] 0, \(DiracDelta\^\[Prime]\)[0. ] \[Rule] 0}; \[IndentingNewLine]periodic = 0; \[IndentingNewLine]f[t_] = \((fnc /. tind -> t)\) /. rules; \n\t\t (*Fint[t_] := NIntegrate[f[s], {s, to, t}]; \n\t\tcint = fncic - Fint[to]; \n\t\tF[t_] := Fint[t] + cint;*) \[IndentingNewLine]\n F[t_] = \(DSolve[{\(y'\)[t] == f[t], y[to] == fncic}, y[t], t]\)[\([1, 1, 2]\)]; \n\nfpp[t_] = D[f[t], t] /. rules; \n fppvalues = Table[fpp[t], {t, to, tf, \((tf - to)\)/5000}]; \t\t\n fvalues = Table[f[t], {t, to, tf, \((tf - to)\)/5000}]; \n Fvalues = Table[F[t], {t, to, tf, \((tf - to)\)/5000}]; \n Fmax = Max[Fvalues]; \nFmin = Min[Fvalues]; \n\n fmaxt = Max[fvalues]; \nfmint = Min[fvalues]; \nfmin = fmint; \n fmax = fmaxt; \n\nstart = {}; roots = {}; \n Do[If[Sign[fvalues[\([k]\)]] \[NotEqual] Sign[fvalues[\([k + 1]\)]], roots = Append[roots, to + \((tf - to)\)/5000. *\((k - 1)\)]], {k, 1, 5000}]; \n\t\n\t\n\t\n\t\t\n steprat = 0.050; \n\t\thrange = If[Fmax < 0, {1.1*Fmin, 0}, If[Fmin > 0, {0, 1.1*Fmax}, {1.1*Fmin, 1.1*Fmax}]]; \n\t\tfrange = If[fmax < 0, {1.1*fmin, 0}, If[fmin > 0, {0, 1.1*fmax}, {1.1*fmin, 1.1*fmax}]]; \nta = 0; size = 8; \n\t (*\t p2 = Plot[f[t], {t, to, tf}, PlotRange -> {{to, tf}, frange}, ImageSize -> {72*size, 72*size/2}, AspectRatio -> 1/2, PlotStyle -> {RGBColor[0, 0, 0], Thickness[0.008]}, AxesLabel \[Rule] {"\", "\"}, Epilog -> {Thickness[0.010], RGBColor[0, 0, 0], Arrow[{to, 0}, {to, f[to]}], Text[\*"\"\<\!\(dQ\/dt\)\>\"", {to, f[to]/2}, {\(-1\), 0}]}, DisplayFunction -> Identity]; p1 = Plot[F[t], {t, to - 0.00001*\((tf - to)\), to}, PlotRange -> {{to - 0.01*\((tf - to)\), tf + 0.01*\((tf - to)\)}, hrange}, ImageSize -> {72*size, 72*size/2}, AspectRatio -> 1/2, PlotStyle -> {RGBColor[0.246098, \ 0.671885, \ 0.199222]}, AxesOrigin -> {0, 0}, AxesLabel \[Rule] {"\", "\"}, Epilog -> {RGBColor[0.246098, \ 0.671885, \ 0.199222], Thickness[0.010], Text[\*"\"\<\!\(Q\_0\)\>\"", {to - 0.01*\((tf - to)\), 0.5*F[to]}, {1, 0}], Arrow[{to - 0.01*\((tf - to)\), 0}, {to - 0.01*\((tf - to)\), F[to]}, HeadScaling -> Automatic]}, DisplayFunction -> Identity]; \n\t\tShow[ GraphicsArray[{p2, p1}], ImageSize -> {72*size, 72*size/4}, AspectRatio \[Rule] 1/4, PlotRegion -> {{0, 1}, {0, 1}}, \ DisplayFunction -> $DisplayFunction];*) \n\n If[Length[roots] != 0, \t\t\n If[Abs[roots[\([Length[roots]]\)] - tf] <= 0.00001*Max[Abs[{Fmax, Fmin}]], \n roots = Append[roots, tf + 0.00001*\((tf - to)\)], roots = Append[roots, tf]; roots = Append[roots, tf + 0.00001*\((tf - to)\)]]; \n If[Abs[roots[\([1]\)] - to] <= 0.00001*Max[Abs[{Fmax, Fmin}]], \n roots = Prepend[roots, to - 0.00001*\((tf - to)\)], roots = Prepend[roots, to]; roots = Prepend[roots, to - 0.00001*\((tf - to)\)]];, roots = Append[roots, tf]; roots = Append[roots, tf + 0.00001*\((tf - to)\)]; \n\t\t\troots = Prepend[roots, to]; roots = Prepend[roots, to - 0.00001*\((tf - to)\)]]; \n\n n = Length[roots]; \n\t\troots = Sort[roots // N]; \n\t\tFor[k = 1, k < Length[roots] - 1, \(k++\), If[roots[\([k]\)] == roots[\([k + 1]\)], roots = Delete[roots, k]]]; \n\t\tk = 1; \n\t\tWhile[ k <= Length[roots], If[roots[\([k]\)] < \((to - 0.00001*\((tf - to)\))\) || roots[\([k]\)] > \((tf + 0.00001*\((tf - to)\))\), roots = Delete[roots, k], \(k++\)]]; \t\n\ \ \n\t\t\n Do[Clear[p1, p2]; \n\t\n\tlim = 1; \n\t While[ta > roots[\([lim + 2]\)], \ lim = lim + 1]; \n\t\t\t\t\n\t\t\t\t\tp1t = Plot[F[t], {t, to, If[ta == roots[\([lim + 1]\)], ta - \((tf - to)\)/5000, ta]}, PlotRange -> {{to - 0.01*\((tf - to)\), tf + 0.01*\((tf - to)\)}, hrange}, AspectRatio -> 1/2, PlotStyle -> {RGBColor[0.246098, \ 0.671885, \ 0.199222], Dashing[{}]}, ImageSize -> {72*size, 72*size/2}, PlotRegion -> {{0, 1}, {0, 1}}, \ AxesLabel \[Rule] {"\", "\"}, DisplayFunction -> Identity, Prolog -> Flatten[{RGBColor[0.246098, \ 0.671885, \ 0.199222], Text["\", {ta, 0.5*F[ta]}, {\(-1\), 0}], Thickness[0.010], Arrow[{ta, 0}, {ta, F[ta]}, HeadScaling -> Automatic], Text[\*"\"\<\!\(Q\_0\)\>\"", {to - 0.01*\((tf - to)\), 0.5*F[to]}, {1, 0}], Arrow[{to - 0.01*\((tf - to)\), 0}, {to - 0.01*\((tf - to)\), F[to]}, HeadScaling -> Automatic], Thickness[0.015], Table[{If[f[roots[\([k]\)] + \((tf - to)\)/5000] > 0, RGBColor[1, 0, 0], RGBColor[0, 0, 1]], Arrow[{roots[\([k]\)], F[roots[\([k]\)]]}, {roots[\([k]\)], F[roots[\([k + 1]\)]]}, HeadScaling -> Automatic], RGBColor[0, 0, 0], Thickness[0.003], Dashing[{0.01, 0.02}], Line[{{roots[\([k]\)], F[roots[\([k + 1]\)]]}, {roots[\([k + 1]\)], F[roots[\([k + 1]\)]]}}]}, {k, 1, lim}], If[f[ta - \((tf - to)\)/5000] > 0, RGBColor[1, 0, 0], RGBColor[0, 0, 1]], Arrow[{roots[\([lim + 1]\)], F[roots[\([lim + 1]\)]]}, {roots[\([lim + 1]\)], F[ta]}, HeadScaling -> Automatic], Thickness[0.003], RGBColor[0, 0, 0], Dashing[{0.01, 0.02}], Line[{{roots[\([lim + 1]\)], F[ta]}, {ta, F[ta]}}], Dashing[{}]}, 1]]; \n\t\t\t\n\t\t\t\n\t\t\tp1 = Show[p1t, ImageSize -> {72*size, 72*size/2}, PlotRegion -> {{0, 1}, {0, 1}}, AxesFront -> True, DisplayFunction -> Identity, AspectRatio \[Rule] 1/2]; \n\t\t\t\t\t\t\n\t p2t = {}; \n\t\t\n\t\t\t\tDo[ If[f[roots[\([k]\)] + \((tf - to)\)/5000] > 0, fillcolor = RGBColor[1, 0, 0], fillcolor = RGBColor[0, 0, 1]]; \n\t\t\t\t\tpinter = FilledPlot[f[t], {t, roots[\([k]\)], roots[\([k + 1]\)]}, PlotRange -> {{to, tf}, frange}, ImageSize -> {72*size, 72*size/2}, AspectRatio -> 1/2, PlotStyle -> {RGBColor[0, 0, 0], Thickness[0.008]}, Fills -> {fillcolor}, AxesFront -> True, Curves -> Front, DisplayFunction -> Identity]; \n\t\t\t\t\tp2t = Append[p2t, pinter], {k, 1, lim}]; \n\t\t\t\tIf[ f[ta - \((tf - to)\)/5000] > 0, fillcolor = RGBColor[1, 0, 0], fillcolor = RGBColor[0, 0, 1]]; \n\t\t\t\tpinter2 = FilledPlot[ f[t], {t, roots[\([lim + 1]\)], If[ta == roots[\([lim + 1]\)], ta + \((tf - to)\)/5000, ta]}, PlotRange -> {{to, tf}, frange}, PlotStyle -> {RGBColor[0, 0, 0], Thickness[0.008]}, Fills -> {fillcolor}, AxesFront -> True, Curves -> Front, ImageSize -> {72*size, 72*size/2}, AspectRatio -> 1/2, DisplayFunction -> Identity]; \n\t\t\tp2t = Append[p2t, pinter2]; \n\t\t\n\t\t\tpint = Plot[f[t], {t, to, tf}, PlotRange -> {{to, tf}, frange}, ImageSize -> {72*size, 72*size/2}, AspectRatio -> 1/2, PlotStyle -> {RGBColor[0, 0, 0], Thickness[0.008]}, AxesLabel \[Rule] {"\", "\"}, Epilog -> {Thickness[0.010], RGBColor[0, 0, 0], Arrow[{ta, 0}, {ta, f[ta]}], Text[\*"\"\<\!\(dQ\/dt\)\>\"", {ta, f[ta]/2}, {\(-1\), 0}]}, DisplayFunction -> Identity]; \n\t\t\tp2t = Prepend[p2t, pint]; \n\t\t\t\n\t\t\t\n\t\t\tp2 = Show[p2t, ImageSize -> {72*size, 72*size/2}, AspectRatio \[Rule] 1/2, AxesFront -> True, PlotRegion -> {{0, 1}, {0, 1}}, \ DisplayFunction -> Identity]; \n\t\t\t\n Show[GraphicsArray[{p2, p1}], ImageSize -> {72*size, 72*size/4}, AspectRatio \[Rule] 1/4, PlotRegion -> {{0, 1}, {0, 1}}, \ DisplayFunction -> $DisplayFunction], {ta, to, If[periodic == 1, tf - steprat*\((tf - to)\), tf], \((tf - to)\)/25}];];\)\)}], "Input", Editable->False, CellOpen->False, InitializationCell->True], Cell[CellGroupData[{ Cell["Introduction", "Section", PageWidth->WindowWidth], Cell[TextData[{ "OBJECTIVE: Gain an appreciation for the importance of the Fundamental \ Theorem of Calculus and the Mean Value Theorem in practical applications.\n\n\ The purpose of this module is to show the wide applicability of some of the \ basic ideas in calculus of single variable functions. In addition to gaining \ a better understanding and appreciation for the Fundamental Theorem of \ Calculus and the Mean Value Theorem, you will also see the importance of \ finding the areas between the graphs of functions and identifying extreme \ values. Let's get started. \n\n", StyleBox["This lab is due on Tuesday, November 18. Please answer all \ questions in complete sentences, making clear the context of the answer.", FontColor->RGBColor[1, 0, 0]] }], "Text", PageWidth->WindowWidth] }, Closed]], Cell[CellGroupData[{ Cell["Rain Catchers", "Section", PageWidth->PaperWidth], Cell[TextData[StyleBox["Background", "Subsubsection"]], "Subsection", PageWidth->PaperWidth], Cell["\<\ Property owners are required by law to ensure that water running off their \ properties during a storm does not do harm to their neighbors. This can often \ be a challenge for cities, towns, and municipalities where large flows of \ water can run over public properties and in streets and roadways, presenting \ a potential threat to private property owners. As a result, public as well as \ private entities have to take measures to control storm runoff. Numerous \ examples of such efforts can be found in and around the Los Angeles basin in \ California. In this module, you will explore how one would go about designing a detention \ basin to collect runoff water from a rainstorm and release it at a controlled \ flow rate.\ \>", "Text", PageWidth->WindowWidth], Cell[TextData[StyleBox["Here Comes the Rain", "Subsubsection"]], "Subsection", PageWidth->PaperWidth], Cell[TextData[{ "During a severe 24-hour storm, water flows out of a drainage channel at \ the rate given by ", Cell[BoxData[ FormBox[ RowBox[{ FractionBox[ StyleBox[ RowBox[{"d", StyleBox["Q", FontSlant->"Italic"]}]], "dt"], "=", \(10000 \( t\^2\) e\^\(\(-t\)/2\)\)}], TraditionalForm]]], ", where ", StyleBox["t", FontSlant->"Italic"], " is in hours and ", Cell[BoxData[ FormBox[ FractionBox[ StyleBox[ RowBox[{"d", StyleBox["Q", FontSlant->"Italic"]}]], "dt"], TraditionalForm]]], "is in cubic feet per hour. Execute the two cells below to plot the flow \ rate function." }], "Text", PageWidth->WindowWidth], Cell[BoxData[{ \(\(Clear[Q];\)\), "\[IndentingNewLine]", \(\(Q\^\[Prime]\)[t_] = 10000 \( t\^2\) Exp[\(-t\)/2]\)}], "Input", PageWidth->PaperWidth], Cell[BoxData[ \(\(Plot[\(Q\^\[Prime]\)[t], {t, 0, 24}, AxesLabel -> {"\", \*"\"\<\!\(Q\^\[Prime]\) (\!\(ft\^3\)/hr)\ \>\""}, PlotStyle \[Rule] {RGBColor[0, 0, 1]}];\)\)], "Input", PageWidth->PaperWidth], Cell[TextData[{ "We would like to know what the maximum flow rate is and where it occurs. \ ", StyleBox["Execute the two cells below and compare the results with the \ graph you just generated to determine where the maximum flow rate occurs. \ Then use ", FontColor->RGBColor[1, 0, 0]], StyleBox["Mathematica", FontSlant->"Italic", FontColor->RGBColor[1, 0, 0]], StyleBox[" to find the maximum flow rate. Paste the cell you use for this \ computation into your lab report. Be sure to use the correct units with your \ answer.", FontColor->RGBColor[1, 0, 0]] }], "Text"], Cell[BoxData[ \(\(Q\^\[DoublePrime]\)[t_] = D[\(Q\^\[Prime]\)[t], t] // Simplify\)], "Input", PageWidth->PaperWidth], Cell[BoxData[ \(soln = Solve[\(Q\^\[DoublePrime]\)[t] \[Equal] 0, t]\)], "Input", PageWidth->PaperWidth], Cell[TextData[{ "Imagine that you have been asked to design a storm drain detention basin \ to catch and hold all of the water that flows out the drainage channel during \ this severe 24-hour storm. How much water would the detention basin have to \ hold?\nThe total amount of water that flows out of the drainage channel \ during the 24-hour storm is the area under the graph of ", Cell[BoxData[ \(\(Q\^\[Prime]\)[t]\)]], ". You can show this area by loading a special graphics package called ", StyleBox["Graphics`FilledPlot`", FontWeight->"Bold"], " that contains the ", StyleBox["FilledPlot[ ]", FontWeight->"Bold"], " command.\n" }], "Text", PageWidth->WindowWidth], Cell[BoxData[ \(<< Graphics`FilledPlot`\)], "Input", PageWidth->PaperWidth], Cell[BoxData[ \(\(FilledPlot[\(Q\^\[Prime]\)[t], {t, 0, 24}, Fills \[Rule] {RGBColor[1, 0, 0]}, AxesLabel \[Rule] {"\", \ \*"\"\<\!\(Q\^\[Prime]\)(\!\(ft\^3\)/hr)\>\""}];\)\)], "Input", PageWidth->PaperWidth], Cell["\<\ The definite integral gives the area under the graph, which is the total \ amount of water that flows out of the drainage channel during the 24-hour \ storm.\ \>", "Text", PageWidth->WindowWidth], Cell[BoxData[ \(Q[24] = \[Integral]\_0\%24\( Q\^\[Prime]\)[t] \[DifferentialD]t // N\)], "Input", PageWidth->PaperWidth], Cell[TextData[StyleBox["So, how much water flows out of the drainage channel \ during this 24-hour storm?", FontColor->RGBColor[1, 0, 0]]], "Text"], Cell[TextData[{ "The detention basin must be able to hold about 160,000 cubic feet of \ water. To get an idea of how much water this is, think of a cube with this \ much volume. The length of each side would have to be ", Cell[BoxData[ \(TraditionalForm\`\@160000\%3\)]], "ft or\n" }], "Text", PageWidth->WindowWidth], Cell[BoxData[ \(\@160000\%3 // N\)], "Input", PageWidth->PaperWidth], Cell["\<\ What is the average flow rate during the storm? You can calculate the average \ flow rate two different ways. Here is the first way:\ \>", "Text", PageWidth->WindowWidth], Cell[BoxData[ \(Q\&_\^\[Prime] = \(1\/\(24 - 0\)\) \(\[Integral]\_0\%24\( Q\^\[Prime]\)[ t] \[DifferentialD]t\) // N\)], "Input", PageWidth->PaperWidth], Cell[TextData[StyleBox["Why does the calculation above give you the average \ flow rate during the storm?", FontColor->RGBColor[1, 0, 0]]], "Text"], Cell["Here is the second way:", "Text", PageWidth->PaperWidth], Cell[BoxData[{ \(\(Q[0] = 0;\)\), "\[IndentingNewLine]", \(Q\&_\^\[Prime] = \(Q[24] - Q[0]\)\/\(24 - 0\)\)}], "Input", PageWidth->PaperWidth], Cell["\<\ Why does the calculation above give you the average flow rate during the \ storm?\ \>", "Text", FontColor->RGBColor[1, 0, 0]], Cell[TextData[{ "Therefore, the average flow is 6663.18 ", Cell[BoxData[ \(TraditionalForm\`ft\^3\/hr\)]], ". ", StyleBox["Use Part 2 of the Fundamental Theorem of Calculus to explain why \ these two calculations give the same values.", FontColor->RGBColor[1, 0, 0]] }], "Text", PageWidth->WindowWidth], Cell[TextData[{ "At what time(s) during the 24-hour event does the flow rate equal the \ average rate of flow? Execute the cell below to find out. ", StyleBox["What theorem guarantees the existence of a time when the flow \ rate is equal to the average flow rate?", FontColor->RGBColor[1, 0, 0]] }], "Text", PageWidth->WindowWidth], Cell[BoxData[ \(Solve[\(Q\^\[Prime]\)[t] \[Equal] Q\&_\^\[Prime], t]\)], "Input", PageWidth->PaperWidth], Cell[BoxData[ ButtonBox[ ButtonBox[ RowBox[{ StyleBox["\[MathematicaIcon]", FontSize->18, FontWeight->"Bold", FontColor->RGBColor[0.792981, 0.777356, 0.144533], FontVariations->{"CompatibilityType"->0}], StyleBox[" ", FontSize->14, FontWeight->"Bold", FontSlant->"Italic"], StyleBox["About", FontSize->14, FontWeight->"Bold", FontColor->RGBColor[0.500008, 0, 0.500008]], StyleBox[" ", FontSize->14, FontWeight->"Bold", FontSlant->"Italic"], StyleBox["Mathematica", FontSize->14, FontWeight->"Bold", FontSlant->"Italic", FontColor->RGBColor[0.500008, 0, 0.500008]]}], ButtonStyle->"Hyperlink"], ButtonData:>"h1", ButtonStyle->"Hyperlink"]], "Input", PageWidth->PaperWidth, Evaluatable->False, CellTags->"h1b"], Cell[TextData[{ "Only the positive values for ", StyleBox["t", FontSlant->"Italic"], " make sense since ", Cell[BoxData[ \(\(Q\^\[Prime]\)[t]\)]], "is only defined for ", StyleBox["t ", FontSlant->"Italic"], "\[GreaterEqual] 0. So now answer the question, ", StyleBox["at what time(s) during the 24-hour event does the flow rate equal \ the average rate of flow?", FontColor->RGBColor[1, 0, 0]], "\n\nIf the detention basin is empty at ", StyleBox["t ", FontSlant->"Italic"], "= 0, find a function that gives the total amount of water ", StyleBox["Q", FontSlant->"Italic"], " in the basin as a function of time during the 24 hours, and graph the \ function." }], "Text", PageWidth->WindowWidth], Cell[BoxData[ \(Q[t_] = \(\(\[Integral]\_0\%t\( Q\^\[Prime]\)[u] \[DifferentialD]u + Q[0]\)\(\ \)\(//\)\(Simplify\)\(\ \ \ \ \ \ \ \ \ \ \ \ \)\( (*from\ \ the\ Fundamental\ Theorem\ of\ Calculus, \ Part\ 1*) \)\)\)], "Input", PageWidth->PaperWidth], Cell[BoxData[ \(\(Plot[Q[t], {t, 0, 24}, AxesLabel \[Rule] {"\", \*"\"\\""}, PlotStyle \[Rule] {RGBColor[0, 1, 0]}];\)\)], "Input", PageWidth->PaperWidth], Cell[TextData[StyleBox["Approximately how much water is in the detention \ basin after 24 hours? Does this agree with what you found earlier?", FontColor->RGBColor[1, 0, 0]]], "Text"], Cell[TextData[StyleBox["Watch it Fill", "Subsubsection"]], "Subsection", PageWidth->PaperWidth], Cell[TextData[{ "We can watch the water accumulate in the detention basin using the \ command, ", StyleBox["antidifferentiate[ f[t], t, a, b, f[a] ]", FontWeight->"Bold"], ", which was designed specially for this demonstration. The arguments of \ the function are: ", StyleBox["f[t]", FontWeight->"Bold"], ", the rate of change function;", StyleBox[" ", FontWeight->"Bold", FontSlant->"Italic"], StyleBox["t", FontWeight->"Bold"], ", the independent variable; ", StyleBox["a", FontWeight->"Bold"], ", the beginning time; ", StyleBox["b", FontWeight->"Bold"], ", the ending time; and ", StyleBox["f[a]", FontWeight->"Bold"], ", the initial value of ", StyleBox["f[t]", FontWeight->"Bold"], ". \n\nTo animate the sequence of graphs:\n1. Execute the cell below these \ instructions. Be patient - it will take some time for it to generate the \ output.\n2. If necessary, widen the notebook window so that both graphs in \ each cell show across the page.\n2. Put the cursor in the cell bracket that \ contains all the graphics cells, and double click the left mouse button. This \ will collapse all the graphs into one cell, displaying only the first \ graphics cell in the sequence.\n3. Be sure the cell bracket that contains the \ collapsed graphics cells is selected (if not, place the cursor in the cell \ bracket and click once), and then press Ctrl+Y. This will play the sequence \ of graphics slides to generate the animation. \n4. While the animation is \ playing, a control bar appears at the bottom of the notebook window. This bar \ allows you to control the speed and direction of the animation.\n\n" }], "Text", PageWidth->WindowWidth], Cell[BoxData[ \(antidifferentiate[\(Q\^\[Prime]\)[t], t, 0, 24, 0]\)], "Input", PageWidth->PaperWidth], Cell["Explain what the animation is demonstrating.", "Text", FontColor->RGBColor[1, 0, 0]], Cell[TextData[{ "If the reservoir were to fill at a constant rate over the 24-hour period, \ what would the constant fill rate be? It would, of course, be the average \ rate of flow, ", Cell[BoxData[ \(\(\(Q\&_\^\[Prime]\)\(=\)\)\)]], "6663.18 ", Cell[BoxData[ \(TraditionalForm\`ft\^3\/hr\)]], ", that we calculated above. This is true because we know from the \ definition of the average value of a function that ", Cell[BoxData[ \(Q\&_\^\[Prime]\)]], "\[Times](", Cell[BoxData[ \(TraditionalForm\`t\_f - t\_i\)]], ") = ", Cell[BoxData[ FormBox[ RowBox[{\(\[Integral]\_\(t\_i\)\%\(t\_f\)\), RowBox[{ SuperscriptBox[ StyleBox["Q", FontSlant->"Plain"], "\[Prime]"], \(\[DifferentialD]t\)}]}], TraditionalForm]]], ". Let's watch the reservoir fill at the average rate instead of the \ actual. \n\nNote: The ", StyleBox["antidifferentiate[ ]", FontWeight->"Bold"], " command generates a lot of graphics, which may fill up your computer's \ memory. Before executing the next command, pull down the Kernel menu and \ select Delete All Output. All computed values are saved when you do this." }], "Text", PageWidth->WindowWidth], Cell[TextData[StyleBox["", CellFrame->True, Background->GrayLevel[0.849989]]], "Text", PageWidth->PaperWidth], Cell[BoxData[ \(antidifferentiate[Q\&_\^\[Prime], t, 0, 24, 0]\)], "Input", PageWidth->PaperWidth], Cell[TextData[StyleBox["The Mean Value Theorem: Integral Form", \ "Subsubsection"]], "Subsection", PageWidth->PaperWidth], Cell["\<\ For some additional insight, let's plot the constant average-rate-of-change \ function together with the actual-rate-of-change function.\ \>", "Text", PageWidth->PaperWidth], Cell[BoxData[ \(\(Plot[{\(Q\^\[Prime]\)[t], Q\&_\^\[Prime]}, {t, 0, 24}, PlotStyle \[Rule] {{RGBColor[0, 0, 1]}, {RGBColor[1, 0, 0]}}, AxesLabel \[Rule] {"\", \*"\"\<\!\(Q\^\[Prime]\)[t],\!\(Q\&_\^\ \[Prime]\)\>\""}];\)\)], "Input", PageWidth->PaperWidth], Cell[TextData[{ "The integral form of the Mean Value Theorem assures us that since ", Cell[BoxData[ \(\(Q\^\[Prime]\)[t]\)]], "is continuous on the 24-hour interval, there will be at least one time \ where the average rate of flow, ", Cell[BoxData[ \(Q\&_\^\[Prime]\)]], ", will equal the instantaneous rate of flow, ", Cell[BoxData[ \(\(Q\^\[Prime]\)[t]\)]], ". In this case, there are actually two. Do you see these two times on the \ preceding graph? ", StyleBox["What are these times?", FontColor->RGBColor[1, 0, 0]], " (We calculated them above.)" }], "Text", PageWidth->WindowWidth], Cell[TextData[StyleBox["The Mean Value Theorem: Derivative Form", \ "Subsubsection"]], "Subsection", PageWidth->PaperWidth], Cell["\<\ Let's plot the amount of water in the detention basin as a function of time \ for the two flow-rate functions shown in the graph above.\ \>", "Text", PageWidth->WindowWidth], Cell[BoxData[{ \(\(Q\_2[0] = 0;\)\), "\[IndentingNewLine]", \(Q\_2[t_] = Q\&_\^\[Prime]*t + Q\_2[0]\)}], "Input", PageWidth->PaperWidth], Cell[BoxData[ \(\(Plot[{Q[t], Q\_2[t]}, {t, 0, 24}, PlotStyle \[Rule] {{RGBColor[0, 0, 1]}, {RGBColor[1, 0, 0]}}, AxesLabel \[Rule] {"\", \*"\"\\""}];\)\)], \ "Input", PageWidth->PaperWidth], Cell[TextData[{ "In this case, the average rate of flow over the 24-hour interval is the \ slope of the secant line between the to points (0, 0) and (24, 159916). The \ derivative form of the Mean Value Theorem tells us that since ", Cell[BoxData[ \(TraditionalForm\`Q(t)\)]], " is continuous on the interval [0, 24] and differentiable on (0, 24), \ there will be at least one time where the instantaneous flow rate, ", Cell[BoxData[ RowBox[{ SuperscriptBox[ StyleBox["Q", FontSlant->"Italic"], "\[Prime]"], \((t)\)}]]], ", will equal the average flow rate, ", Cell[BoxData[ \(TraditionalForm\`\(\[CapitalDelta]\ Q\)\/\(\[CapitalDelta]\ t\)\)]], ". (Note that by the Fundamental Theorem of Calculus, Part 2\n\n", Cell[BoxData[ \(TraditionalForm\`\(\[CapitalDelta]\ Q\)\/\(\[CapitalDelta]\ t\)\)]], "=", Cell[BoxData[ FormBox[ FractionBox[ RowBox[{ RowBox[{ StyleBox["Q", FontSlant->"Italic"], "(", "24", ")"}], "-", RowBox[{ StyleBox["Q", FontSlant->"Italic"], "(", "0", ")"}]}], \(24 - 0\)], TraditionalForm]]], "=", Cell[BoxData[ FormBox[ RowBox[{\(1\/\(24 - 0\)\), RowBox[{\(\[Integral]\_0\%24\), RowBox[{ RowBox[{ StyleBox[ SuperscriptBox[ StyleBox["Q", FontSlant->"Italic"], "\[Prime]"], FontSlant->"Plain"], "(", "t", ")"}], \(\[DifferentialD]t\)}]}]}], TraditionalForm]]], "=", Cell[BoxData[ SuperscriptBox[ OverscriptBox[ StyleBox["Q", FontSlant->"Italic"], "_"], "\[Prime]"]]], ". \n\nThis is why we call the slope of the secant line the ", StyleBox["average rate of change", FontWeight->"Bold"], ": ", Cell[BoxData[ \(TraditionalForm\`\(\[CapitalDelta]\ Q\)\/\(\[CapitalDelta]\ t\)\)]], "=", Cell[BoxData[ SuperscriptBox[ OverscriptBox[ StyleBox["Q", FontSlant->"Italic"], "_"], "\[Prime]"]]], " truly is the average of the rate of change function over the interval.) \n\ \nThere are actually two points where ", Cell[BoxData[ FormBox[ SuperscriptBox[ StyleBox["Q", FontSlant->"Italic"], "\[Prime]"], TraditionalForm]]], "(t)=", Cell[BoxData[ SuperscriptBox[ OverscriptBox[ StyleBox["Q", FontSlant->"Italic"], "_"], "\[Prime]"]]], ". Do you see them in the graph above? ", StyleBox["Estimate the value of ", FontColor->RGBColor[1, 0, 0]], StyleBox["t", FontSlant->"Italic", FontColor->RGBColor[1, 0, 0]], StyleBox[" at each of those points. ", FontColor->RGBColor[1, 0, 0]], "To highlight them further, let's draw the tangents to the curve at the two \ points. First, we define a new function, ", StyleBox["L[ t, a ]", FontWeight->"Bold"], ", that gives the equation of the line tangent to ", Cell[BoxData[ FormBox[ StyleBox[\(Q(t)\), FontSlant->"Italic"], TraditionalForm]]], " at ", Cell[BoxData[ \(TraditionalForm\`t = a\)]], "; that is, it gives the linearization of ", Cell[BoxData[ FormBox[ StyleBox[\(Q(t)\), FontSlant->"Italic"], TraditionalForm]]], " at the point ", Cell[BoxData[ FormBox[ RowBox[{"(", RowBox[{"a", ",", " ", StyleBox[\(Q(a)\), FontSlant->"Italic"]}], StyleBox[")", FontSlant->"Italic"]}], TraditionalForm]]], "." }], "Text", PageWidth->WindowWidth], Cell[BoxData[{ \(\(Clear[L, a];\)\), "\[IndentingNewLine]", \(L[t_, a_] = \((Q[a] + \(Q\^\[Prime]\)[a]*\((t - a)\))\) // Simplify\)}], "Input", PageWidth->PaperWidth], Cell[TextData[{ "Note that for a specific value of ", StyleBox["a", FontSlant->"Italic"], ", ", "the ", StyleBox["L[ t, a ]", FontWeight->"Bold"], " command gives a linear function. For example," }], "Text", PageWidth->WindowWidth], Cell[BoxData[ \(\(L[t, 2] // N\) // Expand\)], "Input", PageWidth->PaperWidth], Cell[TextData[{ "Recall that in a preceding calculation we found the values of ", StyleBox["t", FontSlant->"Italic"], " where the average rate of change equals the instantaneous rate of change. \ We repeat the calculation here." }], "Text", PageWidth->WindowWidth], Cell[BoxData[ \(a = Solve[\(Q\^\[Prime]\)[t] \[Equal] Q\&_\^\[Prime], t]\)], "Input", PageWidth->PaperWidth], Cell[TextData[{ "Now we find the equations of the tangent lines at the two points in the \ domain where ", Cell[BoxData[ FormBox[ RowBox[{ RowBox[{ SuperscriptBox[ StyleBox["Q", FontSlant->"Italic"], "\[Prime]"], "(", "t", ")"}], "="}], TraditionalForm]]], Cell[BoxData[ SuperscriptBox[ OverscriptBox[ StyleBox["Q", FontSlant->"Italic"], "_"], "\[Prime]"]]], " and graph them together with ", Cell[BoxData[ \(TraditionalForm\`Q(t)\)]], " and ", Cell[BoxData[ \(TraditionalForm\`\(Q\_2\)(t)\)]], "." }], "Text", PageWidth->WindowWidth], Cell[BoxData[ \(tangent1 = L[t, a[\([2, 1, 2]\)]] // Simplify\)], "Input", PageWidth->PaperWidth], Cell[BoxData[ \(tangent2 = L[t, a[\([3, 1, 2]\)]] // Simplify\)], "Input", PageWidth->PaperWidth], Cell[BoxData[ \(\(Plot[{Q[t], Q\_2[t], tangent1, tangent2}, {t, 0, 24}, PlotStyle \[Rule] {{RGBColor[0, 0, 1]}, {RGBColor[1, 0, 0]}, {RGBColor[0, 0, 0]}, {RGBColor[0, 0, 0]}}, AxesLabel \[Rule] {"\", \*"\"\\""}];\)\)], \ "Input", PageWidth->PaperWidth], Cell["Let's zoom in a little.", "Text", PageWidth->PaperWidth], Cell[BoxData[ \(\(Plot[{Q[t], Q\_2[t], tangent1, tangent2}, {t, 0, 11}, PlotStyle \[Rule] {{RGBColor[0, 0, 1]}, {RGBColor[1, 0, 0]}, {RGBColor[0, 0, 0]}, {RGBColor[0, 0, 0]}}, AxesLabel \[Rule] {"\", \*"\"\\""}];\)\)], \ "Input", PageWidth->PaperWidth], Cell[TextData[{ "We see that the tangents at the two points are parallel to the secant \ line. That is, ", Cell[BoxData[ \(TraditionalForm\`\(\(\(Q\^\[Prime]\)(t)\)\(=\)\)\)]], Cell[BoxData[ \(TraditionalForm\`\(\[CapitalDelta]\ Q\)\/\(\[CapitalDelta]\ t\)\)]], Cell[BoxData[ \(TraditionalForm\` = \)]], Cell[BoxData[ RowBox[{" ", SuperscriptBox[ OverscriptBox[ StyleBox["Q", FontSlant->"Italic"], "_"], "\[Prime]"]}]]], " at these two points." }], "Text", PageWidth->WindowWidth], Cell[TextData[StyleBox["Let's Drain the Dam Thing", "Subsubsection"]], \ "Subsection", PageWidth->PaperWidth], Cell[TextData[{ "Now that we have a full detention basin, we need to figure out how to \ drain it. The design includes a pump that is capable of pumping 5000 ", Cell[BoxData[ \(TraditionalForm\`ft\^3\/hr\)]], "out of the basin. This rate of outflow is acceptable and won't flood our \ neighbors. The pump doesn't start until the amount of water in the reservoir \ reaches 50,000 cubic feet, and then it runs until the reservoir is empty. \ Let's find a function to describe how the water accumulates in the basin \ under these conditions. First, we determine when the pump will kick on." }], "Text", PageWidth->WindowWidth], Cell[BoxData[ \(\(\(ton\)\(=\)\(Solve[Q[t] \[Equal] 50000, t]\)\(\ \ \ \ \ \)\( (*This\ command\ won' t\ work, \ but\ don' t\ give\ \(up!\)*) \)\)\)], "Input", PageWidth->PaperWidth], Cell[TextData[{ "The ", StyleBox["Solve[ ]", FontWeight->"Bold"], " command doesn't work for this function, so we resort to the ", StyleBox["FindRoot[ ]", FontWeight->"Bold"], " command. From the graph of ", Cell[BoxData[ \(TraditionalForm\`Q(t)\)]], ", it appears that the water will reach 50000 cubic feet at about 4 hours, \ so we use this as a starting value in the ", StyleBox["FindRoot[ ]", FontWeight->"Bold"], " command." }], "Text", PageWidth->WindowWidth], Cell[BoxData[ \(ton = FindRoot[Q[t] \[Equal] 50000, {t, 4}]\)], "Input", PageWidth->PaperWidth], Cell[BoxData[ ButtonBox[ ButtonBox[ RowBox[{ StyleBox["\[MathematicaIcon]", FontSize->18, FontWeight->"Bold", FontColor->RGBColor[0.792981, 0.777356, 0.144533], FontVariations->{"CompatibilityType"->0}], StyleBox[" ", FontSize->14, FontWeight->"Bold", FontSlant->"Italic"], StyleBox["About", FontSize->14, FontWeight->"Bold", FontColor->RGBColor[0.500008, 0, 0.500008]], StyleBox[" ", FontSize->14, FontWeight->"Bold", FontSlant->"Italic"], StyleBox["Mathematica", FontSize->14, FontWeight->"Bold", FontSlant->"Italic", FontColor->RGBColor[0.500008, 0, 0.500008]]}], ButtonStyle->"Hyperlink"], ButtonData:>"h2", ButtonStyle->"Hyperlink"]], "Input", PageWidth->PaperWidth, Evaluatable->False, CellTags->"h2b"], Cell[TextData[StyleBox["At what time does the pump come on?", FontColor->RGBColor[1, 0, 0]]], "Text"], Cell["\<\ Now we can form the rate-of-fill function and graph it. First, we define the \ rate of inflow and the rate of outflow and graph each of them.\ \>", "Text", PageWidth->WindowWidth], Cell[BoxData[ \(inflowrate[t_] = 10000 \( t\^2\) Exp[\(-t\)/2]\)], "Input", PageWidth->PaperWidth], Cell[TextData[{ "The outflow rate function is piecewise defined since its value is 0 for ", StyleBox["t ", FontSlant->"Italic"], "< 3.92 and 5000 for ", StyleBox["t ", FontSlant->"Italic"], "\[GreaterEqual] 3.92. In ", StyleBox["Mathematica", FontSlant->"Italic"], ", the ", StyleBox["UnitStep[ ]", FontWeight->"Bold"], " command works well for constructing piecewise defined functions because \ ", StyleBox["Mathematica", FontSlant->"Italic"], " integrates the ", StyleBox["UnitStep[ ] ", FontWeight->"Bold"], "function correctly. The ", StyleBox["UnitStep[t ]", FontWeight->"Bold"], " function has a value of 0 for ", StyleBox["t ", FontSlant->"Italic"], "< 0 and 1 for ", StyleBox["t ", FontSlant->"Italic"], "\[GreaterEqual] 0. See how it works to define the outflow rate function in \ the next cell." }], "Text", PageWidth->WindowWidth], Cell[BoxData[ \(outflowrate[t_] = 5000*UnitStep[t - ton[\([1, 2]\)]]\)], "Input", PageWidth->PaperWidth], Cell[BoxData[ ButtonBox[ ButtonBox[ RowBox[{ StyleBox["\[MathematicaIcon]", FontSize->18, FontWeight->"Bold", FontColor->RGBColor[0.792981, 0.777356, 0.144533], FontVariations->{"CompatibilityType"->0}], StyleBox[" ", FontSize->14, FontWeight->"Bold", FontSlant->"Italic"], StyleBox["About", FontSize->14, FontWeight->"Bold", FontColor->RGBColor[0.500008, 0, 0.500008]], StyleBox[" ", FontSize->14, FontWeight->"Bold", FontSlant->"Italic"], StyleBox["Mathematica", FontSize->14, FontWeight->"Bold", FontSlant->"Italic", FontColor->RGBColor[0.500008, 0, 0.500008]]}], ButtonStyle->"Hyperlink"], ButtonData:>"h3", ButtonStyle->"Hyperlink"]], "Input", PageWidth->PaperWidth, Evaluatable->False, CellTags->"h3b"], Cell[BoxData[ \(\(Plot[{inflowrate[t], outflowrate[t]}, {t, 0, 48}, AxesLabel -> {"\", \*"\"\\""}, PlotStyle \[Rule] {{RGBColor[1, 0, 1]}, {RGBColor[0, 1, 0]}}];\)\)], "Input", PageWidth->PaperWidth], Cell[TextData[{ "The rate at which water accumulates is represented as the difference \ between the two curves, that is, (", StyleBox["inflowrate[t] - outflowrate[t]", FontWeight->"Bold"], "). The accumulated water can be represented as the signed area between the \ two graphs. To show this, we use the ", StyleBox["FilledPlot[ ]", FontWeight->"Bold"], " command from the special package, ", StyleBox["Graphics`FilledPlot`", FontWeight->"Bold"], ", that we loaded above. \n\nFirst, let's figure out when the reservoir \ stops filling and begins to drain. This will occur when the outflow rate of \ 5000 ", Cell[BoxData[ \(TraditionalForm\`ft\^3/hr\)]], " exceeds the inflow rate. In the graph above, it is the point where the \ two curves cross near ", Cell[BoxData[ \(TraditionalForm\`t = 12\)]], " hours. Let's find that point exactly." }], "Text", PageWidth->WindowWidth], Cell[BoxData[ \(FindRoot[\(Q\^\[Prime]\)[t] \[Equal] 5000, {t, 12}]\)], "Input", PageWidth->PaperWidth], Cell["At what time does the basin begin draining?", "Text", FontColor->RGBColor[1, 0, 0]], Cell["\<\ Let's plot the curves with the net inflow area colored red and the net \ outflow area colored blue.\ \>", "Text", PageWidth->WindowWidth], Cell[BoxData[ \(\(p1 = FilledPlot[{inflowrate[t], outflowrate[t]}, {t, 0, 10.9652}, AxesLabel -> {"\", \*"\"\\""}, PlotStyle \[Rule] {{Thickness[0.010], RGBColor[1, 0, 1]}, {Thickness[0.010], RGBColor[0, 1, 0]}}, Fills \[Rule] {RGBColor[1, 0, 0]}];\)\)], "Input", PageWidth->PaperWidth], Cell[BoxData[ \(\(p2 = FilledPlot[{inflowrate[t], outflowrate[t]}, {t, 10.9652, 40}, AxesLabel -> {"\", \*"\"\\""}, PlotStyle \[Rule] {{Thickness[0.010], RGBColor[1, 0, 1]}, {Thickness[0.010], RGBColor[0, 1, 0]}}, Fills \[Rule] {RGBColor[0, 0, 1]}];\)\)], "Input", PageWidth->PaperWidth], Cell[BoxData[ \(\(Show[p1, p2];\)\)], "Input", PageWidth->PaperWidth], Cell["\<\ The red area in the preceding graph represents the amount of water that has \ accumulated in the reservoir, and the blue area represents the net amount \ that has drained out of the reservoir. From the preceding graph, can you \ estimate when the basin will stop filling, when it will start draining, and \ when it will be empty? Let's form a function to describe the rate at which water accumulates in the \ basin and graph it. \ \>", "Text", PageWidth->WindowWidth], Cell[BoxData[{ \(\(Clear[Q];\)\), "\[IndentingNewLine]", \(\(Q\^\[Prime]\)[t_] = inflowrate[t] - outflowrate[t]\)}], "Input", PageWidth->PaperWidth], Cell[BoxData[ \(\(Plot[\(Q\^\[Prime]\)[t], {t, 0, 48}, AxesLabel -> {"\", \*"\"\<\!\(Q\^\[Prime]\) (\!\(ft\^3\)/hr)\ \>\""}, PlotStyle \[Rule] {RGBColor[0, 0, 1]}];\)\)], "Input", PageWidth->PaperWidth], Cell["\<\ Can you tell any better from the preceding graph when the basin will stop \ filling, when it will start draining, and when it will be empty?\ \>", "Text", PageWidth->WindowWidth], Cell[TextData[{ "You can use the ", StyleBox["antidifferentate[ ]", FontWeight->"Bold"], " command to watch the basin fill and drain. Animate the graphics if you \ wish to do so.\nNote: The ", StyleBox["antidifferentiate[ ]", FontWeight->"Bold"], " command generates a lot of graphics, which may fill up your computer's \ memory. Before executing the next command, pull down the Kernel menu and \ select Delete All Output. All computed values are saved when you do this. \ Note - you will have to scroll back up to this part of the lab after you \ Delete All Output.\n" }], "Text", PageWidth->WindowWidth], Cell[BoxData[ \(antidifferentiate[\(Q\^\[Prime]\)[t], t, 0, 50, 0]\)], "Input", PageWidth->PaperWidth], Cell[TextData[{ "It appears that the reservoir will be fully drained at about 36 hours \ after the storm begins or 12 hours after the storm ends. This occurs when the \ graph of ", StyleBox["Q[t]", FontWeight->"Bold"], " crosses the ", StyleBox["t", FontSlant->"Italic"], " axis and when the blue area is equal to the red area on the graph of ", Cell[BoxData[ FormBox[ RowBox[{ StyleBox[ SuperscriptBox[ StyleBox["Q", FontWeight->"Bold", FontSlant->"Plain"], "\[Prime]"], FontSlant->"Italic"], StyleBox["[", FontWeight->"Bold"], StyleBox["t", FontWeight->"Bold", FontSlant->"Plain"], StyleBox["]", FontWeight->"Bold"]}], TraditionalForm]]], ". Let's try it. Change the ending time to 36 hours in the command above, \ and execute it again." }], "Text", PageWidth->WindowWidth], Cell[TextData[StyleBox["How much water does the detention basin have to hold \ if we include the pump in the design?", FontColor->RGBColor[1, 0, 0]]], "Text", PageWidth->WindowWidth] }, Closed]], Cell[CellGroupData[{ Cell[TextData[{ StyleBox["\[MathematicaIcon]", FontWeight->"Bold", FontColor->RGBColor[0.792981, 0.777356, 0.144533], FontVariations->{"CompatibilityType"->0}], StyleBox[" ", FontWeight->"Bold", FontSlant->"Italic"], StyleBox["About", FontWeight->"Bold", FontColor->RGBColor[0.500008, 0, 0.500008]], StyleBox[" ", FontWeight->"Bold", FontSlant->"Italic"], StyleBox["Mathematica", FontWeight->"Bold", FontSlant->"Italic", FontColor->RGBColor[0.500008, 0, 0.500008]] }], "Section", PageWidth->PaperWidth, CellDingbat->None], Cell[TextData[{ "The error message that appears when you execute the ", StyleBox["Solve[ ]", FontWeight->"Bold"], " command warns you that whenever ", StyleBox["Mathematica", FontSlant->"Italic"], " uses inverse functions to solve an equation, some solutions may not be \ provided. A good example of this is the equation ", Cell[BoxData[ \(TraditionalForm\`sin\ x = 1\)]], ". ", StyleBox["Mathematica", FontSlant->"Italic"], " will use the inverse sine function to solve this equation, giving ", StyleBox["x", FontSlant->"Italic"], " = ", Cell[BoxData[ \(TraditionalForm\`\[Pi]\/2\)]], " (with the same warning message). We all know, however, that the equation \ actually has infinitely many solutions. They are", Cell[BoxData[ \(TraditionalForm\`\(\(\ \)\(x\ = \ \((4 n + 1)\)\)\)\)]], Cell[BoxData[ \(TraditionalForm\`\[Pi]\/2\)]], ", where ", StyleBox["n", FontSlant->"Italic"], " can be any integer. You might try using ", StyleBox["Mathematica", FontSlant->"Italic"], " to solve ", Cell[BoxData[ \(TraditionalForm\`sin\ x = 1\)]], ". ", ButtonBox["Go Back.", ButtonData:>"h1b", ButtonStyle->"Hyperlink"] }], "Text", PageWidth->WindowWidth, CellTags->"h1"], Cell[TextData[{ StyleBox["FindRoot[Q[t] = = 50000, ", FontWeight->"Bold"], Cell[BoxData[ FormBox[ RowBox[{ StyleBox["{", FontWeight->"Bold"], RowBox[{ StyleBox["t", FontWeight->"Bold", FontSlant->"Plain"], StyleBox[",", FontWeight->"Bold"], StyleBox[" ", FontWeight->"Bold"], StyleBox["4", FontWeight->"Bold"]}], StyleBox["}", FontWeight->"Bold"]}], TraditionalForm]]], StyleBox["]", FontWeight->"Bold"], " searches for a numerical solution to the equation ", StyleBox["Q[t] = = 50000", FontWeight->"Bold"], ", starting with", StyleBox[" ", FontWeight->"Bold"], Cell[BoxData[ FormBox[ RowBox[{ StyleBox["t", FontSlant->"Plain"], "=", "4"}], TraditionalForm]], FontWeight->"Bold"], ". To find out more about the ", StyleBox["FindRoot[ ] ", FontWeight->"Bold"], "command, pull down the Help menu, select the Help Browser, and type ", StyleBox["FindRoot", FontWeight->"Bold"], ". ", ButtonBox["Go Back.", ButtonData:>"h2b", ButtonStyle->"Hyperlink"] }], "Text", PageWidth->WindowWidth, CellTags->"h2"], Cell[TextData[{ "In ", StyleBox["Mathematica", FontSlant->"Italic"], ", the ", StyleBox["UnitStep[t] ", FontWeight->"Bold"], "command is the unit step function, sometimes called the Heaviside step \ function. This function has a value of 0 when the value of the independent \ variable is less than 0, and its value is 1 when the value of the independent \ variable is greater than or equal to 0. To learn more about the ", StyleBox["UnitStep[ ] ", FontWeight->"Bold"], "command, pull down the Help menu, select the Help Browser, and type ", StyleBox["UnitStep", FontWeight->"Bold"], ". ", ButtonBox["Go Back.", ButtonData:>"h3b", ButtonStyle->"Hyperlink"] }], "Text", PageWidth->WindowWidth, CellTags->"h3"] }, Closed]] }, FrontEndVersion->"5.0 for Microsoft Windows", ScreenRectangle->{{0, 1024}, {0, 677}}, AutoGeneratedPackage->None, WindowSize->{1016, 644}, WindowMargins->{{0, Automatic}, {Automatic, 0}}, PrintingCopies->1, PrintingPageRange->{Automatic, Automatic}, StyleDefinitions -> "DemoText.nb" ] (******************************************************************* Cached data follows. If you edit this Notebook file directly, not using Mathematica, you must remove the line containing CacheID at the top of the file. The cache data will then be recreated when you save this file from within Mathematica. *******************************************************************) (*CellTagsOutline CellTagsIndex->{ "h1b"->{ Cell[20617, 475, 1010, 31, 54, "Input", Evaluatable->False, CellTags->"h1b"]}, "h2b"->{ Cell[36863, 968, 1010, 31, 54, "Input", Evaluatable->False, CellTags->"h2b"]}, "h3b"->{ Cell[39316, 1052, 1010, 31, 54, "Input", Evaluatable->False, CellTags->"h3b"]}, "h1"->{ Cell[46333, 1262, 1274, 41, 92, "Text", CellTags->"h1"]}, "h2"->{ Cell[47610, 1305, 1293, 46, 48, "Text", CellTags->"h2"]}, "h3"->{ Cell[48906, 1353, 755, 22, 67, "Text", CellTags->"h3"]} } *) (*CellTagsIndex CellTagsIndex->{ {"h1b", 50390, 1397}, {"h2b", 50496, 1401}, {"h3b", 50602, 1405}, {"h1", 50708, 1409}, {"h2", 50786, 1412}, {"h3", 50864, 1415} } *) (*NotebookFileOutline Notebook[{ Cell[1754, 51, 55, 1, 70, "Title"], Cell[1812, 54, 153, 4, 33, "Text"], Cell[1968, 60, 571, 13, 19, "Input", CellOpen->False, InitializationCell->True], Cell[2542, 75, 10476, 174, 19, "Input", CellOpen->False, InitializationCell->True], Cell[CellGroupData[{ Cell[13043, 253, 57, 1, 54, "Section"], Cell[13103, 256, 804, 13, 191, "Text"] }, Closed]], Cell[CellGroupData[{ Cell[13944, 274, 57, 1, 34, "Section"], Cell[14004, 277, 94, 1, 40, "Subsection"], Cell[14101, 280, 779, 14, 148, "Text"], Cell[14883, 296, 103, 1, 40, "Subsection"], Cell[14989, 299, 793, 26, 51, "Text"], Cell[15785, 327, 158, 3, 60, "Input"], Cell[15946, 332, 226, 4, 62, "Input"], Cell[16175, 338, 594, 14, 67, "Text"], Cell[16772, 354, 129, 3, 40, "Input"], Cell[16904, 359, 110, 2, 40, "Input"], Cell[17017, 363, 700, 16, 129, "Text"], Cell[17720, 381, 81, 2, 40, "Input"], Cell[17804, 385, 241, 5, 62, "Input"], Cell[18048, 392, 207, 5, 29, "Text"], Cell[18258, 399, 135, 3, 52, "Input"], Cell[18396, 404, 149, 2, 29, "Text"], Cell[18548, 408, 331, 8, 82, "Text"], Cell[18882, 418, 74, 2, 44, "Input"], Cell[18959, 422, 182, 4, 29, "Text"], Cell[19144, 428, 174, 3, 52, "Input"], Cell[19321, 433, 149, 2, 29, "Text"], Cell[19473, 437, 64, 1, 29, "Text"], Cell[19540, 440, 152, 3, 73, "Input"], Cell[19695, 445, 137, 4, 29, "Text"], Cell[19835, 451, 322, 9, 35, "Text"], Cell[20160, 462, 341, 7, 48, "Text"], Cell[20504, 471, 110, 2, 41, "Input"], Cell[20617, 475, 1010, 31, 54, "Input", Evaluatable->False, CellTags->"h1b"], Cell[21630, 508, 748, 23, 110, "Text"], Cell[22381, 533, 266, 4, 72, "Input"], Cell[22650, 539, 203, 4, 62, "Input"], Cell[22856, 545, 185, 2, 29, "Text"], Cell[23044, 549, 97, 1, 40, "Subsection"], Cell[23144, 552, 1713, 40, 365, "Text"], Cell[24860, 594, 108, 2, 40, "Input"], Cell[24971, 598, 92, 1, 29, "Text"], Cell[25066, 601, 1255, 33, 157, "Text"], Cell[26324, 636, 115, 3, 29, "Text"], Cell[26442, 641, 104, 2, 41, "Input"], Cell[26549, 645, 123, 2, 40, "Subsection"], Cell[26675, 649, 185, 4, 48, "Text"], Cell[26863, 655, 283, 5, 82, "Input"], Cell[27149, 662, 630, 17, 67, "Text"], Cell[27782, 681, 125, 2, 40, "Subsection"], Cell[27910, 685, 185, 4, 29, "Text"], Cell[28098, 691, 147, 3, 60, "Input"], Cell[28248, 696, 239, 5, 80, "Input"], Cell[28490, 703, 3704, 111, 299, "Text"], Cell[32197, 816, 186, 4, 60, "Input"], Cell[32386, 822, 253, 10, 29, "Text"], Cell[32642, 834, 84, 2, 40, "Input"], Cell[32729, 838, 276, 7, 29, "Text"], Cell[33008, 847, 114, 2, 41, "Input"], Cell[33125, 851, 675, 24, 29, "Text"], Cell[33803, 877, 103, 2, 40, "Input"], Cell[33909, 881, 103, 2, 40, "Input"], Cell[34015, 885, 318, 6, 100, "Input"], Cell[34336, 893, 64, 1, 29, "Text"], Cell[34403, 896, 318, 6, 100, "Input"], Cell[34724, 904, 563, 17, 32, "Text"], Cell[35290, 923, 111, 2, 40, "Subsection"], Cell[35404, 927, 637, 11, 73, "Text"], Cell[36044, 940, 206, 4, 60, "Input"], Cell[36253, 946, 503, 16, 48, "Text"], Cell[36759, 964, 101, 2, 40, "Input"], Cell[36863, 968, 1010, 31, 54, "Input", Evaluatable->False, CellTags->"h2b"], Cell[37876, 1001, 103, 1, 29, "Text"], Cell[37982, 1004, 191, 4, 29, "Text"], Cell[38176, 1010, 104, 2, 40, "Input"], Cell[38283, 1014, 917, 32, 67, "Text"], Cell[39203, 1048, 110, 2, 40, "Input"], Cell[39316, 1052, 1010, 31, 54, "Input", Evaluatable->False, CellTags->"h3b"], Cell[40329, 1085, 274, 5, 83, "Input"], Cell[40606, 1092, 923, 23, 129, "Text"], Cell[41532, 1117, 109, 2, 40, "Input"], Cell[41644, 1121, 91, 1, 29, "Text"], Cell[41738, 1124, 149, 4, 29, "Text"], Cell[41890, 1130, 383, 7, 123, "Input"], Cell[42276, 1139, 384, 7, 123, "Input"], Cell[42663, 1148, 75, 2, 40, "Input"], Cell[42741, 1152, 480, 10, 110, "Text"], Cell[43224, 1164, 159, 3, 60, "Input"], Cell[43386, 1169, 226, 4, 62, "Input"], Cell[43615, 1175, 190, 4, 29, "Text"], Cell[43808, 1181, 625, 14, 110, "Text"], Cell[44436, 1197, 108, 2, 40, "Input"], Cell[44547, 1201, 974, 29, 48, "Text"], Cell[45524, 1232, 186, 3, 29, "Text"] }, Closed]], Cell[CellGroupData[{ Cell[45747, 1240, 583, 20, 34, "Section"], Cell[46333, 1262, 1274, 41, 92, "Text", CellTags->"h1"], Cell[47610, 1305, 1293, 46, 48, "Text", CellTags->"h2"], Cell[48906, 1353, 755, 22, 67, "Text", CellTags->"h3"] }, Closed]] } ] *) (******************************************************************* End of Mathematica Notebook file. *******************************************************************)