COMP 170 L2 Page 1 Review for Midterm 1 l Part I: Counting n L01-L03 l Part II: Number Theory and Cryptography n L04, L05.

Slides:



Advertisements
Similar presentations
1 Lect. 12: Number Theory. Contents Prime and Relative Prime Numbers Modular Arithmetic Fermat’s and Euler’s Theorem Extended Euclid’s Algorithm.
Advertisements

CSE 311 Foundations of Computing I Lecture 13 Number Theory Autumn 2012 CSE
CSE 20 DISCRETE MATH Prof. Shachar Lovett Clicker frequency: CA.
L1 Supplementary Notes Page 1 Selection Sort Comparison Counting.
CSC2110 Discrete Mathematics Tutorial 5 GCD and Modular Arithmetic
L2 Supplementary Notes Page : Recap l General Product Principle n For counting list l Counting Functions n Functions are lists l Function concepts.
COMP 170 L2 Page 1 Part 2 of Course Chapter 2 of Textbook.
6/20/2015 5:05 AMNumerical Algorithms1 x x1x
Inverses and GCDs Supplementary Notes Prepared by Raymond Wong
CSE 321 Discrete Structures Winter 2008 Lecture 8 Number Theory: Modular Arithmetic.
Discrete Structures for Computer Science Ruoming Jin MW 5:30 – 6:45pm Fall 2009 rm MSB115.
Lecture 3.2: Public Key Cryptography II CS 436/636/736 Spring 2012 Nitesh Saxena.
COMP 170 L2 Page 1. COMP 170 L2 Page 2 COMP 170 L2 L10: Intro to Induction l Objective n Introduce induction from proof-by-smallest-counter-example 
Great Theoretical Ideas in Computer Science.
L2 Supplementary Notes Page : Recap l Sum Principle n Applied to selection sort l Product Principle n Applied to matrix multiplication and.
Dan Boneh Intro. Number Theory Modular e’th roots Online Cryptography Course Dan Boneh.
CSE 321 Discrete Structures Winter 2008 Lecture 10 Number Theory: Primality.
CSE 311 Foundations of Computing I Lecture 12 Primes, GCD, Modular Inverse Spring
Fall 2002CMSC Discrete Structures1 Let us get into… Number Theory.
Software Security Seminar - 1 Chapter 11. Mathematical Background 발표자 : 안병희 Applied Cryptography.
Great Theoretical Ideas in Computer Science.
9/2/2015Discrete Structures1 Let us get into… Number Theory.
Introduction to Modular Arithmetic and Public Key Cryptography.
COMP 170 L2 Page 1 L05: Inverses and GCDs l Objective: n When does have an inverse? n How to compute the inverse? n Need: Greatest common dividers (GCDs)
Module :MA3036NI Cryptography and Number Theory Lecture Week 7
Midterm Review Cryptography & Network Security
YSLInformation Security -- Public-Key Cryptography1 Prime and Relatively Prime Numbers Divisors: We say that b  0 divides a if a = mb for some m, where.
Chinese Remainder Theorem Dec 29 Picture from ………………………
1 Network and Computer Security (CS 475) Modular Arithmetic and the RSA Public Key Cryptosystem Jeremy R. Johnson.
A Brief Summary for Exam 2 Subject Topics Number theory (sections ) –Prime numbers Definition Relative prime Fundamental theorem of arithmetic.
Lecture 6.1: Misc. Topics: Number Theory CS 250, Discrete Structures, Fall 2011 Nitesh Saxena.
Network and Computer Security (CS 475) Modular Arithmetic
CS Modular Division and RSA1 RSA Public Key Encryption To do RSA we need fast Modular Exponentiation and Primality generation which we have shown.
MA/CSSE 473 Day 08 Extended Euclid's Algorithm Modular Division Fermat's little theorem.
Tuesday’s lecture: Today’s lecture: One-way permutations (OWPs)
Introduction to Number Theory
Cryptography Lecture 14 Arpita Patra © Arpita Patra.
Ch04-Number Theory and Cryptography 1. Introduction to Number Theory Number theory is about integers and their properties. We will start with the basic.
CMSC250 S ECTIONS 0303 & 0304 M IDTERM R EVIEW Sri Kankanahalli Discussion 10: 9 March 2016 Office Hrs: Mon. and Wed. 4-6PM AVW 1112.
Chapter 4 With Question/Answer Animations 1. Chapter Motivation Number theory is the part of mathematics devoted to the study of the integers and their.
Number Theory Lecture 1 Text book: Discrete Mathematics and its Applications, 7 th Edition.
Great Theoretical Ideas in Computer Science.
MA/CSSE 473 Day 07 Extended Euclid's Algorithm Modular Division Fermat's little theorem intro.
COMP 170 L2 Page 1 Review for Midterm 2 Part II: Number Theory and Cryptography L06: RSA Part III: Logic L07, L08, L09 Part IV: Induction and Recurrence.
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett.
Dr Nazir A. Zafar Advanced Algorithms Analysis and Design Advanced Algorithms Analysis and Design By Dr. Nazir Ahmad Zafar.
Number Theory. Introduction to Number Theory Number theory is about integers and their properties. We will start with the basic principles of divisibility,
MA/CSSE 473 Day 07 Extended Euclid's Algorithm Modular Division
Mathematical Background for Cryptography: Modular arithmetic and gcd
Topic 12: Number Theory Basics (2)
Introduction to Cryptography
Lecture 3.2: Public Key Cryptography II
CSE 311 Foundations of Computing I
Number Theory and Modular Arithmetic
Numerical Algorithms x x-1
Great Theoretical Ideas in Computer Science
CS 280 Midterm Review.
Prime and Relatively Prime Numbers
Discrete Math for CS CMPSC 360 LECTURE 12 Last time: Stable matching
Introduction to Discrete Mathematics
Applied Symbolic Computation (CS 300) Modular Arithmetic
Systems Architecture I
CSE 311: Foundations of Computing
Applied Symbolic Computation (CS 300) Modular Arithmetic
Algorithmic Number Theory and Cryptography (CS 303) Modular Arithmetic
Applied Symbolic Computation (CS 300) Modular Arithmetic
Applied Symbolic Computation (CS 300) Modular Arithmetic
Applied Symbolic Computation (CS 300) Modular Arithmetic
Number Theory.
Cryptography Lecture 16.
Presentation transcript:

COMP 170 L2 Page 1 Review for Midterm 1 l Part I: Counting n L01-L03 l Part II: Number Theory and Cryptography n L04, L05

COMP 170 L2 Counting l Why counting? Page 2

COMP 170 L2 Counting Overview l Principles n Sum principle, Product Principle, Bijection Principle l Objects to count n Lists, functions, subsets, permutations, partitions Page 3

COMP 170 L2 Page 4 Sum Principle

COMP 170 L2 Page 5 Product Principle l Si and Sj are disjoint, |Si| = n l S = S1 U S2 U … U Sm l |S| = m |Si| = mn

COMP 170 L2 Page 6 Product Principle

COMP 170 L2 Page 7 Bijection Principle

COMP 170 L2 Counting Overview l Principles n Sum principle, Product Principle, Bijection Principle l Objects to count n Lists, functions, permutations, subsets, partitions Page 8

COMP 170 L2 Page 9 Counting Lists

COMP 170 L2 Page 10 Counting Functions

COMP 170 L2 Counting Functions Page 11

COMP 170 L2 Page 12 Counting Permutations l Number of k-element permutations l Number of permutations of a set of size n

COMP 170 L2 Page 13 k-element subsets/k-elemen permutations

COMP 170 L2 Counting Subsets Page 14

COMP 170 L2 Page 15 Counting Subsets

COMP 170 L2 Avoid Double Counting Page 16 l Exco Members: Year 1: 4; Year 2: 5; Year 3: 3 l WRONG ANSWER: l First choose 1 from each year l Then pick 3 from remaining 9 members l Answer

COMP 170 L2 Page 17 Counting Partitions/Labelings

COMP 170 L2 Page 18 Review for Midterm 1 l Part I: Counting n L01-L03 l Part II: Number Theory and Cryptography n L04, L05

COMP 170 L2 Part II of Course: Objective Page 19 n Show how to make e-commerce secure using Number theory. n Three logic lectures: L04-L06 n L04-05 covered in Midterm 1

COMP 170 L2 L04-L05 Overview l Addition and multiplication mod n n Basic properties l Multiplicative inverse n GCD n Extended GCD algorithm l Introduction to cryptography Page 20

COMP 170 L2 Modular Arithmetic Page 21

COMP 170 L2 Euclid’s Division Theorem l Proved: Page 22 l Proof technique l Proof by contradiction l Proof by smallest counter example

COMP 170 L2 Basic Properties Page 23

COMP 170 L2 L04-L05 Overview l Addition and multiplication mod n n Basic properties l Multiplicative inverse n GCD n Extended GCD algorithm l Introduction to cryptography Page 24

COMP 170 L2 Link to GCD Page 25

COMP 170 L2 GCD Algorithm Page 26

COMP 170 L2 Page 27 The Extended GCD Algorithm

COMP 170 L2 Multiplicative Inverse Page 28 l a has multiplicative inverse in Zn iff gcd(a, n) =1 l In that case, inverse of a = x mod n.

COMP 170 L2 L04-L05 Overview l Addition and multiplication mod n n Basic properties l Multiplicative inverse n GCD n Extended GCD algorithm l Introduction to cryptography Page 29

COMP 170 L2 Introduction to Cryptography