% Christopher Hanusa
% Christopher.Hanusa@qc.cuny.edu	
\documentclass[12pt]{article} 

\usepackage{amssymb,amsthm,amsmath,epsfig}

\usepackage{color}
\definecolor{darkblue}{rgb}{0, 0, .4}
\definecolor{grey}{rgb}{.7, .7, .7}

\setlength{\topmargin}{-.5in}
\setlength{\textheight}{9in}
\setlength{\textwidth}{6.5in}
%\setlength{\headheight}{26pt}
%\setlength{\headsep}{2pt}
\setlength{\oddsidemargin}{0in}
\setlength{\evensidemargin}{0in}

\newcommand{\lam}{\lambda}

\usepackage[breaklinks]{hyperref} 
\hypersetup{
    colorlinks=true,
    linkcolor=darkblue,
    anchorcolor=darkblue,
    citecolor=darkblue,
    pagecolor=darkblue,
    urlcolor=darkblue,
    pdftitle={},
    pdfauthor={}
}

\begin{document}
\pagestyle{empty}

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\begin{center}\large 
MATH 245, Spring 2014

{\sc Homework 5}

due 10:45{\sc am} on Monday, May 5.
\end{center}

\noindent
{\em Background reading:} Sections 5.1, 4.1, and 4.3 and Tutorial 5.  

\smallskip\noindent
Follow the posted homework guidelines when completing this assignment.  I ask that you do not contact previous Math Modeling students when completing this assignment.  Provide details of calculations and assertions that you include.  Don't forget to provide acknowledgments for those who helped you with the assignment and those resources that you consulted. As always, make sure to include text cells in your {\em Mathematica} notebook in order to explain what you are doing.



\begin{enumerate}
\item[\bf 5-1.] (7 pts) This question involves random simulation in {\em Mathematica}. 
\begin{enumerate}
\item Simulate rolling a 120-sided die 100 times, where the values on the sides of the die are the integers 1 through 120.  Modify the simulation in two ways.  In one modification, keep track of the {\bf sum} of the 100 rolls.  In a second modification, keep track of the {\bf highest value} that is rolled.  
\item  Now use a \verb+Table+ command to repeat each of these two experiments 1000 times.  (Or more if you get carried away!) The result will be two lists of 1000 numbers, each representing the sum and highest values in the simulations.  Take the average of these lists by using the command \verb+Mean+.  Is the average what you expect? 
\item Input the lists from part (b) into the \verb+Histogram+ command to see a visualization of the 1000 trials, and discuss how this is related to real-life die rolling.  Discuss your answer.
\end{enumerate}

\item[\bf 5-2.] (7 pts) 
 In this problem you will modify the waiting room algorithm from the notes and tutorial in order to better simulate the arrival of patients.  Suppose that the doctor determines that patients are more likely to arrive in the first half of the morning (9:00 to 10:29am) than in the second half of the morning (10:30 to 11:59am). Choose arrival probabilities for these two time periods that continues to ensure that the expected number of patients that arrive in any day is 13.5. (Make sure that you justify that your choices ensure this restriction.) Run your simulation at least 1000 times to determine if your modification increases, decreases, or keeps the same the expected number of patients in the waiting room at noon. Discuss whether the answer you find is what you expected to find.



\item[\bf 5-3.] (7 pts)
 For the optimization problem given below, do the following steps. 
 \begin{enumerate}
 \item Write down the linear optimization problem in standard form. 
 \item Draw the feasible region. 
 \item Find the optimal solution by hand. 
 \item Use {\em Mathematica} to solve the optimization problem.
 \end{enumerate}
\begin{quote}
A concrete company makes bags of concrete using beach and river sand. Each pound of beach sand costs 2.5 cents and contains 4 units of fine sand, 3 units of coarse sand, and 4 units of gravel. Each pound of river sand costs 6 cents and contains 3 units of fine sand, 6 units of coarse sand, and 12 units of gravel. Determine the cheapest combination of beach and river sand that will produce a bag of concrete, which requires at least 4 units of fine sand, at least 6 units of coarse sand, and at least 10 units of gravel.
\end{quote}


\end{enumerate}




\end{document}










