Skip to content
← All questions

How do you write the approximation guarantee formally using C, C*, and rho(n)?

For minimization problems, the guarantee is C≤ρ(n)⋅C∗C \leq \rho(n) \cdot C^*. For maximization problems, it is C≥C∗ρ(n)C \geq \frac{C^*}{\rho(n)}.

Conditions

  • C is the algorithm-produced cost.
  • C* is the true optimal cost.
  • rho(n) is the approximation bound.

Reasoning, step by step

  1. Identify the problem type (minimization or maximization).
  2. Define C, C*, and rho(n).
  3. Apply the appropriate inequality based on the problem type.

Example

The narrator states: "For minimization problems, our cost C is always less than or equal to our bound multiplied by the optimal cost C star." and "For maximization problems, it's just flipped. Our score is at least the optimal score divided by that bound."

Common misconceptions

  • Using the same inequality for both minimization and maximization.
  • Forgetting that rho(n) depends on the input size n.

Watch the explanation

Connected concepts

Explore next

Related questions

Answers are generated from source material and independently checked. Consult the original video or creator if something is unclear.