Lecture 5 Flashcards
summarise P, NP, and NP-Complete.
The size of a problem is the number of bits required to represent its input.
Algorithm complexity is measured on how they scale with the problem size. Polynomial time problems(P) is when the algorithm runs in polynomial time for some constant c. A problem is in NP if (non deterministic polynomial time) if a solution can be checked in polynomial time. A problem is NP-complete if it is in NP and at least as hard as every other problem, if a problem like this was found to be in P then every problem in NP would be in P.
What is 3-SAT?
a sequence of binary variables and a set of clauses, each containing 3 literals, is there a truth assignment to the variables that make all clauses true.
What is the travelling salesman problem?
A sequence of vertices, a function from pairs or vertices to positive integers, and a parameter k, is there a path through the vertices such that each is visited at least once and the origin city is returned to and the total cost is less than K.
What is the vertex cover problem?
A graph G consisting of a sequence of vertices and a set of edges between unordered pairs of vertices, and a parameter K, is there a set K of fewer vertices such that every edge contains at least one vertex in the set?
What does it mean if a problem is fixed-parameter tractable?
If there is an algorithm whose complexity is O(f(K)n^C) where K is a parameter which is somewhat independent of the problem size n. Problems of this type can be efficiently solvable even for quite large values of n if the parameter is sufficiently small.
Why can NP problems be useful for public key cryptosystems?
The best public key cryptosystems would involve an NP-complete problem for which almost all instances are hard, a trap door function built around it that can only be opened by solving a random instance, and make sure it’s resistant to quantum attacks.
What is the subset sum problem?
A collection of positive weight and a positive integer S exist, find a subset of the weights which add to give S.
How can we convert an easy knapsack problem into a hard one? How can this be used for cryptosystems?
Start with a super increasing sequence of weights, so one in which a higher weight cannot be created from combining lower weights, choose M greater than the sum of all weights, and W so that the greatest common denominator of M and W is 1, compute vi = weight_i*W (mod M) for each weight, and then put them in sorted order (w’s), if someone doesn’t know M and W, knapsacks based on w’s will look hard, but otherwise will be easy.
To use for a cryptosystem, hide the easy weights and announce the hard weights, to encrypt the sender computes b . w, to decrypt modular multiplication is undone to get the super increasing context, which can be solved easily with a greedy solution. This will be faster than RSA, with a larger key size and message size.
Sadly, it is enough to find any multiplier and modulus which creates a super-increasing system, not the same one that was used.
How can signatures be handled with RSA?
RSA is quasi symmetric in that messages encoded with the private key could be decoded using the public key. Bob transmits a message which contains a section encrypted with his private key, Alice can then decrypt it using his public key.
How does an entropy attack occur on RSA?
Occasionally devices may have collisions in one of the two primes, this can lead to the channels being memorised, making them breakable (so now about 0.5% of keys in some measure are busted).