A topic in the Open Knowledge Graph — a free, open map of 15,290 topics and the order to learn them in.

PTAS and FPTAS

Research Depth 106 in the knowledge graph I know this Set as goal
535prerequisites beneath it
See this on the map →
Approximation Algorithms (LP Relaxation and Primal-Dual)NP-Completeness and Cook-Levin Theorem+1 more
ptas fptas approximation-schemes knapsack

Core Idea

A Polynomial-Time Approximation Scheme (PTAS) is a family of algorithms parameterized by epsilon > 0, where each algorithm runs in polynomial time in n (for fixed epsilon) and returns a (1+epsilon)-approximate solution. An FPTAS (Fully Polynomial-Time Approximation Scheme) is stronger: the running time is polynomial in both n and 1/epsilon. The knapsack problem admits an FPTAS via scaling and rounding item profits, then applying dynamic programming — running in O(n2/epsilon) time. PTAS existence versus FPTAS existence is a meaningful distinction: not all problems with a PTAS have an FPTAS, and the FPTAS exclusion is connected to strong NP-hardness. Problems like Euclidean TSP admit a PTAS (Arora, Mitchell) but are unlikely to have an FPTAS.

Explainer

Approximation algorithms give worst-case guarantees — a 2-approximation always returns a solution within a factor of 2 of optimal. But for many applications, you want to tune the accuracy: a 1.01-approximation for a shipping route, a 1.001-approximation for a portfolio allocation. Approximation schemes provide this tunability by parameterizing the accuracy with epsilon.

A PTAS is a family of algorithms indexed by epsilon > 0. For each epsilon, the algorithm runs in time polynomial in n (the input size) and returns a solution within factor (1+epsilon) of optimal. The catch is that the polynomial's degree or leading constant can depend on epsilon — a running time of O(n1/epsilon) qualifies as a PTAS because for epsilon = 0.1 it is O(n10), which is polynomial. But for epsilon = 0.001 it is O(n1000), which is technically polynomial but practically useless. An FPTAS removes this catch: the running time must be polynomial in both n and 1/epsilon, like O(n2/epsilon) or O(n3/epsilon2).

The knapsack FPTAS is the canonical example. The standard DP for knapsack runs in O(nP) time where P is the total profit — pseudopolynomial because P can be exponential in the input encoding. The FPTAS rescales profits by dividing by K = epsilon * p_max / n, effectively reducing the profit resolution. Rounding down to integers loses at most K profit per item, and with at most n items, the total loss is at most nK = epsilon * p_max <= epsilon * OPT. The scaled DP table has dimensions n by n/epsilon, giving O(n2/epsilon) time. You trade a controlled amount of precision for a massive reduction in running time — from pseudopolynomial to fully polynomial.

The existence of an FPTAS is tied to the number-theoretic structure of the problem. Strongly NP-hard problems — those that remain NP-hard even when all numbers are polynomially bounded — cannot have FPTAS unless P = NP, because an FPTAS would solve the bounded case exactly. This is why knapsack (weakly NP-hard) has an FPTAS but bin packing (strongly NP-hard) does not. Problems like Euclidean TSP occupy an intermediate position: they admit a PTAS (using geometric structure) but the running time's dependence on 1/epsilon is exponential, and this is believed to be inherent. The PTAS / FPTAS / no-PTAS hierarchy provides a refined classification of NP-hard optimization problems by their approximability.

Practice Questions 4 questions

Prerequisite Chain

Understanding ZeroThe Number ZeroCounting to FiveCounting to 10Counting to 20Counting a Set of Objects Up to 20Cardinality: The Last Number CountedMatching Numerals to QuantitiesSubitizing Small QuantitiesAddition Within 10Number Bonds to 10Addition Within 20Doubles and Near DoublesDoubles Facts Within 10Near Doubles Facts Within 20Mental Math Strategies for AdditionMental Math: Adding and Subtracting TensAddition Within 100Repeated Addition as MultiplicationMultiplication as Equal GroupsMultiplication: ArraysBasic Multiplication Facts (0s, 1s, 2s, 5s, 10s)Multiplication Facts Within 100Division as Equal SharingDivision as Grouping (Measurement Division)Division: Grouping (Repeated Subtraction) ModelDivision: Fair Sharing ModelDivision as Equal SharingDivision as GroupingBasic Division FactsDivision Facts Within 100Multiplication and Division Fact FamiliesRelationship Between Multiplication and DivisionDivision Facts as Inverse of MultiplicationRemainders and Quotients in DivisionDivision Word ProblemsMulti-Step Word ProblemsSolving Multi-Step Word ProblemsMultiplication Word ProblemsDivision Word ProblemsIntroduction to Long DivisionFactors and MultiplesPrime and Composite NumbersEquivalent FractionsRelating Fractions and DecimalsDecimal Place ValueIntegers and the Number LineComparing and Ordering IntegersAbsolute ValueAdding IntegersSubtracting IntegersMultiplying IntegersIntroduction to ExponentsOrder of OperationsInteger Order of OperationsVariable ExpressionsThe Distributive PropertyVariables and Expressions ReviewIntroduction to PolynomialsAdding and Subtracting PolynomialsMultiplying PolynomialsFactorialPermutationsCombinationsCounting Principles: Addition and Multiplication RulesIntroduction to Graph TheoryPropositional Logic FoundationsLogical EquivalencesBoolean AlgebraBoolean Type and Truth ValuesComparison Operators and Boolean TestsLogical Operators and Boolean AlgebraBoolean Algebra and Fundamental LawsLogic Gates FundamentalsImplementing Boolean Functions with GatesKarnaugh Map SimplificationCombinational Circuit DesignFlip-Flops and LatchesFinite State Machines (FSMs)Deterministic Finite Automata (DFA)Nondeterministic Finite Automata (NFA)Two-Way Finite AutomataNFA to DFA Conversion (Subset Construction)DFA Properties and Minimization AlgorithmsRegular Languages: Definition and CharacterizationContext-Free Grammars (CFGs)Pushdown Automata (PDA)Equivalence of CFGs and Pushdown AutomataClosure Properties of Context-Free LanguagesLimitations of Context-Free LanguagesPumping Lemma for Context-Free LanguagesTuring MachinesVariants of Turing Machines and EquivalenceNondeterministic Time Complexity and NPThe P vs. NP ProblemComplexity Class P: Polynomial TimeComplexity Class NP: Nondeterministic Polynomial TimeNP-Completeness and Cook-Levin TheoremThe Cook-Levin TheoremBoolean Satisfiability, Cook-Levin, and Reductions3-SAT and k-SAT VariantsPartition and Subset Sum ProblemsVertex Cover and Clique ProblemsApproximation Algorithms and Approximation RatiosHardness of ApproximationApproximation Algorithms (LP Relaxation and Primal-Dual)PTAS and FPTAS

Longest path: 107 steps · 535 total prerequisite topics

Prerequisites (3)

Leads To (0)

No topics depend on this one yet.