0% found this document useful (0 votes)
58 views7 pages

Crypto Answers

This document contains the questions for a computer science exam with 9 questions covering topics in distributed systems, comparative architectures, specification and verification of hardware, numerical analysis, graphics, semantics, and additional topics. Students are instructed to answer 5 of the 9 questions.

Uploaded by

Tawan Jim
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
58 views7 pages

Crypto Answers

This document contains the questions for a computer science exam with 9 questions covering topics in distributed systems, comparative architectures, specification and verification of hardware, numerical analysis, graphics, semantics, and additional topics. Students are instructed to answer 5 of the 9 questions.

Uploaded by

Tawan Jim
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

CST.93.7.

COMPUTER SCIENCE TRIPOS Part II

Tuesday 1 June 1993 1.30 to 4.30

Paper 7

Answer five questions.


Submit the answers in five separate bundles each with its own cover sheet.
Write on one side of the paper only.

1 Distributed Systems

A distributed software system follows the client-server model. The microkernel


on which it is based supports multi-threaded processes. A remote procedure call
(RPC) package is used for client-server interactions. The RPC system runs above
an unreliable, datagram-based communications service.

(a) Explain how timers may be used in the RPC protocol to achieve client-server
synchronisation. [10 marks]

(b) Discuss how the RPC system may support the location of remote procedures.
[7 marks]

(c) Discuss the requirements on the RPC system that follow from the use of multi-
threaded processes. [3 marks]

2 Distributed Systems

A distributed computation may involve related operations on a number of objects


which reside at different nodes of a distributed system.

(a) Explain why the concept of transaction is suitable for modelling such a
computation. [6 marks]

(b) Explain what is involved in committing a transaction in a distributed system.


[14 marks]

1 [TURN OVER
CST.93.7.2

3 Comparative Architectures

A revisionist view might be that a processor design is RISC if every transistor pays
its way in terms of global system performance, i.e. the design is in some sense a
local optimum. Explain how this view relates to the original definition of RISC.
Can a CISC instruction set be RISC under such a definition? [4 marks]

Given a certain silicon budget (e.g. 106 transistors) compare and contrast, under the
above criterion, alternative ways of spending the excess over the (say) 104 transistor
cost of a simple load-store one-accumulator machine. You might find it helpful to
consider the various features and instructions of common processors. [12 marks]

This budget is sufficient to build most, but not all, of a VAX. Which parts would
you omit and how could you arrange to execute full VAX code? [4 marks]

4 Comparative Architectures

Compare and contrast possible implementations of instructions which

(a) load a single byte from memory [8 marks]

(b) store a single byte in memory [4 marks]

(c) move a sequence of n bytes from one address to another [8 marks]

For each implementation, indicate briefly whether it conforms to the RISC


philosophy, its effect on pipelining, and its likely efficiency compared with any
alternatives.

2
CST.93.7.3

5 Specification and Verification of Hardware

You are given components MUX, REG and COMP whose behaviour is defined by

MUX(sw,in1,in2,out) = (∀ t. out t = (sw t → in1 t | in2 t))

REG v (in,out) = (out 0 = v) ∧ (∀ t. out(t+1) = in t)

COMP(in1,in2,out) = (∀ t. out t = (in1 t < in2 t))

Use these to implement a device MAX that satisfies the specification

MAX(in,out) ⇒ (∀ t. out t = M ax in t)

where the function M ax is defined by

(M ax in 0 = in 0) ∧
(M ax in (n+1) = (M ax in n < in(n+1) → in(n+1) | M ax in n))

[10 marks]

Prove that your implementation meets its specification. [10 marks]

6 Specification and Verification of Hardware

Describe the simple switch model of CMOS transistors. [5 marks]

Draw a circuit diagram of a CMOS inverter and give a proof that it is correct in
the simple switch model. [2 + 3 marks]

Describe the unidirectional model of NMOS transistors. [5 marks]

Draw a circuit diagram of an NMOS inverter and give a proof that it is correct in
the unidirectional model. [2 + 3 marks]

3 [TURN OVER
CST.93.7.4

7 Numerical Analysis II

State a recurrence formula suitable for evaluating the sequence of Chebyshev


polynomials {Tn (x)} for an argument x. What are the starting values? [2 marks]

The error in Lagrange interpolation can be expressed in the form


n
f (n) (ζ) Y
f (x) − Ln−1 (x) = (x − xj )
n! j=1

for a suitable function f (x). Suggest a choice of the interpolation points {xj } which
tends to minimise this error over the interval [−1, 1]. [3 marks]

Hence justify and explain the method of economisation of a power series.


[5 marks]

In what sense is an economised power series a best approximation? [2 marks]

Suppose Pn (x) is a polynomial formed by truncating a power series after the term
in xn . Perform an economisation of the truncated power series

x2 x4
cosh x ' P4 (x) = 1 + 2! + 4! [5 marks]

Given that the maximum error in P4 (x) over [−1, 1] is approximately 0.0014,
compare the error in your economised polynomial with the error in P2 (x).
[3 marks]

4
CST.93.7.5

8 Numerical Analysis II

If B is a real symmetric n × n matrix such that z̄T Bz > 0 for any complex vector
z, prove that any eigenvalue λ of B is such that λ > 0. Hence prove that the
eigenvalues of AT A, where A is any real square matrix, are real and non-negative.
[3 marks]

Let P, Q be real n × n matrices and let kPk22 denote the maximum eigenvalue of
PT P. State Schwarz’s inequality for kPQk2 . Explain how this is modified if Q is
replaced by a vector of n elements. [3 marks]

Derive the condition number K for solution of the equations Ax = b. Hint: start
by setting e = x − x̂ where x̂ is an approximate solution. [5 marks]

Describe the singular value decomposition

A = UWVT

and explain how you would use it to solve the n equations Ax = b when W has
rank n. [5 marks]

How may the singular value decomposition help in solving the equations Ax = b
when A has rank < n? Use the case n = 4, W = diag{1, 10−3 , 10−20 , 0} to
illustrate your answer. (You may assume that machine epsilon ' 10−16 .)
[4 marks]

9 Graphics II

When scan-converting items for display, a Z-buffer is sometimes used to avoid some
sorting. Outline its operation and limitations. [12 marks]

The use of an A-buffer will improve matters. Explain why. [8 marks]

5 [TURN OVER
CST.93.7.6

10 Semantics

An imperative language has boolean expressions be, integer expressions ie, and
commands C, whose abstract syntax is specified by:

ie ::= n | X | ie + ie | ie − ie
be ::= b | ie = ie
C ::= skip | X := ie | C ; C | if be then C else C | while be do C

where b is true or false, n is any integer, and X ranges over a fixed set of variables.
Describe the operational semantics of the language in terms of inductively defined
evaluation relations

be, S ⇒ b ie, S ⇒ n and C, S ⇒ S 0

where S and S 0 are integer-valued functions on the set of variables. [5 marks]

In what sense are these evaluation relations deterministic? What is meant by the
assertion that two commands are semantically equivalent? [3 marks]

For any choice of be, C and C 0 , which of the following pairs of commands are
semantically equivalent and which are not? Justify your answer in each case.

(a) ((while be do C) ; C) and (if be then ((while be do C) ; C) else C)

(b) (C ; (while be do C)) and (if be then (while be do C) else C)

(c) (while be do (if be then C else C 0 )) and (while be do C)

[12 marks]

6
CST.93.7.7

11 Additional Topics

Describe, for a competent programmer, the decoding of a Lempel-Ziv data


compression code. Assume that the input is a stream of positive integers.
[10 marks]

Construct a Huffman Code for a seven-letter alphabet, given the following


approximate frequencies:

a b c d e f g
192 58 105 71 315 131 0 [4 marks]

Give an error-correcting code and explain how it works, excluding the simple
repetition code. [3+3 marks]

12 Additional Topics

Explain the distinction between Public- and Secret-Key cryptosystems. [4 marks]

Name an example of each type. [1+1 marks]

Is a One Time Pad a Public- or Secret-Key system? [1 mark]

Discuss the advantages and disadvantages of One Time Pads as compared with
alternative systems. When might One Time Pads be used and when should they
be avoided? [13 marks]

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy