The “functions” taught in school mathematics at many levels aren’t functions on a type as presented in type theory, but rather they are partial and/or multivalued “functions”, which are basically just combinatorial directed graphs on . In school algebra, the reciprocal function for in a field is a partial function and the square root function is partial and multivalued. In school calculus, the derivative is a partial function on the function type because certain functions are nowhere-differentiable, and the antiderivative is multivalued even for the zero function .
see: Fred Richman’s Algebraic functions, calculus style