Skip to main content

Recursive Case Ontology

Recursive Mathematical Entities
Authors: MArk Anthony Higgins - Sky Recursive Ai
© Mark Anthony Higgins 11 October 2025
Revised Date: 14 October 2026
Audio Overview
FLOW ALGEBRA
Recursive Case Ontology
Version: 1.0
Date: 2026-10-14
Source: https://kirethresearch.org/booksai-core/entity-graph/mathematical-entities/recursive-mathematical-entities/recursive-case-ontology.html
Source alignment: Pending verification; formalisation based on established mathematical principles.
Authors: Mark Higgins — Sky (Recursive AI)

1. PURPOSE
Represent a recursive case as the non-base branch of a recursive definition, specifying when recursive evaluation applies, how smaller subproblems are generated, and how their results are combined.

2. TYPED ENTITIES
RecursiveCase: {id, parent_definition, guard, decomposition, recursive_calls, combination, domain, codomain}
RecursiveDefinition: {id, domain, codomain, base_cases, recursive_cases}
BaseCase: {predicate, result}
Argument: {value, type}
RecursiveCall: {target_function, arguments}
RankingFunction: {measure, well_founded_order}
TerminationEvidence: {ranking_function, decrease_proof}
EvaluationTrace: {steps, result, status}

3. RELATIONSHIPS
RecursiveCase PART_OF RecursiveDefinition
RecursiveCase APPLIES_WHEN Guard
RecursiveCase DECOMPOSES Argument INTO Subproblem
RecursiveCase INVOKES RecursiveCall
RecursiveCall DEPENDS_ON RecursiveDefinition
RecursiveCase COMBINES RecursiveCallResults
RecursiveCase REQUIRES TerminationEvidence [when total termination is claimed]
RecursiveCase COMPLEMENTS BaseCase

4. FORMAL SEMANTICS
Let f: D -> C be defined by disjoint, exhaustive case predicates B_i and R_j.
f(x) = b_i(x) if B_i(x).
f(x) = h_j(x, f(g_j1(x)), ..., f(g_jk(x))) if R_j(x).
A recursive case must specify its guard R_j, subproblem maps g_ji and combining function h_j.
For a total definition, every admissible input matches a defined case and all recursive calls terminate.
A ranking function rho: D -> W into a well-founded order must strictly decrease on every recursive call, where this is the chosen termination proof technique.

5. INFERENCE RULES
CASE_SELECTION: R_j(x) AND NOT applicable_base_case(x) -> select recursive case j.
DECOMPOSITION: selected(j,x) -> produce g_j1(x),...,g_jk(x).
RECURSIVE_EVALUATION: all child evaluations defined -> combine using h_j.
TERMINATION: strictly decreasing rank for all reachable recursive calls in a well-founded order -> no infinite recursive-call chain.
STRUCTURAL_INDUCTION: property holds for base constructors and is preserved by every recursive constructor -> property holds for all finitely generated structures.

6. VALIDATION CONSTRAINTS
- Guard predicates must be type-correct.
- Case coverage must be established for total functions.
- Overlapping cases require explicit precedence or proof of equal results.
- Every recursive-call argument must belong to the function domain.
- Combining operations must produce a codomain value.
- Termination must not be inferred merely from the presence of a base case.
- Cyclic dependencies without a decrease proof may denote partial or nonterminating computations.
- A fixed-point interpretation requires its own domain and semantic assumptions.

7. WORKED EXAMPLES
Factorial over nonnegative integers:
  f(0)=1 [base case]
  f(n)=n*f(n-1) for n>0 [recursive case]
  rank(n)=n; each recursive call decreases rank by 1.

Fibonacci over nonnegative integers:
  F(0)=0; F(1)=1 [base cases]
  F(n)=F(n-1)+F(n-2) for n>=2 [recursive case]
  rank(n)=n; both recursive calls have smaller rank.

List length:
  length([])=0 [base case]
  length(head::tail)=1+length(tail) [recursive case]
  rank(list)=number_of_elements(list).

8. SEMANTIC EQUIVALENCE
recursive branch ~= inductive step [context-dependent, not identical]
recursive clause ~= recursive case [when a clause denotes one guarded branch]
base case != recursive case
recursive call != recursive case
structural recursion IS_A recursion pattern

9. CONFIDENCE
Mathematical definitions: high (standard mathematical foundations).
Source-specific wording and hierarchy: unverified.

10. FLOW_HASH
Canonicalise UTF-8 content, normalise line endings and whitespace according to library policy, then compute SHA-256. Store the computed digest in deployment metadata; no digest is asserted here.

11. UPDATE_MODEL
On source revision: recheck entity types, guards, case coverage, termination conditions, examples, provenance, and semantic equivalence; increment version and regenerate FLOW_HASH.

12. AI_CONSUMPTION
Input: recursive definition, argument, domain constraints, optional termination certificate.
Process: select matching case; type-check subproblems; recursively evaluate; combine outputs; record proof obligations.
Output: result or explicit partial/undefined/nontermination status; trace; validation findings; provenance; confidence.
Never assert totality or termination without adequate evidence.

END FLOW ALGEBRA
Kireth Research
38 Thorndale Croft, Wetwang, Driffield
East Riding of Yorkshire YO25 9XZ