Assignment

49 views 9:26 am 0 Comments March 25, 2023

MACM 203 Assignment 6
Spring 2023
This assignment is due Tuesday March 7th at 10pm. Upload your solutions to Crowdmark. Write your solutions as a single Matlab Live Script and export the script to PDF.
Write the course number and assignment number as the title of the Matlab Live Script,
followed by the table of contents, and then create a section for each part of the question.
Keep in mind that your assignment, including the source code, is a document that will
be read in order to be marked. It has to be very clear and properly formatted.
Your Matlab code must be general enough to solve any other instance of the same problem
without modification. That is, if you are asked to run your code on some data that are
specified in the assignment, then your code must run on any similar data set (or solve
any similar problem) without modification.
Assignments should be written individually. You can discuss in groups, but you have to
write your assignment yourself. In case of plagiarism SFU policies will be applied.
Preamble
This week’s assignment focuses on linear optimization.
Question 1 (15 marks)
Part (a)
An electronics company must deliver exactly 2400 units within the next 3 weeks. The
client will pay
$30 for each unit delivered by the end of the first week; $25 for each unit
delivered by the end of the second week, and
$20 for each unit delivered by the end of
the third week. Each worker can only assemble 40 units per week. The present labour
force of the company is 15 workers. Hence, the company must hire and train temporary
help. Any of the experienced workers can be taken off the assembly line to instruct at
most two trainees; after one week of instruction, each of the trainees can either proceed
to the assembly line or instruct new trainees.
Some workers may become idle towards the end of the project; however all workers
must be kept on the payroll until the end of the project. The weekly wages of a worker,
whether assembling, instructing, or being idle, are
$600; the weekly wages of a trainee are
$300. We assume that the wages are the only costs associated with the production.
Here is one possible example of scheduling the production:
1

Week 1: 12 assemblers, 3 instructors, 6 trainees, revenue from assembled units =
12
· 40 · 30 = 14400, wages = 12 · 600 + 3 · 600 + 6 · 300 = 10800.
Week 2: 13 assemblers, 8 instructors, 16 trainees, revenue from assembled units =
13
· 40 · 25 = 13000, wages = 13 · 600 + 8 · 600 + 16 · 300 = 17400.
Week 3: 35 assemblers, 2 idle, revenue from assembled units = 35 · 40 · 20 = 28000,
wages = 35
· 600 + 2 · 600 = 22200.
Total profit = total revenue
total wages = 55400 50400 = 5000 dollars.
The company wants to schedule the production so as to maximize the total profit.
Write down a Linear Programming formulation of this problem as Matlab code. Explain the meaning of your variables.
Hint: It follows from the theory of Linear Programming that you do not need to
explicitly assume that the variables in your formulation of this problem take only integer
values.
Part (b)
Solve the problem in Matlab. Print an optimal schedule of the production and the total
profit obtained from this optimal solution.
2