This preview shows pages 1–4. Sign up to view the full content.

Timothy Lin HW06 Modeling Insulin Loading with Differential Equations BEE 1510: Introduction to Computer Programming Homework Exercise 06 Timothy Lin Cornell University due: December 05, 2008

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
Executive Summary This exercise was meant to model the concentrations of insulin in different organs or areas of the body taking into account the different rates of movement of insulin between the different areas. In addition, the different volumes of each “compartment” are taken into account when there is an initial injection of insulin into one compartment. The assumption is made that when that injection is made at time t = 0, there is no other insulin in any other “compartment.” Problem The problem is how to graphically represent where insulin is and in what concentration in each body “compartment” over a certain given time with the inputs of the initial concentrations at each “compartment” and the span of time. Objective The objective of this homework exercise was to combine the use of differential equations in Matlab with the ODE solver. A function file mapping out the paths of insulin movement throughout the blood, kidneys, pancreas and abdomen is created using the “compartment” model. The rates of movement are designated by the compartment model and are used in the function file. Two similar function files with the same exact equations were also created, but one with halved k - rates and the other with doubled rates. In addition, for a more user-friendly use of these function files and the ODE solver, a GUI (Graphical User Interface) was created. This GUI took user inputs of the initial concentrations of insulin in the blood, kidneys, pancreas and the abdomen as well as the starting and ending times, ran it through the function files and returned graphical displays for the user. Materials and Methods There are four different equations used in the insulin function files (insulin w/ given rates, halved rates and doubled rates) that calculate how much insulin moves into each compartment and how much there is at designated times. The first equation describes how much insulin moves through blood, which in this “compartment” model, receives inputs from the abdomen, pancreas and kidneys and outputs to the kidneys and pancreas. The second equation describes how much insulin enters and leaves the kidneys, which just exchanges insulin (input and output) with the blood. The third equation describes how much insulin enters and leaves the pancreas, which also just exchanges insulin (input and output) with the blood. Finally, the last equation describes how much insulin leaves the abdomen, which outputs insulin only to the blood.
Materials and Methods – Algorithm for the insulin function (same for insulindouble and insulinhalf) 1. Enter Comments INSULIN is a function that uses a “compartment model” to view the concentration of insulin in the blood, kidneys, pancreas, and abdomen after it is injected into the abdomen. This function is

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}

### What students are saying

• As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

Kiran Temple University Fox School of Business ‘17, Course Hero Intern

• I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

Dana University of Pennsylvania ‘17, Course Hero Intern

• The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

Jill Tulane University ‘16, Course Hero Intern