Visual exploration of surjectivity and injectivity (as a properties of mathematical functions).
Live demo.
-
controls for generating random functions
- generate any function
- surjective, injective (only enabled when such a function exists for given domain/codomain size)
-
add explanation about why given function is NOT surjective / injective
-
Link Wikipedia articles in appropriate places
- https://en.wikipedia.org/wiki/Vacuous_truth - explanation why there is an empty function : {} -> anything
- https://en.wikipedia.org/wiki/Initial_and_terminal_objects
- https://en.wikipedia.org/wiki/Surjective_function
- https://en.wikipedia.org/wiki/Empty_set
- https://en.wikipedia.org/wiki/Domain_of_a_function