<s>
In	O
mathematics	O
,	O
a	O
partial	B-Algorithm
function	I-Algorithm
from	O
a	O
set	O
to	O
a	O
set	O
is	O
a	O
function	O
from	O
a	O
subset	O
of	O
(	O
possibly	O
the	O
whole	O
itself	O
)	O
to	O
.	O
</s>
<s>
The	O
subset	O
,	O
that	O
is	O
,	O
the	O
domain	B-Algorithm
of	O
viewed	O
as	O
a	O
function	O
,	O
is	O
called	O
the	O
domain	B-Algorithm
of	I-Algorithm
definition	I-Algorithm
or	O
natural	O
domain	B-Algorithm
of	O
.	O
</s>
<s>
If	O
equals	O
,	O
that	O
is	O
,	O
if	O
is	O
defined	O
on	O
every	O
element	O
in	O
,	O
then	O
is	O
said	O
to	O
be	O
a	O
total	B-Algorithm
function	I-Algorithm
.	O
</s>
<s>
More	O
technically	O
,	O
a	O
partial	B-Algorithm
function	I-Algorithm
is	O
a	O
binary	O
relation	O
over	O
two	O
sets	O
that	O
associates	O
every	O
element	O
of	O
the	O
first	O
set	O
to	O
at	O
most	O
one	O
element	O
of	O
the	O
second	O
set	O
;	O
it	O
is	O
thus	O
a	O
functional	O
binary	O
relation	O
.	O
</s>
<s>
A	O
partial	B-Algorithm
function	I-Algorithm
is	O
often	O
used	O
when	O
its	O
exact	O
domain	B-Algorithm
of	I-Algorithm
definition	I-Algorithm
is	O
not	O
known	O
or	O
difficult	O
to	O
specify	O
.	O
</s>
<s>
This	O
is	O
the	O
case	O
in	O
calculus	O
,	O
where	O
,	O
for	O
example	O
,	O
the	O
quotient	O
of	O
two	O
functions	O
is	O
a	O
partial	B-Algorithm
function	I-Algorithm
whose	O
domain	B-Algorithm
of	I-Algorithm
definition	I-Algorithm
cannot	O
contain	O
the	O
zeros	O
of	O
the	O
denominator	O
.	O
</s>
<s>
For	O
this	O
reason	O
,	O
in	O
calculus	O
,	O
and	O
more	O
generally	O
in	O
mathematical	O
analysis	O
,	O
a	O
partial	B-Algorithm
function	I-Algorithm
is	O
generally	O
called	O
simply	O
a	O
.	O
</s>
<s>
In	O
computability	O
theory	O
,	O
a	O
general	O
recursive	O
function	O
is	O
a	O
partial	B-Algorithm
function	I-Algorithm
from	O
the	O
integers	O
to	O
the	O
integers	O
;	O
no	O
algorithm	O
can	O
exist	O
for	O
deciding	O
whether	O
an	O
arbitrary	O
such	O
function	O
is	O
in	O
fact	O
total	O
.	O
</s>
<s>
When	O
arrow	O
notation	O
is	O
used	O
for	O
functions	O
,	O
a	O
partial	B-Algorithm
function	I-Algorithm
from	O
to	O
is	O
sometimes	O
written	O
as	O
or	O
However	O
,	O
there	O
is	O
no	O
general	O
convention	O
,	O
and	O
the	O
latter	O
notation	O
is	O
more	O
commonly	O
used	O
for	O
inclusion	B-Algorithm
maps	I-Algorithm
or	O
embeddings	O
.	O
</s>
<s>
Specifically	O
,	O
for	O
a	O
partial	B-Algorithm
function	I-Algorithm
and	O
any	O
one	O
has	O
either	O
:	O
</s>
<s>
thumb|200px|An	O
example	O
of	O
a	O
partial	B-Algorithm
function	I-Algorithm
that	O
is	O
injective	O
.	O
</s>
<s>
A	O
partial	B-Algorithm
function	I-Algorithm
arises	O
from	O
the	O
consideration	O
of	O
maps	O
between	O
two	O
sets	O
and	O
that	O
may	O
not	O
be	O
defined	O
on	O
the	O
entire	O
set	O
.	O
</s>
<s>
A	O
common	O
example	O
is	O
the	O
square	O
root	O
operation	O
on	O
the	O
real	O
numbers	O
:	O
because	O
negative	O
real	O
numbers	O
do	O
not	O
have	O
real	O
square	O
roots	O
,	O
the	O
operation	O
can	O
be	O
viewed	O
as	O
a	O
partial	B-Algorithm
function	I-Algorithm
from	O
to	O
The	O
domain	B-Algorithm
of	I-Algorithm
definition	I-Algorithm
of	O
a	O
partial	B-Algorithm
function	I-Algorithm
is	O
the	O
subset	O
of	O
on	O
which	O
the	O
partial	B-Algorithm
function	I-Algorithm
is	O
defined	O
;	O
in	O
this	O
case	O
,	O
the	O
partial	B-Algorithm
function	I-Algorithm
may	O
also	O
be	O
viewed	O
as	O
a	O
function	O
from	O
to	O
.	O
</s>
<s>
The	O
notion	O
of	O
partial	B-Algorithm
function	I-Algorithm
is	O
particularly	O
convenient	O
when	O
the	O
exact	O
domain	B-Algorithm
of	I-Algorithm
definition	I-Algorithm
is	O
unknown	O
or	O
even	O
unknowable	O
.	O
</s>
<s>
For	O
a	O
computer-science	B-General_Concept
example	O
of	O
the	O
latter	O
,	O
see	O
Halting	O
problem	O
.	O
</s>
<s>
In	O
case	O
the	O
domain	B-Algorithm
of	I-Algorithm
definition	I-Algorithm
is	O
equal	O
to	O
the	O
whole	O
set	O
,	O
the	O
partial	B-Algorithm
function	I-Algorithm
is	O
said	O
to	O
be	O
total	O
.	O
</s>
<s>
Thus	O
,	O
total	O
partial	B-Algorithm
functions	I-Algorithm
from	O
to	O
coincide	O
with	O
functions	O
from	O
to	O
.	O
</s>
<s>
Many	O
properties	O
of	O
functions	O
can	O
be	O
extended	O
in	O
an	O
appropriate	O
sense	O
of	O
partial	B-Algorithm
functions	I-Algorithm
.	O
</s>
<s>
A	O
partial	B-Algorithm
function	I-Algorithm
is	O
said	O
to	O
be	O
injective	O
,	O
surjective	B-Algorithm
,	O
or	O
bijective	B-Algorithm
when	O
the	O
function	O
given	O
by	O
the	O
restriction	O
of	O
the	O
partial	B-Algorithm
function	I-Algorithm
to	O
its	O
domain	B-Algorithm
of	I-Algorithm
definition	I-Algorithm
is	O
injective	O
,	O
surjective	B-Algorithm
,	O
bijective	B-Algorithm
respectively	O
.	O
</s>
<s>
Because	O
a	O
function	O
is	O
trivially	O
surjective	B-Algorithm
when	O
restricted	O
to	O
its	O
image	O
,	O
the	O
term	O
partial	O
bijection	B-Algorithm
denotes	O
a	O
partial	B-Algorithm
function	I-Algorithm
which	O
is	O
injective	O
.	O
</s>
<s>
An	O
injective	O
partial	B-Algorithm
function	I-Algorithm
may	O
be	O
inverted	O
to	O
an	O
injective	O
partial	B-Algorithm
function	I-Algorithm
,	O
and	O
a	O
partial	B-Algorithm
function	I-Algorithm
which	O
is	O
both	O
injective	O
and	O
surjective	B-Algorithm
has	O
an	O
injective	O
function	O
as	O
inverse	O
.	O
</s>
<s>
Furthermore	O
,	O
a	O
function	O
which	O
is	O
injective	O
may	O
be	O
inverted	O
to	O
an	O
injective	O
partial	B-Algorithm
function	I-Algorithm
.	O
</s>
<s>
The	O
notion	O
of	O
transformation	B-Algorithm
can	O
be	O
generalized	O
to	O
partial	B-Algorithm
functions	I-Algorithm
as	O
well	O
.	O
</s>
<s>
For	O
convenience	O
,	O
denote	O
the	O
set	O
of	O
all	O
partial	B-Algorithm
functions	I-Algorithm
from	O
a	O
set	O
to	O
a	O
set	O
by	O
This	O
set	O
is	O
the	O
union	O
of	O
the	O
sets	O
of	O
functions	O
defined	O
on	O
subsets	O
of	O
with	O
same	O
codomain	O
:	O
</s>
<s>
because	O
any	O
partial	B-Algorithm
function	I-Algorithm
can	O
be	O
extended	O
to	O
a	O
function	O
by	O
any	O
fixed	O
value	O
not	O
contained	O
in	O
so	O
that	O
the	O
codomain	O
is	O
an	O
operation	O
which	O
is	O
injective	O
(	O
unique	O
and	O
invertible	O
by	O
restriction	O
)	O
.	O
</s>
<s>
The	O
first	O
diagram	O
at	O
the	O
top	O
of	O
the	O
article	O
represents	O
a	O
partial	B-Algorithm
function	I-Algorithm
that	O
is	O
a	O
function	O
since	O
the	O
element	O
1	O
in	O
the	O
left-hand	O
set	O
is	O
not	O
associated	O
with	O
anything	O
in	O
the	O
right-hand	O
set	O
.	O
</s>
<s>
The	O
logarithm	O
of	O
a	O
non-positive	O
real	O
is	O
not	O
a	O
real	O
number	O
,	O
so	O
the	O
natural	O
logarithm	O
function	O
does	O
n't	O
associate	O
any	O
real	O
number	O
in	O
the	O
codomain	O
with	O
any	O
non-positive	O
real	O
number	O
in	O
the	O
domain	B-Algorithm
.	O
</s>
<s>
Therefore	O
,	O
the	O
natural	O
logarithm	O
function	O
is	O
not	O
a	O
function	O
when	O
viewed	O
as	O
a	O
function	O
from	O
the	O
reals	O
to	O
themselves	O
,	O
but	O
it	O
is	O
a	O
partial	B-Algorithm
function	I-Algorithm
.	O
</s>
<s>
If	O
the	O
domain	B-Algorithm
is	O
restricted	O
to	O
only	O
include	O
the	O
positive	O
reals	O
(	O
that	O
is	O
,	O
if	O
the	O
natural	O
logarithm	O
function	O
is	O
viewed	O
as	O
a	O
function	O
from	O
the	O
positive	O
reals	O
to	O
the	O
reals	O
)	O
,	O
then	O
the	O
natural	O
logarithm	O
is	O
a	O
function	O
.	O
</s>
<s>
Subtraction	O
of	O
natural	O
numbers	O
(	O
non-negative	O
integers	O
)	O
can	O
be	O
viewed	O
as	O
a	O
partial	B-Algorithm
function	I-Algorithm
:	O
</s>
<s>
In	O
denotational	B-Application
semantics	I-Application
a	O
partial	B-Algorithm
function	I-Algorithm
is	O
considered	O
as	O
returning	O
the	O
bottom	O
element	O
when	O
it	O
is	O
undefined	O
.	O
</s>
<s>
In	O
computer	B-General_Concept
science	I-General_Concept
a	O
partial	B-Algorithm
function	I-Algorithm
corresponds	O
to	O
a	O
subroutine	O
that	O
raises	O
an	O
exception	O
or	O
loops	O
forever	O
.	O
</s>
<s>
The	O
IEEE	O
floating	O
point	O
standard	O
defines	O
a	O
not-a-number	O
value	O
which	O
is	O
returned	O
when	O
a	O
floating	O
point	O
operation	O
is	O
undefined	O
and	O
exceptions	O
are	O
suppressed	O
,	O
e.g.	O
</s>
<s>
In	O
a	O
programming	O
language	O
where	O
function	O
parameters	O
are	O
statically	O
typed	O
,	O
a	O
function	O
may	O
be	O
defined	O
as	O
a	O
partial	B-Algorithm
function	I-Algorithm
because	O
the	O
language	O
's	O
type	O
system	O
cannot	O
express	O
the	O
exact	O
domain	B-Algorithm
of	O
the	O
function	O
,	O
so	O
the	O
programmer	O
instead	O
gives	O
it	O
the	O
smallest	O
domain	B-Algorithm
which	O
is	O
expressible	O
as	O
a	O
type	O
and	O
contains	O
the	O
domain	B-Algorithm
of	I-Algorithm
definition	I-Algorithm
of	O
the	O
function	O
.	O
</s>
<s>
The	O
category	O
of	O
sets	O
and	O
partial	B-Algorithm
functions	I-Algorithm
is	O
equivalent	O
to	O
but	O
not	O
isomorphic	O
with	O
the	O
category	O
of	O
pointed	O
sets	O
and	O
point-preserving	O
maps	O
.	O
</s>
<s>
One	O
textbook	O
notes	O
that	O
"	O
This	O
formal	O
completion	O
of	O
sets	O
and	O
partial	B-Algorithm
maps	I-Algorithm
by	O
adding	O
“	O
improper	O
,	O
”	O
“	O
infinite	O
”	O
elements	O
was	O
reinvented	O
many	O
times	O
,	O
in	O
particular	O
,	O
in	O
topology	O
(	O
one-point	O
compactification	O
)	O
and	O
in	O
theoretical	O
computer	O
science.	O
"	O
</s>
<s>
The	O
category	O
of	O
sets	O
and	O
partial	O
bijections	B-Algorithm
is	O
equivalent	O
to	O
its	O
dual	O
.	O
</s>
<s>
An	O
example	O
would	O
be	O
a	O
field	O
,	O
in	O
which	O
the	O
multiplicative	O
inversion	O
is	O
the	O
only	O
proper	O
partial	O
operation	O
(	O
because	O
division	B-Algorithm
by	I-Algorithm
zero	I-Algorithm
is	O
not	O
defined	O
)	O
.	O
</s>
<s>
The	O
set	O
of	O
all	O
partial	B-Algorithm
functions	I-Algorithm
(	O
partial	O
transformations	O
)	O
on	O
a	O
given	O
base	O
set	O
,	O
forms	O
a	O
regular	O
semigroup	O
called	O
the	O
semigroup	O
of	O
all	O
partial	O
transformations	O
(	O
or	O
the	O
partial	O
transformation	B-Algorithm
semigroup	O
on	O
)	O
,	O
typically	O
denoted	O
by	O
The	O
set	O
of	O
all	O
partial	O
bijections	B-Algorithm
on	O
forms	O
the	O
symmetric	O
inverse	O
semigroup	O
.	O
</s>
<s>
Charts	O
in	O
the	O
atlases	O
which	O
specify	O
the	O
structure	O
of	O
manifolds	B-Architecture
and	O
fiber	O
bundles	O
are	O
partial	B-Algorithm
functions	I-Algorithm
.	O
</s>
<s>
In	O
the	O
case	O
of	O
manifolds	B-Architecture
,	O
the	O
domain	B-Algorithm
is	O
the	O
point	O
set	O
of	O
the	O
manifold	B-Architecture
.	O
</s>
<s>
In	O
the	O
case	O
of	O
fiber	O
bundles	O
,	O
the	O
domain	B-Algorithm
is	O
the	O
space	O
of	O
the	O
fiber	O
bundle	O
.	O
</s>
<s>
The	O
initial	O
classification	O
of	O
manifolds	B-Architecture
and	O
fiber	O
bundles	O
is	O
largely	O
expressed	O
in	O
terms	O
of	O
constraints	O
on	O
these	O
transition	O
maps	O
.	O
</s>
<s>
The	O
reason	O
for	O
the	O
use	O
of	O
partial	B-Algorithm
functions	I-Algorithm
instead	O
of	O
functions	O
is	O
to	O
permit	O
general	O
global	O
topologies	O
to	O
be	O
represented	O
by	O
stitching	O
together	O
local	O
patches	O
to	O
describe	O
the	O
global	O
structure	O
.	O
</s>
