Download presentation
Presentation is loading. Please wait.
Published byLucinda Wade Modified over 9 years ago
1
Mathematical Sciences at Oxford Stephen Drape
2
2 Who am I? Dr Stephen Drape Access and Schools Liaison Officer for Computer Science (Also a Departmental Lecturer) 8 years at Oxford (3 years Maths degree, 4 years Computer Science graduate, 1 year lecturer) Email: stephen.drape@comlab.ox.ac.uk
3
3 Five myths about Oxford There’s little chance of getting in It’s expensive College choice is very important Oxford is elitist You have to be very bright
4
4 Myth 1: Little chance of getting in False! Statistically: you have a 20–40% chance Admissions data for 2007 entry: ApplicationsAcceptances% Maths82817320.9% Maths & Stats1432920.3% Maths & CS521630.8% Comp Sci822429.3% Physics69517024.5% Chemistry50719037.5%
5
5 Myth 2: It’s very expensive False! Most colleges provide cheap accommodation for three years. College libraries and dining halls also help you save money. Increasingly, bursaries help students from poorer backgrounds. Most colleges and departments are very close to the city centre – low transport costs!
6
6 Myth 3: College Choice Matters False! If the college you choose is unable to offer you a place because of space constraints, they will pass your application on to a second, computer- allocated college. Application loads are intelligently redistributed in this way. Lectures are given centrally by the department as are many classes for courses in later years.
7
7 Myth 3: College Choice Matters However… Choose a college that you like as you have to live and work there for 3 or 4 years Look at accommodation & facilities offered. Choose a college that has a tutor in your subject.
8
8 Myth 4: Oxford is elitist False! Oxford has a large variety of students (state & independent, British & International, male & female) Tutors assess applicants based on ability and motivation It does not matter what your “background” is
9
9 Myth 5: You have to be bright True! We find it takes special qualities to benefit from the kind of teaching we provide. So we are looking for the very best in ability and motivation. A typical offer is 3 A grades at A-Level
10
10 Mathematical Science Subjects Mathematics Mathematics and Statistics Computer Science Mathematics and Computer Science All courses can be 3 or 4 years
11
11 Maths in other subjects For admissions, A-Level Maths is mentioned as a preparation for a number of courses: Essential: Computer Science, Engineering Science, Engineering, Economics & Management (EEM), Materials, Economics & Management (MEM), Materials, Maths, Medicine, Physics Desirable/Helpful: Biochemistry, Biology, Chemistry, Economics & Management, Experimental Psychology, History and Economics, Law, Philosophy, Politics & Economics (PPE), Physiological Sciences, Psychology, Philosophy & Physiology (PPP)
12
12 Admissions Process Fill in UCAS and Oxford form Choose a college or submit an “Open” Application Interview Test Based on common core A-Level Taken before the interview Interviews Take place over a few days Often have many interviews
13
13 Entrance Requirements Essential: A-Level Mathematics Recommended: Further Maths or a Science Note it is not a requirement to have Further Maths for entry to Oxford For Computer Science, Further Maths is perhaps more suitable than Computing or IT Usual offer is AAA
14
14 First Year Maths Course Algebra (Group Theory) Linear Algebra (Vectors, Matrices) Calculus Analysis (Behaviour of functions) Applied Maths (Dynamics, Probability) Geometry
15
15 Subsequent Years The first year consists of compulsory courses which act as a foundation to build on The second year starts off with more compulsory courses The reminder of the course consists of a variety of options which become more specialised In the fourth year, students have to study 6 courses from a choice of 40
16
16 Mathematics and Statistics The first year is the same as for the Mathematics course In the second year, there are some compulsory units on probability and statistics Options can be chosen from a wide range of Mathematics courses as well as specialised Statistics options Requirement that around half the courses must be from Statistics options
17
17 Computer Science Computer Science firmly based on Mathematics Mathematics and Computer Science Closer to a half/half split between CS and Maths Computer Science is part of the Mathematical Science faculty because it has a strong emphasis on theory
18
18 Computer Science Year 1 Year 2 Year 3 Year 4 MathematicsComputingProject work
19
19 Mathematics & Computer Science Year 1 Year 2 Year 3 MathematicsComputing Year 4 Project work
20
20 Some of the first year courses Functional Programming Design and Analysis of Algorithms Imperative Programming Digital Hardware Calculus Linear Algebra Logic and Proof Discrete Maths
21
21 Subsequent Years The second year is a combination of compulsory courses and options Many courses have a practical component Later years have a greater choice of courses Third and Fourth year students have to complete a project
22
22 Some Computer Science Options Compilers Programming Languages Computer Graphics Computer Architecture Intelligent Systems Machine Learning Lambda Calculus Computer Security Category Theory Computer Animation Linguistics Domain Theory Program Analysis Information Retrieval Bioinformatics Formal Verification
23
23 Useful Sources of Information Admissions: http://www.admissions.ox.ac.uk/ Mathematical Institute http://www.maths.ox.ac.uk/ Computing Laboratory: http://www.comlab.ox.ac.uk/ Colleges
24
24 What is Computer Science? It’s not about learning new programming languages. It is about understanding why programs work, and how to design them. If you know how programs work then you can use a variety of languages. It is the study of the Mathematics behind lots of different computing concepts.
25
25 Power We can use the power notation to write very large in a compact way. 3 5 = 3 £ 3 £ 3 £ 3 £ 3 = 243 How could we write a program to compute this? base exponent 3535
26
26 Writing a program for this Here’s a very simple program: This uses a technique called recursion
27
27 Number of multiplications So we’ve just seen that to work out 3 5 we need 5 multiplications. What about 3 25 ? Using the previous program, we would need 25 multiplications. But it is possible to compute this using only 7 multiplications!
28
28 Splitting Up the Exponent Split the exponent (power) into powers of 2. 25 = 1+8+16 = 2 0 + 2 3 + 2 4 and so 3 25 = 3 1 £ 3 8 £ 3 16 Now working out the powers: 1 £ 3 = 3 1 (keep)3 1 £ 3 1 = 3 2 3 2 £ 3 2 = 3 4 3 4 £ 3 4 = 3 8 (keep) 3 8 £ 3 8 = 3 16 (keep) So we have 7 multiplications in total
29
29 Setting up an algorithm We have three variables: y (which keeps the powers of 2 that we need) z (which works out the powers of 2) k (a counter to count down) Initially we set y = 1, z = base, k = exponent
30
30 The algorithm This algorithm is not written in any programming language – it is written in “pseudo-code” so that we can explain what is happening.
31
31 A real program This is written in a programming language called Haskell. It’s used throughout the Computer Science course at Oxford.
32
32 Try an example Let’s try an example and see how this algorithm works out 3 25. At the start, we take y=1, z=3 and k=25
33
33 Steps 1 starty=1z=3k=25 oddy=1 £ 3 =3 1 z=3 1 k=24 eveny=3 1 z=3 1 £ 3 1 = 3 2 k=12 eveny=3 1 z=3 2 £ 3 2 = 3 4 k=6 eveny=3 1 z=3 4 £ 3 4 = 3 8 k=3
34
34 Steps 2 k=6eveny=3 1 z=3 4 £ 3 4 = 3 8 k=3 oddy=3 1 £ 3 8 =3 9 z = 3 8 k=2 eveny=3 9 z=3 8 £ 3 8 = 3 16 k=1 oddy=3 9 £ 3 16 =3 25 z=3 16 k=0 doney = 3 25 7 multiplications
35
35 Comparison of number of steps Here’s a table showing the size of the power and the number of multiplications needed using our fast algorithm: Size of powersNumber of multiplications 105 257 1009 100015 1000000 (10 6 )22 10 12 52
36
36 So What? Many computer algorithms need to be able to work out powers efficiently. The RSA encryption algorithm needs to do calculations such as: For security, e and n need to be 2048 bits (which means bigger than 2 2048 ) which has over 600 digits.
37
37 Algorithm Design When designing algorithms, we have to consider a number of things: Our algorithm should be efficient – that is, where possible, it should not take too long or use too much memory. We should look at ways of improving existing algorithms. We may have to try a number of different approaches. We should make sure that our algorithms are correct.
38
38 An Interview Type Problem You have an urn which contains 23 white beans and 34 black beans. You take out two beans from the jar: if the beans are the same colour then you put a black bean (from a large pile of beans that you have) into the jar otherwise, you put a white bean into the jar You repeat this process until there is only one bean left. What colour is it?
39
39
40
40 Finding the Highest Common Factor Example: Find the HCF of 308 and 1001. 1) Find the factors of both numbers: 308 – [1,2,4,7,11,14,22,28,44,77,154,308] 1001 – [1,7,11,13,77,91,143,1001] 2) Find those in common [1,7,11,77] 3) Find the highest Answer = 77
41
41 Creating an algorithm For our example, we had three steps: 1) Find the factors 2) Find those factors in common 3) Find the highest factor in common These steps allow us to construct an algorithm.
42
42 Creating a program We are going to use a programming language called Haskell. Haskell is used throughout the Computer Science course at Oxford. It is very powerful as it allows you write programs that look very similar to mathematical equations. You can easily prove properties about Haskell programs.
43
43 Step 1 We need produce a list of factors for a number n – call this list factor(n). A simple way is to check whether each number d between 1 and n is a factor of n. We do this by checking what the remainder is when we divide n by d. If the remainder is 0 then d is a factor of n. We are done when d=n. We create factor lists for both numbers.
44
44 Function for Step 1
45
45 Step 2 Now that we have our factor lists, which we will call f1 and f2, we create a list of common factors. We do this by looking at all the numbers in f1 to see if they are in f2. We there are no more numbers in f1 then we are done. Call this function: common(f1,f2).
46
46 Function for Step 2
47
47 Step 3 Now that we have a list of common factors we now check which number in our list is the biggest. We do this by going through the list remembering which is the biggest number that we have seen so far. Call this function: highest(list).
48
48 Function for Step 3 If list is empty then return 0, otherwise we check whether the first member of list is higher than the rest of list.
49
49 Putting the three steps together To calculate the hcf for two numbers a and b, we just follow the three steps in order. So, in Haskell, we can define Remember that when composing functions, we do the innermost operation first.
50
50 Problems with this method Although this method is fairly easy to explain, it is quite slow for large numbers. It also wastes quite a lot of space calculating the factors of both numbers when we only need one of them. Can we think of any ways to improve this method?
51
51 Possible improvements Remember factors occur in pairs so that we actually find two factors at the same time. If we find the factors in pairs then we only need to check up to n. We could combine common and highest to find the hcf more quickly (this kind of technique is called fusion). Could use prime numbers.
52
52 A Faster Algorithm This algorithm was apparently first given by the famous mathematician Euclid around 300 BC.
53
53 An example of this algorithm hcf(308,1001) = hcf(308,693) = hcf(308,385) = hcf(308,77) = hcf(231,77) = hcf(154,77) = hcf(77,77) = 77 The algorithm works because any factor of both a and b is also a factor of a – b
54
54 Writing this algorithm in Haskell
55
55 An even faster algorithm hcf(1001,308)1001 = 3 × 308 + 77 = hcf(308,77) 308 = 4 × 77 = hcf(77,0) = 77
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.