Measure semantics for applicative sequencing #
Independent applicative pairs denote Mathlib product measures on arbitrary measurable spaces. Discarding either output retains the successful mass of its computation as a scaling factor. No operational support, discrete evaluator, or measurable structure on a function space is needed.
Independently sampled applicative pairs have the product of their output measures.
An applicative binary operation pushes its product law forward along the uncurried operation. Only that operation's joint measurability is needed, without a measurable function space.
Keeping the first result scales its measure by the second computation's successful mass.
Keeping the second result scales its measure by the first computation's successful mass.
Mapping the retained first output commutes with discarding the second output. No measurable space or measurability obligation is needed for the intermediate first output.
Mapping the retained second output commutes with discarding the first output. No measurable space or measurability obligation is needed for the intermediate second output.
An independent applicative pair inherits losslessness from its factors.
Keeping the first of two lossless computations preserves its probability certificate.
Keeping the second of two lossless computations preserves its probability certificate.
A final event about the first result retains the second computation's successful mass. The retained result type needs no measurable-space argument.
A final event about the second result retains the first computation's successful mass. The retained result type needs no measurable-space argument.