Docsity

Analysis of Algorithms, Schemes and Mind Maps of Discrete Mathematics

Toggle sidebar
bg1
Strict Algorithmic Property Dependencies & Paradigm Routing
1 Core Properties: Generic to Specific Definitions
Algorithms are classified by evaluating problem properties in a strict logical sequence. The existence of
higher-level optimization properties strictly depends on foundational structural properties.
1.1 1. Decomposability (The Root Property)
Generic: The global problem can be divided into smaller instances of the exact same problem type.
Specific: A problem Pover input size Nevaluates via a function gof subproblems P1(n1),. . . , Pk(nk)
where ni< N.
Real Example: Finding the maximum value in an array A[0..N] decomposes into finding the maximum
of A[0..N/2] and A[N/2..N ].
Influence: If a problem lacks Decomposability, it mathematically cannot possess Independent Subprob-
lems, Overlapping Subproblems, Optimal Substructure, or the Greedy Choice Property.
1.2 2. State Independence (Markov Property & Resource Independence)
Generic: Solving one subproblem does not restrict the state, constraints, or available resources of
another subproblem within the same global execution.
Specific: The feasible solution space Ω(P2) remains constant regardless of the specific solution s1∈
Ω(P1) chosen. The optimal future cost from state Stdepends solely on the parameters of St, not the
historical sequence S0. . . St−1.
Real Example: In Mergesort, sorting the left half does not consume integers or alter array indices
required to sort the right half.
Influence: If subproblems are dependent (e.g., they compete for unvisited nodes in the Longest Simple
Path problem), the problem strictly cannot possess Optimal Substructure.
1.3 3. Optimal Substructure
Generic: The strictly optimal solution to a global problem is mathematically formed by combining the
optimal solutions of its independent subproblems.
Specific: Let OP T (X) be the optimal solution value for state X.
OP T (X) = min
Y∈neighbors(X){cost(X, Y )+OPT(Y)}
Real Example: In the Shortest Path problem, if the globally shortest path from Ato Cpasses through
B, the segment A→Bis strictly the shortest possible path to B.
Influence: If true, it guarantees that localized exact solutions can be synthesized into a global exact
solution. If false, combining local optima may yield an invalid or sub-optimal global state.
1.4 4. Overlapping Subproblems
Generic: The decomposition tree requires the evaluation of the exact same subproblem state multiple
times across different recursive branches.
Specific: In the subproblem dependency Directed Acyclic Graph (DAG), at least one node representing
a computational state has an in-degree strictly greater than 1.
Real Example: In computing the Fibonacci sequence, F(N) and F(N−1) both independently require
the computation of F(N−2).
Influence: Strictly dictates computational efficiency. If present alongside Optimal Substructure, it
enables caching (Memoization/Tabulation).
1
pf3
pf4

Partial preview of the text

Download Analysis of Algorithms and more Schemes and Mind Maps Discrete Mathematics in PDF only on Docsity!

Strict Algorithmic Property Dependencies & Paradigm Routing

1 Core Properties: Generic to Specific Definitions

Algorithms are classified by evaluating problem properties in a strict logical sequence. The existence of higher-level optimization properties strictly depends on foundational structural properties.

1.1 1. Decomposability (The Root Property)

Generic: The global problem can be divided into smaller instances of the exact same problem type. Specific: A problem P over input size N evaluates via a function g of subproblems P 1 (n 1 ),... , Pk(nk) where ni < N. Real Example: Finding the maximum value in an array A[0..N ] decomposes into finding the maximum of A[0..N/2] and A[N/ 2 ..N ]. Influence: If a problem lacks Decomposability, it mathematically cannot possess Independent Subprob- lems, Overlapping Subproblems, Optimal Substructure, or the Greedy Choice Property.

1.2 2. State Independence (Markov Property & Resource Independence)

Generic: Solving one subproblem does not restrict the state, constraints, or available resources of another subproblem within the same global execution. Specific: The feasible solution space Ω(P 2 ) remains constant regardless of the specific solution s 1 ∈ Ω(P 1 ) chosen. The optimal future cost from state St depends solely on the parameters of St, not the historical sequence S 0... St− 1. Real Example: In Mergesort, sorting the left half does not consume integers or alter array indices required to sort the right half. Influence: If subproblems are dependent (e.g., they compete for unvisited nodes in the Longest Simple Path problem), the problem strictly cannot possess Optimal Substructure.

1.3 3. Optimal Substructure

Generic: The strictly optimal solution to a global problem is mathematically formed by combining the optimal solutions of its independent subproblems. Specific: Let OP T (X) be the optimal solution value for state X.

OP T (X) = min Y ∈neighbors(X)

{cost(X, Y ) + OP T (Y )}

Real Example: In the Shortest Path problem, if the globally shortest path from A to C passes through B, the segment A → B is strictly the shortest possible path to B. Influence: If true, it guarantees that localized exact solutions can be synthesized into a global exact solution. If false, combining local optima may yield an invalid or sub-optimal global state.

1.4 4. Overlapping Subproblems

Generic: The decomposition tree requires the evaluation of the exact same subproblem state multiple times across different recursive branches. Specific: In the subproblem dependency Directed Acyclic Graph (DAG), at least one node representing a computational state has an in-degree strictly greater than 1. Real Example: In computing the Fibonacci sequence, F (N ) and F (N − 1) both independently require the computation of F (N − 2). Influence: Strictly dictates computational efficiency. If present alongside Optimal Substructure, it enables caching (Memoization/Tabulation).

1.5 5. Greedy Choice Property

Generic: A locally optimal choice is mathematically guaranteed to be a component of the global opti- mum without requiring evaluation of alternative subproblems (no lookahead or backtracking). Specific: Often structurally guaranteed by Matroids. A sequence of localized optimal choices ci directly yields OP T (P ). Real Example: In Dijkstra’s Algorithm, finalizing the unvisited node with the lowest cumulative dis- tance is mathematically guaranteed to be correct because strictly positive edge weights prevent future paths from discovering a shorter route. Influence: Overrides the need for Dynamic Programming. If present, the algorithm only needs to track a single optimal path rather than evaluating a DAG of subproblems.

4 The Algorithmic Paradigm Dependency Graph

This Directed Acyclic Graph defines the exact mathematical routing. A problem flows from the root through the logical gates defined by its properties, terminating at the strictly correct algorithmic paradigm.

  1. Decomposability (^) Brute Force Iteration
  2. State Independence (Markov Property)

Backtracking (State-Dependent Search)

  1. Optimal Substructure (^) (Memoization of Values Fails)Backtracking / Brute Force
  2. Greedy Choice Property Greedy Algorithm

Divide & Conquer 5. Overlapping Subproblems Dynamic Programming

  • Monotonic Bounds

Branch & Bound

No

Yes

No

Yes

Yes

No

Yes

Yes

No

No Yes

but OptSub = No,^ If Overlap = Yes Caching Values Fails

Figure 1: Strict logical routing of problem properties to algorithmic paradigms.