AMPl求解,下列三个问题,树模型文件数据文件分开

This exercise starts with a two-variable linear program similar in structure to the one of Sections 1.1 and 1.2, but with a quite different story behind it.
(a) You are in charge of an advertising campaign for a new product, with a budget of $1 million.
You can advertise on TV or in magazines. One minute of TV time costs $20,000 and reaches 1.8
million potential customers; a magazine page costs $10,000 and reaches 1 million. You must sign
up for at least 10 minutes of TV time. How should you spend your budget to maximize your audience? Formulate the problem in AMPL and solve it. Check the solution by hand using at least one
of the approaches described in Section 1.1.
(b) It takes creative talent to create effective advertising; in your organization, it takes three
person-weeks to create a magazine page, and one person-week to create a TV minute. You have
only 100 person-weeks available. Add this constraint to the model and determine how you should
now spend your budget.
(c) Radio advertising reaches a quarter million people per minute, costs $2,000 per minute, and
requires only 1 person-day of time. How does this medium affect your solutions?
(d) How does the solution chang

AMPL是一种建模语言,并不是一个求解器。它的主要作用是提供一种表达定义,优化问题的方式。有了问题的定义之后,再通过调用不同的求解器来求解问题