Home

nontotal

Nontotal is an adjective used in mathematics, logic, and computer science to describe a relation or function that is not defined for every element of its input domain. A function is total if every input yields a value in the codomain; if there exists at least one input for which no output is assigned, the function is nontotal (or, more commonly in some contexts, partial). The term highlights the property of non-definition rather than the specific mechanism by which the undefined inputs arise.

In formal discussions, the standard notion is that of a partial function. A partial function from a

Examples are common in programming and logic. A function f: N -> N defined by f(n) = 1

Handling non-totality often involves explicit error signaling, option or Maybe types, or restricting the input domain

set
A
to
a
set
B
has
a
domain
of
definition
D
that
is
a
subset
of
A;
outside
D,
the
function
has
no
value.
The
label
nontotal
is
sometimes
used
synonymously
with
partial,
but
some
authors
prefer
partial
to
emphasize
the
mathematical
object
and
reserve
nontotal
for
broader
or
less
formal
contexts,
such
as
a
process
that
may
fail
to
yield
a
result
on
certain
inputs.
if
n
is
even
and
undefined
if
n
is
odd
is
nontotal.
Similarly,
a
mathematical
rule
like
“take
the
square
root
of
n
if
n
is
a
perfect
square;
otherwise
undefined”
is
nontotal.
In
computability,
non-termination
is
a
typical
source
of
non-totality,
since
a
program
may
run
forever
for
some
inputs,
failing
to
produce
an
output.
to
guarantee
totality.
See
also
partial
function,
total
function,
domain
of
definition,
halting
problem.