Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

on python 2 A discrete-time predator-prey model can be described by the following system of difference equations: Xk+1 = axk bxkYk Yk+1 = cyk +

image text in transcribed

on python 2

A discrete-time predator-prey model can be described by the following system of difference equations: Xk+1 = axk bxkYk Yk+1 = cyk + dxkYk In which x_{k+1}, y_{k+1} denote the prey and predator population at generation k+1 respectively, and a,b,c and d are positive constants. 1 - Write a recursive function that given initial values, x0 and yo, constants a,b,c,d and a specified number of generations n, returns the population size at the nth generation. 2- Use your function to calculate the populations sizes for the values specified below, up to 100th generation: a = 1.0 6, b = 0.007, C= 0.85, d= 0.003, x0=100 and yo=10 and store the values for each Xn and Yn in an array (i.e. X=(x0, x1, ... , xn],Y=[ye,y1, ... , xn]). 3 - Plot X vs Y. What is the predator population size when prey population is at 80? 4 - Plot values of X and Y vs number of generations 5 - Plot the combined population size (prey and predator) vs number of generations

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Design And Implementation

Authors: Edward Sciore

2nd Edition

3030338355, 978-3030338350

More Books

Students also viewed these Databases questions

Question

Describe how projective tests are used.

Answered: 1 week ago