logo

Axioms for the theory of proveit.logic.sets.functions

In [1]:
import proveit
# Prepare this notebook for defining the axioms of a theory:
%axioms_notebook # Keep this at the top following 'import proveit'.

from proveit import f, x, A, B, fx
from proveit.logic import Forall, Equals, InSet
from proveit.logic.sets import Functions
In [2]:
%begin axioms
Defining axioms for theory 'proveit.logic.sets.functions'
Subsequent end-of-cell assignments will define axioms
%end_axioms will finalize the definitions

A function from a domain $A$ to codomain $B$ must map any element in $A$ to an element in $B$.

In [3]:
functions_def = Forall(
    (f, A, B), Equals(InSet(f, Functions(A, B)),
                      Forall(x, InSet(fx, B), domain=A)))
Out[3]:
functions_def:
In [4]:
%end axioms
These axioms may now be imported from the theory package: proveit.logic.sets.functions