You may assume that the path does not try to reach cells outside the given arrangement. [5
Question:
You may assume that the path does not try to reach cells outside the given arrangement. [5 marks] 7 Show, by defining suitable selector and constructor functions, how the ML type defined as follows: datatype L = N of int * unit->L; can be used in the representation of lazy integer lists. [5 marks] Define a function makeseq(f) that will yield a lazy list representing the following infinite sequence: 0, f(0), f(f(0)), ... where the integer at position i has the value f i (0). [5 marks] Define a function 'matches s seq', where s is of type int list and seq is a lazy list, that will yield a lazy list of integers giving the positions where s matches consecutive items in seq. For example, if matches [1 1] is applied to the lazy list 1,1,2,1,1,1,0,1,2,1,1,... it will produce a lazy list starting 0,3,4,9,
(a) Explain the uses of Eulerian and Hamiltonian graphs in the context of genome
assembly. [4 marks]
(b) Discuss, giving an example, how to apply de Bruijn graphs to genome assembly.
[6 marks]
(c) Discuss how the choice of different K-mer length affects the accuracy of genome
reconstruction. [3 marks]
(d) Discuss the additive property in phylogeny. [3 marks].
(e) Show one example of additive and one of non-additive matrices. [4 marks]
5 Business Studies
(a) A small software company accepts a contract to supply some specialist software.
The contract is worth £2M, paid by payments of £500k at start and three
payments of £500k invoiced against milestones expected at months 1, 3 and 5 of
the 6 month project. Staff costs are estimated at £150k/month and overheads
of £100k/month. Draw up an outline cashflow for this project. [5 marks]
(b) How profitable is this project if all goes to plan? [2 marks]
(c) At a project beer night towards the end of Month 3, your lead programmer
punches the project manager in the face, during a heated argument. The project
manager comes to you on the following day to complain to you in your role as
CEO. How will you handle this affair and what is the likely effect on the project's
progress? [8 marks]
(d) How would the resulting loss of progress affect the project's profitability?
[5 marks]
7 (TURN OVER)
CST.2016.7.8
6 Comparative Architectures
A large Last Level Cache (LLC) is necessary to achieve good performance in many
applications. Recent server class processors have included LLCs with capacities of 40
MBytes or more. Large caches such as this are constructed from numerous smaller
SRAM banks.
(a) Describe an appropriate on-chip network to interconnect 32 SRAM banks to
create a large LLC. The delay to access a bank should increase as we move
further away from the cache controller and bus interface. The SRAM banks are
square and the time taken for a signal to travel along the edge of a SRAM bank
is much less than your network's clock cycle time. [5 marks]
(b) To implement a set-associative LLC we may spread each set across multiple
banks, i.e. each "way" of the set will be in a different bank. The different
associative ways will have different access latencies depending on their distance
from the cache controller. How might we optimise the placement of lines in
particular banks (or ways) to minimise the cache's average access latency?
Remember to consider the cost of moving lines. [6 marks]
(c) How might the SRAM banks be efficiently interconnected so that the cache's
access time is constant regardless of which bank is accessed? [4 marks]
(d) Why might it be advantageous to be able to manage the amount of LLC used
by each co-scheduled thread in a chip multiprocessor? [5 marks]
8
CST.2016.7.9
7 Denotational Semantics
(a) (i) Define the notion of continuous function between domains. [2 marks]
(ii) Let P(N
2
) be the domain of all subsets of pairs of natural numbers ordered
by inclusion. Show that the function f : P(N
2
) → P(N
2
) given by
f(S) = { (1, 1) } ∪ { (x + 1, x · y) ∈ N
2
| (x, y) ∈ S } (S ⊆ N
2
)
is continuous. [3 marks]
(b) (i) State Tarski's fixed point theorem for a continuous endofunction on a
domain. [2 marks]
(ii) Give a concrete explicit description of the fixed point fix (f) ⊆ N
2 of the
continuous function f in Part (a)(ii). Briefly justify your answer.
[3 marks]
(c) (i) Define the notion of an admissible subset of a domain. [2 marks]
(ii) Let P ⊆ P(N
2
) be defined as P = { S ⊆ N
2
| ∀ (x, y) ∈ S. log y ≤ x·log x }.
Show that P is an admissible subset of the domain P(N
2
). [3 marks]
(d) (i) State Scott's fixed point induction principle. [2 marks]
(ii) Use Scott's fixed point induction principle to show that fix (f) ∈ P for f
the continuous function in Part (a)(ii) and P the admissible subset of the
domain P(N
2
) in Part (c)(ii). [3 marks]
9 (TURN OVER)
CST.2016.7.10
8 Hoare Logic and Model Checking
This question considers a language L which has integer variables V , arithmetic
expressions E and boolean expressions B, along with commands C of the forms
V :=E (assignment), C; C
0
(sequencing), IF B THEN C ELSE C
0
(conditional) and
WHILE B DO C (iteration).
(a) Explain the syntax of the Hoare-logic partial-correctness formula {P} C {Q}
and give a careful definition in English of when it is valid, that is, when
|= {P} C {Q}. [2 marks]
(b) How does the definition of validity for the total-correctness formula [P] C [Q]
differ? [1 mark]
(c) Preconditions and postconditions in {P} C {Q} often make use of logical
or auxiliary variables v in addition to program variables V . Explain why
this is useful illustrating your answer with a command C which satisfies
{T} C {R = X + Y} but not {X = x ∧ Y = y} C {R = x + y}.
(a) Give three methods of computing location of cell phones and indicate the
accuracy in each case. [10 marks]
(b) What is the location accuracy of GPS (Global Positioning System) and how
can it be improved? [5 marks]
(c) Give the accuracy of the ultrasonic Active Bat location system and discuss
how it might compare with radio-based ultra wideband location systems.
[5 marks]
15 Additional Topics
(a) In relation to the locational privacy problem for the Active Badge system:
(i) Define location privacy.
(ii) Define a sensible security policy for the system with respect to location
privacy.
(iii) What elements of the system does a user need to trust?
(iv) What if one does not want to be tracked? [6 marks]
(b) In the Active Badge system, the badge emits its identifier and the building
infrastructure picks it up. To protect location privacy, some have suggested to
reverse this architecture: the room would transmit its identifier and the badge
would pick it up. Discuss advantages and disadvantages of this arrangement.
[2 marks]
(c) You are required to design the security architecture for a location-based
system. You are the cellular phone operator, so you know the location of
users; application providers selling their location-based services to users must
go through you. Of course you know the position of all active phones at all
times, but you want to reassure your users that application providers can't
track them. State your security policy and describe your implementation that
enforces it. [6 marks]
(d) Describe at least two attacks against the system you designed in part (c).
(a) Compare and contrast each of the following techniques for achieving
instruction-level parallelism:
(i) statically-scheduled super scalar;
(ii) out-of-order speculative execution;
(iii) Very Long Instruction Word (VLIW);
(iv) EPIC (as used by IA-64).
[12 marks]
(b) Discuss hardware multi-threading, and hence the different implementation
approaches that have been tried to enable a single CPU core to execute from
multiple instruction streams. How can multi-threading be used to improve
system performance? What are the pitfalls? [8 marks]
2 Digital Communication II
(a) Explain the terms Work Conservation and max-min fairness, in the context
of packet switching. [8 marks]
(b) Outline the operation of two work-conserving queueing schemes that provide
max-min fairness, and two (simpler) ones that do not. [8 marks]
(c) Give at least two main implementation costs associated with implementations
of fairness in packet switched routers. [4 marks]
3 Security
(a) Describe the Bell-LaPadula security policy. [6 marks]
(b) Describe the Chinese Wall security policy. [6 marks]
(c) To what extent is the Chinese Wall policy an extension of Bell-LaPadula?
[6 marks]
(d) Are either of these policies relevant to digital rights management? [2 marks]
2
CST.2003.7.3
4 Advanced Graphics
(a) We want to find the first intersection point between an arbitrary ray and a
sphere of arbitrary radius at an arbitrary position in space.
(i) List and define all of the parameters required to specify the geometry of
the ray and the sphere. [2 marks]
(ii) Give an algorithm which returns the desired intersection point (if it exists)
and the appropriate normal vector at the intersection point. [5 marks]
(b) Describe a method which converts an arbitrary sphere to a triangle mesh at a
desired resolution. The desired resolution is specified as a desired number of
triangles, D. Your method should produce a number of triangles, N, which is
within an order of magnitude of D: D/10 < N < 10D. [4 marks]
Auditing A Risk Based Approach to Conducting a Quality Audit
ISBN: 978-1305080577
10th edition
Authors: Karla Johnstone, Audrey Gramling, Larry E. Rittenberg