Answered step by step
Verified Expert Solution
Question
1 Approved Answer
30 Make a function called ntickets(N,gamma,p) that does the following: o calculates the number of tickets to be sold when the number of seats in
30 Make a function called ntickets(N,gamma,p) that does the following: o calculates the number of tickets to be sold when the number of seats in the flight is N and the probability of a "show" is p and gamma is the probability a plane will be truly overbooked (more people show than there are seats). You will do this in two ways: Use solely the appropriate discrete distribution Use the normal approximation o prints a named list containing nd, nc, N, p and gamma - where nd is calculated using the discrete distribution and nc is the same calculated with normal approximation. o creates a plot of Objective function Vs n, the objective function can be constructed from the defining equation by simply making the equation equal zero -- example 1-gamma-pnorm(...) = 0. The left-hand side can be called an objective function. Make two of these -- one for the discrete and one for the continuous case
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started