Skip to main content

Marginal Probability Ontology

Probability Entities
Authors: MArk Anthony Higgins - Sky Recursive Ai
© Mark Anthony Higgins 11 October 2025
Revised Date: 13 October 2026
Audio Overview
FLOW ALGEBRA
Marginal Probability Ontology
Version: 1.0
Date: 2026-10-13
Source: https://kirethresearch.org/booksai-core/entity-graph/mathematical-entities/probability-entities/marginal-probability-ontology-2.html
Authors: Mark Higgins — Sky (Recursive AI)
Project: Kireth Semantic Library | https://kirethresearch.org

1. PURPOSE
Represent marginal probability as the probability law of a subset of random variables obtained from a joint probability law by projecting away other variables. Provide typed entities, precise conditions, executable-style inference rules, validation and AI consumption metadata.

2. ENTITY TYPES
ProbabilitySpace := (Omega: Set, F: SigmaAlgebra(Omega), P: ProbabilityMeasure(F))
RandomVariable[T] := measurable mapping Omega -> T
RandomVector[T1,...,Tn] := tuple of random variables
JointLaw := ProbabilityMeasure(ProductMeasurableSpace)
MarginalLaw[T] := ProbabilityMeasure(T)
Projection := measurable mapping ProductSpace -> ComponentSpace
DiscretePMF := nonnegative mass function summing to 1
ContinuousDensity := nonnegative integrable function integrating to 1
Event := measurable subset of sample space

3. CORE DEFINITIONS
Let (X,Y) be a random vector with joint law mu_XY.
mu_X(A) := mu_XY(A x S_Y), for every measurable A subset S_X.
mu_Y(B) := mu_XY(S_X x B), for every measurable B subset S_Y.
Equivalently, mu_X = (pi_X)_# mu_XY (pushforward by projection pi_X).
For an n-dimensional vector, a marginal on index set I is the pushforward under coordinate projection pi_I.

4. DISCRETE RULES
p_X(x) = sum_y p_XY(x,y), for countable support and nonnegative mass.
p_Y(y) = sum_x p_XY(x,y).
For a finite n-way table, sum all axes not retained.
Sum_x p_X(x) = 1; p_X(x) >= 0.
Example: p_XY(0,0)=0.1; p_XY(0,1)=0.2; p_XY(1,0)=0.3; p_XY(1,1)=0.4.
Then p_X(0)=0.3, p_X(1)=0.7; p_Y(0)=0.4, p_Y(1)=0.6.

5. CONTINUOUS RULES
If the joint law admits a density f_XY with respect to product Lebesgue measure:
f_X(x) = integral_{S_Y} f_XY(x,y) dy (almost everywhere).
f_Y(y) = integral_{S_X} f_XY(x,y) dx (almost everywhere).
For mixed or singular distributions, use measure-theoretic pushforward rather than assuming a joint density exists.
Tonelli's theorem justifies integrating nonnegative joint densities; Fubini's theorem applies under suitable integrability conditions.

6. RELATIONSHIPS
MarginalLaw --DERIVED_FROM--> JointLaw
MarginalLaw --PROJECTS_ONTO--> RandomVariable
JointLaw --DESCRIBES--> RandomVector
Projection --PUSHES_FORWARD--> JointLaw
ConditionalLaw --COMBINES_WITH--> ConditioningMarginal
Independence --FACTORISES--> JointLaw

7. INFERENCE RULES
RULE MARGINAL_DISCRETE:
  IF valid_joint_pmf(pXY) AND finite_or_countable_support(Y)
  THEN pX(x) := SUM_y pXY(x,y).
RULE MARGINAL_CONTINUOUS:
  IF joint_density_exists(fXY)
  THEN fX(x) := INTEGRAL_y fXY(x,y) dy, almost_everywhere.
RULE MARGINAL_MEASURE:
  IF joint_law(muXY) AND measurable_projection(piX)
  THEN muX := PUSHFORWARD(muXY, piX).
RULE JOINT_FROM_CONDITIONAL:
  IF conditional_kernel(K_Y_given_X) AND marginal_law(muX)
  THEN muXY(A x B) := INTEGRAL_A K_Y_given_X(x,B) muX(dx).
RULE INDEPENDENCE:
  IF X_independent_Y
  THEN muXY = muX PRODUCT_MEASURE muY.
RULE CONSISTENCY:
  IF marginalise(muXYZ, [X,Y]) = muXY
  THEN marginalise(muXY, [X]) = marginalise(muXYZ, [X]).

8. SEMANTIC DISTINCTIONS
Marginal probability: unconditional probability of selected variable(s) derived from a joint law.
Conditional probability: probability given another event or variable; not synonymous with marginal probability.
Joint probability: simultaneous law of multiple variables; not synonymous with marginal probability.
Marginalisation: summation, integration or pushforward operation; not conditioning.
Independence: a special factorisation property, not required for marginalisation.
A marginal alone does not determine the joint dependence structure.

9. VALIDATION
CHECK joint measure is nonnegative, normalised and countably additive.
CHECK projection is measurable and target spaces are well typed.
CHECK discrete probabilities sum to one within numerical tolerance.
CHECK density nonnegative almost everywhere and integrates to one.
CHECK marginal output is normalised and nonnegative.
CHECK retained axes and eliminated axes are disjoint and cover intended coordinates.
CHECK numerical integration errors and finite precision are reported.
CHECK conditional-to-joint reconstruction includes a valid conditional kernel and conditioning marginal.

10. CONFIDENCE AND PROVENANCE
CONFIDENCE: 1.0 for mathematically proven transformations under stated assumptions; otherwise annotate approximation error and evidence.
PROVENANCE: preserve source joint law, selected coordinates, integration/summation method, assumptions and numerical precision.
SEMANTIC_EQUIVALENCE: summing out, integrating out and projection pushforward express the same marginalisation concept in their respective valid domains.

11. FLOW HASH AND UPDATE MODEL
FLOW_HASH: SHA-256 of canonical UTF-8 serialisation of ontology identifier, version, definitions, relationships and rules; compute at publication time (no fabricated digest).
UPDATE_MODEL: semantic-version changes; record additions, corrections, deprecated relationships, timestamps and source provenance; recompute hash after changes.

12. AI CONSUMPTION
INPUT: joint law or joint PMF/density, measurable spaces, retained variable indices, assumptions.
PROCESS: validate input; choose measure pushforward, discrete summation or continuous integration; derive marginal; verify normalisation and consistency.
OUTPUT: typed MarginalLaw, symbolic or numerical representation, assumptions, provenance, confidence, validation results and flow hash when computed.
FAILURE: reject malformed distributions, undefined projections, unsupported integration or unverified numerical approximations; explain failure.

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