partial function

Updated About encyclopedia.com content Print Article Share Article
views updated

partial function Roughly, a function f : ST

that holds for only a proper subset of S. Strictly, if the subset over which it holds is R, then f : RT

is a function. However it may be more convenient to work with S rather than with R. The set U, U = SR,

is nonempty, and f has no value (or rather has the undefined value) at points in U; f is then said to be undefined on U and defined for all elements in the subset R of S, i.e. in S but not in U.

Partial functions arise naturally in computing. When recursive definitions of functions are given, the definition can sometimes loop for certain parameters. Definitions of functions can also give rise to overflow or exception situations. In these cases it is convenient to talk about partial functions. Compare total function.