# Posts from the ‘MathBio Homework’ Category

## MathBio HW6, due Wed April 16

1. A cooperation model.

Consider the following two-species model. $\displaystyle \dot x = x(1 - x) + a x y$ $\displaystyle \dot y = c y (1 - y) + c b xy$

where $a$, $b$ and $c$ are positive constants.

1. Under what circumstances is there a positive coexistence equilibrium?
2. In the case where there exists a positive equilibrium, find ALL equilibria, determine their stability and sketch the phase plane.
3. What does the phase plane look like when there is no positive coexistence state?

2. On the half life of one-hit wonders

Suppose that there is a band that puts out a great first album, but then they soon run out of ideas.  The first album has 15 songs, of which 5 are good. The second album has 12 songs, of which 3 are good. The last album has 10 songs, of which only 1 is good.  Use Bayes’ Theorem to answer the following questions.

1. Suppose that a radio station picks songs at random to play and you hear one of their good songs on the radio.  What is the probability that song is from the first album?
2. Suppose that another radio station plays only good songs and chooses from them at random.  You hear one of the band’s good songs on this station.  What is the probability the song is from the first album?

You visit a neighbor’s house.  You know the neighbor has two children. When you knock, a girl answers the door.  What is the probability that the other child is a girl?

4. Bayes’ Theorem in the news.  Find an example in the news where a test is given widely to many people where there is little to no indication that the person being tested has the condition.  Some recent examples include concerns about mammograms and prescreening for prostate cancer. In the political sphere, there has been significant criticism of testing welfare recipients for drug use.

1. Provide a brief summary of the article you read. Be sure to point out exactly the nature of the false positives and what cost there is to taking action based on positive results.
2. From the article or from other supporting documents, estimate the rate of false positives, the rate of false negatives and the overall rate of prevalence of the condition that is being tested for.  Based on your estimates, what is the approximate probability that a positive test is correct?
3. Based on what you have read, do you think that current policy should change?

## MathBio: Gearing up for Test 2

If you a looking for problems to work on to prepare for Midterm 2, this post will be the place to look.  This will be updated several times over the next few days.

Challenge problems for discrete-time systems.

Solutions to the important parts of the Horseshoe Crab project are written up here:

For more practice, I recommend 3.3 #5 from the book.

Challenge problems for continuous-time systems.

The first and most important place to find problems for continuous time systems is in my supplemental lecture notes:  Systems of ODEs (pdf).  See in particular problems 4, 5, 6 and 7.  Solutions are included already for 4-6.  I will post a solution to 7 on Monday.

Challenge problem on epidemics. $\dot S = - \alpha SI + \gamma R$ $\dot I = \alpha SI - \beta I$ $\dot R = \beta I - \gamma R$

Set $\beta = 2$, $\gamma = 1$ and impose the constraint that $S + I + R = 1$.  Rewrite the system as a two dimensional system (in $S$ and $I$ only) and determine a condition for $\alpha$ such that there exists an endemic equilibrium (meaning an equilibrium $(S_*,I_*)$ where $S_* > 0$ and $I_* > 0$.  Classify the type of the endemic equilibrium.

SOLUTION

There is an endemic equilibrium if $\alpha > 2$.  CHECK me on this next part!!!  I’m getting that the endemic equilibrium is a stable spiral if $\alpha \in (2.0294, 35.9706)$

Challenge Problem for Nullcline Analysis

Consider the following system of ODEs which are from the class of Niche Competition models introduced in class.  (Both species exhibit logistic growth models when alone and have negative mutual interactions.) In this case, we have one unknown parameter $a$. $\dot x = x ( 2 -x - y)$ $\dot y = y (a - 2x - y)$

• Sketch the $x$ and $y$ nullclines in three cases: $a = 1, 3, 5$.  In each case, note whether there is an equilibrium in the first quadrant (a co-existence equilibrium).
• For what values of $a$ does this system have a coexistence equilibrium?
• When the coexistence equilibrium exists, what is its type?

SOLUTION

The x- and y- nullclines for this problem are pictured below.

There is only a coexistence equilibrium if $a \in (2,4)$. This equilibrium has coordinates $(x_*,y_*) = (a-2, 4-a)$.  After computing the Jacobian and evaluating at the fixed point, we see that the trace of the Jacobian is $-2$ for all values of $a$, while the determinant is $-(a-2)(4-a)$ which is always negative.  We conclude that, when it exists, the coexistence equilibrium is always a saddle node.

## MathBio: Homework 5, due Wed March 19

For the following assignment, you may work in groups but the homework you turn in should be your own.

Homework 5 (pdf)

UPDATE (3/17, 3:30 pm): For 1(b) you may set $m = 0.9$ and determine the stable age structure.

## MathBio: The Basic Horseshoe Crab Model During the last class before spring break, we were visited by Daniel Sasson from the Biology Department, a horseshoe crab expert and mathematical modeling enthusiast.  We presented several versions of our models for the “Blood Harvest” we discussed in Wednesday’s class and he advised us on some parameter values that make sense.  Our general conclusions are posted above and we began simulating the code in class.  Everyone immediately noticed an annoying, but persistent explosion no matter what parameters choices were made.  Basically, the default model was given as follows.

• $m$ is the mortality rate of juveniles, assumed during class to be 70%, but later determined to be a different value (see below).
• $g$ is the graduation rate of juveniles to be adults. Since it takes juveniles on average 10 years to become adults, we set this to 0.1
• $f_A$ is the fecundity of adults.  Daniel said that each female lays 60,000 eggs, of which roughly 10,000 are fertilized and become juveniles.
• $f_B$ is the fecundity of bled adults.  We assume that the fecundity is about half that of healthy adults.
• $h$ is the fraction of healthy adults that are harvested and bled each year.  Daniel’s research indicated that roughly one-fifth of the population is bled each year.
• $r$ is the rate of recovery of the bled adults.  We assume that after one year all bled crabs that have not died are recovered. So $r = 1 - \mu_B$.
• $\mu_A$ is the fraction of adults that die each year.  Daniel estimated that crabs live for about ten years as adults, so we set $\mu_A = 0.1$.
• $\mu_B$ is the fraction of bled adults that die each year.  The article indicated that roughly 20% of captured crabs do not survive the process.  It was not clear whether this was measured only during the harvesting process, or if the researchers tracked the crabs through out the year to observe their long term rate of death.

As was soon pointed out by David Garcia in the comments section of the Linear 3d coding post, the problem lay in our model for the graduation rate of juveniles to adults.  Very few juveniles progress to adulthood, but the way Version 1 of the model is written, 10% of the 10,000 fertilized eggs will become adults in the next generation.  A more realistic depiction of the dynamic would say that a very large portion of juveniles die first, and then 10% of the remaining juveniles become adults. The updated model would be this.

I wrote up some code to simulate Version 2.  blood_harvest.R

In the simulation depicted below, the annual fraction of juvenile deaths has been increased to 9/10.  Furthermore, to establish the dynamics before bleeding, the harvest parameter is set to zero. You will note that there is still exponential growth, but it is much slower.

Your next homework assignment will involve two parts (an explicit description will be posted Wednesday):

• You will determine what combinations of the juvenile death fraction $m$ and harvest capture fraction $h$ lead to exponential growth and decay.
• To introduce the possibility of a stable existence equilibrium, we will introduce logistic growth somewhere in the model and once again analyze circumstances under which the extinction equilibrium is unstable.

Though you are only required to analyze the basic models, I encourage groups with other models to analyze those in parallel to this model.  I will judge the extended models and will pick the best two, which will then presented to Daniel Sasson in a follow-up session.

## MathBio: Homework 4, Due Wed Feb 26

One problem, due Wed Feb 26

—————————————————

(Logan and Wolesenksy, 3.3 #2)

In 1998, van der Meijden described the following model connecting the cinnabar moth and ragweed.  The life cycle of the moth is as follows.  It lives for one year, lays its eggs on the plant, and dies. The eggs hatch the next spring.  The number of eggs is proportional to the plant biomass the preceding year, or $E_{t+1} = aB_t$.

The plant biomass the next year depends on the biomass the current year and the number of eggs according to $B_{t+1} = k e^{-cE_t / B_t}$.

• Explain why the last equation is a reasonable model (plant biomass vs eggs and biomass vs biomass).
• What are the dimensions of $k$, $c$ and $a$?
• Rewrite the model equations in terms of the “rescaled” variables $X_t = B_t / k$ and $Y_t = E_t /ka$.  Define $b=ac$.  What are the dimensions of $X_t, \, Y_t$ and $b$?
• Find the equilibrium and determine a condition on $b$ for which the equilibrium is stable.
• If the system is perturbed from equilibrium, describe how it returns to equilibrium in the stable case. (This means:  is the dominant eigenvalue real or complex?  If it is complex, this means there are decaying oscillations toward the equilibrium.)

—————————————————

One further note about the suggested problem, 3.3 #1.  It appears that there is a typo either in the statement of the problem or in the given solution.  If the statement of the problem is correct, then the projection matrix seen at the top of page 376 should be $\left( \begin{array}{cc} 2 & -2 \\ -1 & 1 \end{array}\right)$.

Otherwise, the model should be $\Delta P_t = - P_t - 2Q_t, \quad \Delta Q_t = - P_t$.

As a hint, keep in mind that this is equivalent to our usual form $P_{t+1} = - 2 Q_t$ $Q_{t+1} = -P_t + Q_t$.

For practice, it’s worth doing the problem both ways and comparing the outcomes.

——————————————————-

UPDATE:  Here are the solutions to 3.3 #2 (b) – (e):  Solutions, HW4 (pdf)