This commit is contained in:
jverzani 2023-05-01 11:03:42 -04:00
commit 3e57f389cf

View File

@ -186,7 +186,7 @@ plot(𝒇, -50, 50)
We can see the slant asymptote and hints of vertical asymptotes, but, we'd like to see more of the basic features of the graph.
Previously, we have discussed rational functions and their asymptotes. This function has numerator of degree $3$ and denominator of degree $2$, so will have a slant asymptote. As well, the zeros of the denominator, $0$ and $-2$, will lead to vertical asymptotes.
Previously, we have discussed rational functions and their asymptotes. This function has numerator of degree $3$ and denominator of degree $2$, so will have a slant asymptote. As well, the zeros of the denominator, $0$ and $2$, will lead to vertical asymptotes.
To identify how wide a viewing window should be, for the rational function the asymptotic behaviour is determined after the concavity is done changing and we are past all relative extrema, so we should take an interval that includes all potential inflection points and critical points:
@ -258,13 +258,13 @@ ex = log(x/100)/x
limit(ex, x=>0, dir="+"), limit(ex, x=>oo)
```
The $\ln(x/100)$ part of $f$ goes $-\infty$ as $x \rightarrow 0+$; yet $f(x)$ is eventually positive as $x \rightarrow 0$. So a graph should
The $\ln(x/100)$ part of $f$ goes $-\infty$ as $x \rightarrow 0+$; yet $f(x)$ is eventually positive as $x \rightarrow \infty$. So a graph should
* not show too much of the vertical asymptote
* capture the point where $f(x)$ must cross $0$
* capture the point where $f(x)$ has a relative maximum
* show enough past this maximum to indicate to the reader the eventual horizontal asyptote.
* show enough past this maximum to indicate to the reader the eventual horizontal asymptote.
For that, we need to get the $x$ intercepts and the critical points. The $x/100$ means this graph has some scaling to it, so we first look between $0$ and $200$:
@ -412,14 +412,15 @@ The *slant* asymptote has slope?
```{julia}
#| hold: true
#| echo: false
numericq(1)
numericq(-1)
```
The function has critical points at
```{julia}
#| hold: true,echo
#| hold: true
#| echo: false
radioq(qchoices, 2, keep_order=true)
```
@ -474,7 +475,7 @@ yesnoq("yes")
Two models for population growth are *exponential* growth: $P(t) = P_0 a^t$ and [logistic growth](https://en.wikipedia.org/wiki/Logistic_function#In_ecology:_modeling_population_growth): $P(t) = K P_0 a^t / (K + P_0(a^t - 1))$. The exponential growth model has growth rate proportional to the current population. The logistic model has growth rate depending on the current population *and* the available resources (which can limit growth).
Letting $K=10$, $P_0=5$, and $a= e^{1/4}$. A plot over $[0,5]$ shows somewhat similar behaviour:
Letting $K=50$, $P_0=5$, and $a= e^{1/4}$. A plot over $[0,5]$ shows somewhat similar behaviour:
```{julia}
@ -528,10 +529,10 @@ answ = 1
radioq(choices, answ)
```
##### Question
###### Question
The plotting algorithm for plotting functions starts with a small initial set of points over the specified interval ($21$) and then refines those sub-intervals where the second derivative is determined to be large.
The plotting algorithm for plotting functions starts with a small initial set of points over the specified interval ($31$) and then refines those sub-intervals where the second derivative is determined to be large.
Why are sub-intervals where the second derivative is large different than those where the second derivative is small?
@ -549,7 +550,7 @@ answ = 2
radioq(choices, answ)
```
##### Question
###### Question
Is there a nice algorithm to identify what domain a function should be plotted over to produce an informative graph? [Wilkinson](https://www.cs.uic.edu/~wilkinson/Publications/plotfunc.pdf) has some suggestions. (Wilkinson is well known to the `R` community as the specifier of the grammar of graphics.) It is mentioned that "finding an informative domain for a given function depends on at least three features: periodicity, asymptotics, and monotonicity."