In computational complexity theory, a **complexity class** is a set of problems of related resource-based complexity. A typical complexity class has a definition of the form:

- the set of problems that can be solved by an abstract machine M using O(f(
*n*)) of resource R, where*n*is the size of the input.

For example, the class **NP** is the set of decision problems whose solutions can be determined by a non-deterministic Turing machine in polynomial time, while the class **PSPACE** is the set of decision problems that can be solved by a deterministic Turing machine in polynomial space.

The simpler complexity classes are defined by the following factors:

- The type of computational problem: The most commonly used problems are decision problems. However, complexity classes can be defined based on function problems (an example is
**FP**), counting problems (e.g.**#P**), optimization problems, promise problems, etc. - The model of computation: The most common model of computation is the deterministic Turing machine, but many complexity classes are based on nondeterministic Turing machines, boolean circuits, quantum Turing machines, monotone circuits, etc.
- The resource (or resources) that are being bounded and the bounds: These two properties are usually stated together, such as "polynomial time", "logarithmic space", "constant depth", etc.

Many complexity classes can be characterized in terms of the mathematical logic needed to express them; see descriptive complexity.

Bounding the computation time above by some concrete function *f*(*n*) often yields complexity classes that depend on the chosen machine model. For instance, the language {*xx* | *x* is any binary string} can be solved in linear time on a multi-tape Turing machine, but necessarily requires quadratic time in the model of single-tape Turing machines. If we allow polynomial variations in running time, Cobham-Edmonds thesis states that "the time complexities in any two reasonable and general models of computation are polynomially related" (Goldreich 2008, Chapter 1.2). This forms the basis for the complexity class P, which is the set of decision problems solvable by a deterministic Turing machine within polynomial time. The corresponding set of function problems is FP.

The Blum axioms can be used to define complexity classes without referring to a concrete computational model.

Read more about Complexity Class: Important Complexity Classes, Reduction, Closure Properties of Classes, Relationships Between Complexity Classes

### Other articles related to "complexity class, complexity, class":

**Complexity Class**es - Hierarchy Theorems

... For the

**complexity**classes defined in this way, it is desirable to prove that relaxing the requirements on (say) computation time indeed defines a bigger set of problems ... Thus there are pairs of

**complexity**classes such that one is properly included in the other ... The time and space hierarchy theorems form the basis for most separation results of

**complexity**classes ...

... In computational

**complexity**theory, a computational problem is complete for a

**complexity class**if it is, in a technical sense, among the "hardest" (or "most expressive") problems in the

**complexity class**... More formally, a problem p is called hard for a

**complexity class**C under a given type of reduction, if there exists a reduction (of the given type) from any problem in C to p ... If a problem is both hard for the

**class**and a member of the

**class**, it is complete for that

**class**(for that type of reduction) ...

... In computational

**complexity**theory, a natural proof is a certain kind of proof establishing that one

**complexity class**differs from another one ... Specifically, natural proofs prove lower bounds on the circuit

**complexity**of boolean functions ... Rudich show that these proofs cannot separate certain

**complexity**classes ...

**Complexity Class**

... The

**complexity class**of decision problems that have Las Vegas algorithms with expected polynomial runtime is ZPP ... Namely the

**class**RP consists of all decision problems for which a randomized polynomial-time algorithm exists that always answers correctly when the correct answer is "no ...

... in polynomial time that is, if they lie in the

**complexity class**P ... of functions" is one of the earliest mentions of the concept of the

**complexity class**P, consisting of problems decidable in polynomial time ... Cobham theorized that this

**complexity class**was a good way to describe the set of feasibly computable problems ...

### Famous quotes containing the words class and/or complexity:

“Money couldn’t buy friends, but you got a better *class* of enemy.”

—Spike Milligan (b. 1918)

“The price we pay for the *complexity* of life is too high. When you think of all the effort you have to put in—telephonic, technological and relational—to alter even the slightest bit of behaviour in this strange world we call social life, you are left pining for the straightforwardness of primitive peoples and their physical work.”

—Jean Baudrillard (b. 1929)