170 likes | 507 Views
Graphical Integration Exogenous Rates, Step Functions & Ramp Functions. Simulation and Modeling. References. Graphical Integration Exercises. Part One : Exogenous Rates D-4547-1.pdf Graphical Integration Exercises. Part Two : Ramp Functions D-4571.pdf All attached. Graphical Integration.
E N D
Graphical IntegrationExogenous Rates, Step Functions & Ramp Functions Simulation and Modeling Week 7 – Graphical Integration
References • Graphical Integration Exercises. Part One : Exogenous Rates • D-4547-1.pdf • Graphical Integration Exercises. Part Two : Ramp Functions • D-4571.pdf All attached Week 7 – Graphical Integration
Graphical Integration • Helps improve our understanding of the relation between structure and behaviour and also to catch errors in the model built. • Helps us to be able to predict and understand what we see on the graph after running a simulation • Graphical integration of constant flows as well as step functions falls under exogenous rates • Ramp function exhibits linearly increasing or decreasing behaviour. Week 7 – Graphical Integration
Exogenous rates/Endogenous rates • Exogenous rate : is a rate variable that cannot be affected by that system. • Endogenous rate: is a rate variable that is affected by that system. Many of the systems we see in the real world are affected by endogenous rates. • For example, suppose you are trying to explain consumption of individuals in the Uganda. Consumption would be an endogenous variable-a variable you are trying to explain. • An example of exogenous variable is the income tax rate. The income tax rate is set by the government, and if you are not interested in explaining government behavior, you would take the tax rate as exogenous. Week 7 – Graphical Integration
Systems: constant rate : Inflow • Consider a bathtub : we have the following • Level of Water in bathtub - variable • Rate : inflow of water - constant • Time – variable • Example : • If the inflow of water is at a rate of 2 units of water per unit time • Initial level of water in the tub is 0 units • At the end of 12 units of time we shall have • Level of water at 24 units of water. Time Week 7 – Graphical Integration
Systems : Constant rate : outflow • Consider an outflow from the bathtub : we have the following • Level of Water in bathtub - variable • Rate : outflow of water - constant • Time – variable • Example : • If the outflow of water is at a rate of 1 units of water per unit time. So the net constant flow is netflow = inflow-outflow : netflow = 0 – (1) = -1 which gives a negative slope • Initial level of water in the tub is 40 units • At the end of 20 units of time we shall have • Level of water at 20 units of water. Time Week 7 – Graphical Integration
Step Function • A function that has a graph resembling a staircase. Week 7 – Graphical Integration
Step Function : Example 1 • System starts at a constant value, then steps either up or down to another constant value • Example : We delay turning on the faucet • Step function starts off at a constant value 0, • Step up to +3 at Time = 5 • Stock : Water in the tub • Until the Time =5, the stock stays at zero, and when the flow increases to 3, the stock accumulates at rate of 3 units per unit time Time Time Week 7 – Graphical Integration
Step Function : Example 2 • This example has two steps, one step up at Time = 5 and another at Time = 15. • Step function starts off at constant value 0, • Step up to 2, at time =5 • Step up to 8, at time =15 Time Time Week 7 – Graphical Integration
Step Function : Exercises Ex 1 : • Graph the behaviour of the system showing the stock (Water in bath tub) with the following specifications : • The flow has a constant rate of +3. • Assume that the initial value of the level is 0, • End time = 12 min • Ex 2 : • Graph the behaviour of the system showing the stock (Water in bath tub) with the following specifications : • Assume there is no inflow and outflow = 2. • Assume the initial value of the level is 40. • End time = 20 min Week 7 – Graphical Integration
Step Function : Exercises Ex 3 : • Graph the behaviour of the system showing the stock (Water in bath tub) with the following specifications : • The flow remains at constant 0, • Steps up to 4 at Time = 5min • Assume that the initial value of the level is 0, • End time = 20 min • Ex 4 : • Graph the behaviour of the system showing the stock (Water in bath tub) with the following specifications : • The flow remains at constant 0, • Steps up to 4 at Time = 5min • Then steps down to 2 at Time=15 min • Assume that the initial value of the level is 0, • End time = 20 min Week 7 – Graphical Integration
Ramp Functions • A ramp function is a flow that is increasing or decreasing linearly and thus it is not constant over time. • Example : Filling the bathtub by constantly turning the faucet in the “on” direction • As time goes by, not only does the amount of water in the tub increase but so does the rate at which water enters the tub from the faucet. Week 7 – Graphical Integration
Parabolic Growth : Linearly Increasing Flows • Area between flow graph and line representing the flow is Area : • Total Area = 0.5 *base*height • Total Area = 0.5*12*12 • Total Area = 72. Time Time • Calculating the area under the flow graph is important if you are to integrate it graphically since it allows you to determine the final value of stock • Final Value of Stock = Initial value of Stock + Total Area • Final Value of Stock = 0 +72 • Final Value of Stock = 72 Week 7 – Graphical Integration
Parabolic Growth : Linearly Increasing Flows • Total Area= Area under flat line until Time 10 + Area under the triangle : • Total Area = 0 + 0.5 *base*height • Total Area = 0 + 0.5*20*(20-10) • Total Area = 100 Time Time • Final Value of Stock = Initial value of Stock + Total Area • Final Value of Stock = 0 +100 • Final Value of Stock = 100 Week 7 – Graphical Integration
Decreasing Parabolic Growth : Linearly Decreasing Flows • Total Area= Area under flow graph : • Total Area = 0.5 *base*height • Total Area = 0.5*20*(20) • Total Area = 200 Time Time • Area under the flow graph is equal to the change in the value of the stock • Final Value of Stock = Initial value of Stock + Change in the Value of Stock • Final Value of Stock = 0 +200 • Final Value of Stock = 200 Week 7 – Graphical Integration
Linearly Increasing Flow : Exercises Ex 1 : • Graph the behaviour of the system showing the stock (Water in bath tub) with the following specifications : • Initial Flow is 0 units per minute. • It increases linearly with a slope of +2 units per minute, • Assume initial value of stock is 0. • End time = 20 min • Ex 2 : • Graph the behaviour of the system showing the stock (Water in bath tub) with the following specifications : • Initial rate of filling the tub is constant at +5 until Time = 5. • At time 5, the flow increases linearly with a slope of +1. • Assume the initial value of the stock to be 75. • End time is 20 min • (combines constant and linearly increasing flow) Week 7 – Graphical Integration
Linearly Decreasing Flow : Exercises Ex 1 : • Graph the behaviour of the system showing the stock (Water in bath tub) with the following specifications : • Initial Flow is 0 units per minute. • It increases linearly with a slope of +2 units per minute, • Assume initial value of stock is 0. • End time = 20 min • Ex 2 : • Graph the behaviour of the system showing the stock (Water in bath tub) with the following specifications : • Initial rate of filling the tub is constant at +5 until Time = 5. • At time 5, the flow increases linearly with a slope of +1. • Assume the initial value of the stock to be 75. • End time is 20 min • (combines constant and linearly decreasing flow) Week 7 – Graphical Integration