School of Computer Science题量大约四五道,与Mock Examination难度相当

欢迎随时预定学霸大神

Answer ALL questions. The paper will be marked out of 60, which will be rescaled to a mark out of 100.

Question 2 : Context-free Languages

Question 3 : Models of Computation

Question 4 : Decidability and Complexity
(a) Following a spate of malware problems, several companies are reviewing their security
procedures.
(i) The manager of Very Careful Ltd. instructs their IT team to write a program
that can determine whether an app is able to corrupt data. Can this instruction
be carried out? Explain your answer.
(ii) The manager of Somewhat Careful Inc. instructs their IT team to write a
program that can determine whether an app’s code contains the signature (the
essential part of the code) of a known virus. Can this instruction be carried
out? Explain your answer.

(b) The following program takes as input a nonempty array p of a’s and b’s of length
n > 0.
elapse 2 seconds;
for (int i=0; i<n-1; i++){
elapse 1 second;
if (p[i]==’b’ && p[i+1]==’a’) {
p[i+1] = ‘b’;
elapse 1 second;
}
}
For example, if the input is abab, then the output is abbb. All the running time is
given by the elapse instructions.
Give the best case, worst case, and average case running time for length n = 3. For
the average case, assume that each entry is independent, with a and b equally likely.
Show that the worse case running time is O(n).
[9 marks]

扫一扫又不会怀孕,扫一扫,作业无烦恼。
留学顾问の QQ:2128789860
留学顾问の微信:risepaper

本次展示的是第九次作业

Assignment 9:  Transportation Planning With LP

A. You are a transportation economist for an Italian firm.  In the next planning period, the firm must ship a product from Milan, Florence and Venice, to Turin, Genoa, Pisa, Modena and Padua.  The quantities available by source, the quantities needed by destination, and unit transportation costs are as follows

Download the Excel file named MEL09-F15 Tran LP.xls.  Set up this partially completed worksheet to solve minimum cost transportation problems with up to six sources and up to six destinations.  Add the constraint equations (out-shipments by source and in-shipments by destination) and the objective/target equation (total transportation cost).  Hint: this is a very good place to use the SUMPRODUCT function.

Set up the solver to find the minimum cost transportation plan for any problem with up to six sources and six destinations.  Select the non-negative decision variables option and Simplex LP solution method.  Enter the data for the problem above and find the optimal shipping plan using the Excel solver.  Save the answer and sensitivity report tabs – you will be submitting your Excel file.

B. In the next shipping period, the per unit transport costs for shipments from Venice will be 25% higher due to road construction projects.  Modify the problem and solve it for the new rate structure.  Again, save the answer report and sensitivity report tabs.

C. Prepare a Word document with a complete description of the analyses you completed for problems A and B, and the results of the analyses.  Write your report in the form of a memo to your company’s Director of Logistics.Your memo should be clear in meaning and free of errors.  Use of linear programming and related economic terms and concepts should be correct and consistent – you may assume that the Director is familiar with these concepts and terms.  Your memo should be complete, including data tables and tables of results.

D. For this assignment, you will submit your xlsx file with the two answer and sensitivity reports, and your docx file with the memo to the Director of Logistics.  Details about submitting your assignment will be provided at the December 2 labs session.