<s>
In	O
mathematics	O
,	O
an	O
invariant	B-Application
is	O
a	O
property	B-Algorithm
of	O
a	O
mathematical	O
object	O
(	O
or	O
a	O
class	O
of	O
mathematical	O
objects	O
)	O
which	O
remains	O
unchanged	O
after	O
operations	O
or	O
transformations	B-Algorithm
of	O
a	O
certain	O
type	O
are	O
applied	O
to	O
the	O
objects	O
.	O
</s>
<s>
The	O
particular	O
class	O
of	O
objects	O
and	O
type	O
of	O
transformations	B-Algorithm
are	O
usually	O
indicated	O
by	O
the	O
context	O
in	O
which	O
the	O
term	O
is	O
used	O
.	O
</s>
<s>
For	O
example	O
,	O
the	O
area	O
of	O
a	O
triangle	O
is	O
an	O
invariant	B-Application
with	O
respect	O
to	O
isometries	O
of	O
the	O
Euclidean	O
plane	O
.	O
</s>
<s>
The	O
phrases	O
"	O
invariant	B-Application
under	O
"	O
and	O
"	O
invariant	B-Application
to	O
"	O
a	O
transformation	O
are	O
both	O
used	O
.	O
</s>
<s>
More	O
generally	O
,	O
an	O
invariant	B-Application
with	O
respect	O
to	O
an	O
equivalence	O
relation	O
is	O
a	O
property	B-Algorithm
that	O
is	O
constant	O
on	O
each	O
equivalence	O
class	O
.	O
</s>
<s>
Invariants	B-Application
are	O
used	O
in	O
diverse	O
areas	O
of	O
mathematics	O
such	O
as	O
geometry	O
,	O
topology	B-Architecture
,	O
algebra	O
and	O
discrete	O
mathematics	O
.	O
</s>
<s>
Some	O
important	O
classes	O
of	O
transformations	B-Algorithm
are	O
defined	O
by	O
an	O
invariant	B-Application
they	O
leave	O
unchanged	O
.	O
</s>
<s>
For	O
example	O
,	O
conformal	O
maps	O
are	O
defined	O
as	O
transformations	B-Algorithm
of	O
the	O
plane	O
that	O
preserve	O
angles	O
.	O
</s>
<s>
The	O
discovery	O
of	O
invariants	B-Application
is	O
an	O
important	O
step	O
in	O
the	O
process	O
of	O
classifying	O
mathematical	O
objects	O
.	O
</s>
<s>
The	O
quantity	O
—	O
a	O
cardinal	O
number	O
—	O
is	O
associated	O
with	O
the	O
set	O
,	O
and	O
is	O
invariant	B-Application
under	O
the	O
process	O
of	O
counting	O
.	O
</s>
<s>
On	O
the	O
other	O
hand	O
,	O
multiplication	O
does	O
not	O
have	O
this	O
same	O
property	B-Algorithm
,	O
as	O
distance	O
is	O
not	O
invariant	B-Application
under	O
multiplication	O
.	O
</s>
<s>
Angles	O
and	O
ratios	O
of	O
distances	O
are	O
invariant	B-Application
under	O
scalings	B-Algorithm
,	O
rotations	O
,	O
translations	B-Algorithm
and	O
reflections	O
.	O
</s>
<s>
These	O
transformations	B-Algorithm
produce	O
similar	O
shapes	O
,	O
which	O
is	O
the	O
basis	O
of	O
trigonometry	O
.	O
</s>
<s>
In	O
contrast	O
,	O
angles	O
and	O
ratios	O
are	O
not	O
invariant	B-Application
under	O
non-uniform	B-Algorithm
scaling	I-Algorithm
(	O
such	O
as	O
stretching	B-Algorithm
)	O
.	O
</s>
<s>
The	O
sum	O
of	O
a	O
triangle	O
's	O
interior	O
angles	O
(	O
180°	O
)	O
is	O
invariant	B-Application
under	O
all	O
the	O
above	O
operations	O
.	O
</s>
<s>
As	O
another	O
example	O
,	O
all	O
circles	O
are	O
similar	O
:	O
they	O
can	O
be	O
transformed	O
into	O
each	O
other	O
and	O
the	O
ratio	O
of	O
the	O
circumference	O
to	O
the	O
diameter	O
is	O
invariant	B-Application
(	O
denoted	O
by	O
the	O
Greek	O
letter	O
π	O
(	O
pi	O
)	O
)	O
.	O
</s>
<s>
The	O
real	O
part	O
and	O
the	O
absolute	O
value	O
of	O
a	O
complex	O
number	O
are	O
invariant	B-Application
under	O
complex	O
conjugation	O
.	O
</s>
<s>
The	O
degree	O
of	O
a	O
polynomial	O
is	O
invariant	B-Application
under	O
a	O
linear	O
change	O
of	O
variables	O
.	O
</s>
<s>
The	O
dimension	O
and	O
homology	O
groups	O
of	O
a	O
topological	O
object	O
are	O
invariant	B-Application
under	O
homeomorphism	O
.	O
</s>
<s>
The	O
number	O
of	O
fixed	O
points	O
of	O
a	O
dynamical	O
system	O
is	O
invariant	B-Application
under	O
many	O
mathematical	O
operations	O
.	O
</s>
<s>
Euclidean	O
distance	O
is	O
invariant	B-Application
under	O
orthogonal	O
transformations	B-Algorithm
.	O
</s>
<s>
Euclidean	O
area	O
is	O
invariant	B-Application
under	O
linear	B-Architecture
maps	I-Architecture
which	O
have	O
determinant	O
±1	O
(	O
see	O
)	O
.	O
</s>
<s>
Some	O
invariants	B-Application
of	O
projective	B-Algorithm
transformations	I-Algorithm
include	O
collinearity	O
of	O
three	O
or	O
more	O
points	O
,	O
concurrency	O
of	O
three	O
or	O
more	O
lines	O
,	O
conic	O
sections	O
,	O
and	O
the	O
cross-ratio	O
.	O
</s>
<s>
The	O
determinant	O
,	O
trace	O
,	O
eigenvectors	O
,	O
and	O
eigenvalues	O
of	O
a	O
linear	O
endomorphism	O
are	O
invariant	B-Application
under	O
a	O
change	O
of	O
basis	O
.	O
</s>
<s>
In	O
other	O
words	O
,	O
the	O
spectrum	O
of	O
a	O
matrix	B-Architecture
is	O
invariant	B-Application
under	O
a	O
change	O
of	O
basis	O
.	O
</s>
<s>
The	O
principal	O
invariants	B-Application
of	O
tensors	B-Device
do	O
not	O
change	O
with	O
rotation	B-General_Concept
of	O
the	O
coordinate	O
system	O
(	O
see	O
Invariants	B-Application
of	O
tensors	B-Device
)	O
.	O
</s>
<s>
The	O
singular	O
values	O
of	O
a	O
matrix	B-Architecture
are	O
invariant	B-Application
under	O
orthogonal	O
transformations	B-Algorithm
.	O
</s>
<s>
Lebesgue	O
measure	O
is	O
invariant	B-Application
under	O
translations	B-Algorithm
.	O
</s>
<s>
The	O
variance	O
of	O
a	O
probability	O
distribution	O
is	O
invariant	B-Application
under	O
translations	B-Algorithm
of	O
the	O
real	O
line	O
.	O
</s>
<s>
The	O
fixed	O
points	O
of	O
a	O
transformation	O
are	O
the	O
elements	O
in	O
the	O
domain	B-Algorithm
that	O
are	O
invariant	B-Application
under	O
the	O
transformation	O
.	O
</s>
<s>
For	O
example	O
,	O
objects	O
with	O
translational	O
symmetry	O
are	O
invariant	B-Application
under	O
certain	O
translations	B-Algorithm
.	O
</s>
<s>
The	O
integral	O
of	O
the	O
Gaussian	O
curvature	O
of	O
a	O
two-dimensional	O
Riemannian	B-Architecture
manifold	I-Architecture
is	O
invariant	B-Application
under	O
changes	O
of	O
the	O
Riemannian	O
metric	O
.	O
</s>
<s>
The	O
MU	O
puzzle	O
is	O
a	O
good	O
example	O
of	O
a	O
logical	O
problem	O
where	O
determining	O
an	O
invariant	B-Application
is	O
of	O
use	O
for	O
an	O
impossibility	O
proof	O
.	O
</s>
<s>
However	O
,	O
it	O
might	O
be	O
quicker	O
to	O
find	O
a	O
property	B-Algorithm
that	O
is	O
invariant	B-Application
to	O
all	O
rules	O
(	O
i.e.	O
</s>
<s>
This	O
makes	O
the	O
following	O
invariant	B-Application
interesting	O
to	O
consider	O
:	O
</s>
<s>
This	O
is	O
an	O
invariant	B-Application
to	O
the	O
problem	O
,	O
if	O
for	O
each	O
of	O
the	O
transformation	O
rules	O
the	O
following	O
holds	O
:	O
if	O
the	O
invariant	B-Application
held	O
before	O
applying	O
the	O
rule	O
,	O
it	O
will	O
also	O
hold	O
after	O
applying	O
it	O
.	O
</s>
<s>
If	O
the	O
invariant	B-Application
held	O
,	O
it	O
still	O
does	O
.	O
</s>
<s>
The	O
invariant	B-Application
still	O
holds	O
.	O
</s>
<s>
The	O
invariant	B-Application
still	O
holds	O
.	O
</s>
<s>
If	O
the	O
invariant	B-Application
held	O
,	O
it	O
still	O
does	O
.	O
</s>
<s>
The	O
table	O
above	O
shows	O
clearly	O
that	O
the	O
invariant	B-Application
holds	O
for	O
each	O
of	O
the	O
possible	O
transformation	O
rules	O
,	O
which	O
means	O
that	O
whichever	O
rule	O
one	O
picks	O
,	O
at	O
whatever	O
state	O
,	O
if	O
the	O
number	O
of	O
I	O
's	O
was	O
not	O
a	O
multiple	O
of	O
three	O
before	O
applying	O
the	O
rule	O
,	O
then	O
it	O
wo	O
n't	O
be	O
afterwards	O
either	O
.	O
</s>
<s>
A	O
subset	O
S	O
of	O
the	O
domain	B-Algorithm
U	O
of	O
a	O
mapping	O
T	O
:	O
U	O
→	O
U	O
is	O
an	O
invariant	B-Application
set	O
under	O
the	O
mapping	O
when	O
Note	O
that	O
the	O
elements	O
of	O
S	O
are	O
not	O
fixed	O
,	O
even	O
though	O
the	O
set	O
S	O
is	O
fixed	O
in	O
the	O
power	O
set	O
of	O
U	O
.	O
</s>
<s>
(	O
Some	O
authors	O
use	O
the	O
terminology	O
setwise	O
invariant	B-Application
,	O
vs.	O
pointwise	O
invariant	B-Application
,	O
to	O
distinguish	O
between	O
these	O
cases	O
.	O
)	O
</s>
<s>
For	O
example	O
,	O
a	O
circle	O
is	O
an	O
invariant	B-Application
subset	O
of	O
the	O
plane	O
under	O
a	O
rotation	B-General_Concept
about	O
the	O
circle	O
's	O
center	O
.	O
</s>
<s>
Further	O
,	O
a	O
conical	O
surface	O
is	O
invariant	B-Application
as	O
a	O
set	O
under	O
a	O
homothety	B-Algorithm
of	O
space	O
.	O
</s>
<s>
An	O
invariant	B-Application
set	O
of	O
an	O
operation	O
T	O
is	O
also	O
said	O
to	O
be	O
stable	O
under	O
T	O
.	O
For	O
example	O
,	O
the	O
normal	O
subgroups	O
that	O
are	O
so	O
important	O
in	O
group	O
theory	O
are	O
those	O
subgroups	O
that	O
are	O
stable	O
under	O
the	O
inner	B-Algorithm
automorphisms	I-Algorithm
of	O
the	O
ambient	O
group	O
.	O
</s>
<s>
In	O
linear	B-Language
algebra	I-Language
,	O
if	O
a	O
linear	B-Architecture
transformation	I-Architecture
T	O
has	O
an	O
eigenvector	O
v	O
,	O
then	O
the	O
line	O
through	O
0	O
and	O
v	O
is	O
an	O
invariant	B-Application
set	O
under	O
T	O
,	O
in	O
which	O
case	O
the	O
eigenvectors	O
span	O
an	O
invariant	B-Application
subspace	O
which	O
is	O
stable	O
under	O
T	O
.	O
</s>
<s>
When	O
T	O
is	O
a	O
screw	O
displacement	O
,	O
the	O
screw	O
axis	O
is	O
an	O
invariant	B-Application
line	O
,	O
though	O
if	O
the	O
pitch	O
is	O
non-zero	O
,	O
T	O
has	O
no	O
fixed	O
points	O
.	O
</s>
<s>
Firstly	O
,	O
if	O
one	O
has	O
a	O
group	O
G	O
acting	O
on	O
a	O
mathematical	O
object	O
(	O
or	O
set	O
of	O
objects	O
)	O
X	O
,	O
then	O
one	O
may	O
ask	O
which	O
points	O
x	O
are	O
unchanged	O
,	O
"	O
invariant	B-Application
"	O
under	O
the	O
group	O
action	O
,	O
or	O
under	O
an	O
element	O
g	O
of	O
the	O
group	O
.	O
</s>
<s>
Frequently	O
one	O
will	O
have	O
a	O
group	O
acting	O
on	O
a	O
set	O
X	O
,	O
which	O
leaves	O
one	O
to	O
determine	O
which	O
objects	O
in	O
an	O
associated	O
set	O
F(X )	O
are	O
invariant	B-Application
.	O
</s>
<s>
For	O
example	O
,	O
rotation	B-General_Concept
in	O
the	O
plane	O
about	O
a	O
point	O
leaves	O
the	O
point	O
about	O
which	O
it	O
rotates	O
invariant	B-Application
,	O
while	O
translation	B-Algorithm
in	O
the	O
plane	O
does	O
not	O
leave	O
any	O
points	O
invariant	B-Application
,	O
but	O
does	O
leave	O
all	O
lines	O
parallel	O
to	O
the	O
direction	O
of	O
translation	B-Algorithm
invariant	B-Application
as	O
lines	O
.	O
</s>
<s>
Formally	O
,	O
define	O
the	O
set	O
of	O
lines	O
in	O
the	O
plane	O
P	O
as	O
L(P )	O
;	O
then	O
a	O
rigid	B-Algorithm
motion	I-Algorithm
of	O
the	O
plane	O
takes	O
lines	O
to	O
lines	O
–	O
the	O
group	O
of	O
rigid	B-Algorithm
motions	I-Algorithm
acts	O
on	O
the	O
set	O
of	O
lines	O
–	O
and	O
one	O
may	O
ask	O
which	O
lines	O
are	O
unchanged	O
by	O
an	O
action	O
.	O
</s>
<s>
More	O
importantly	O
,	O
one	O
may	O
define	O
a	O
function	O
on	O
a	O
set	O
,	O
such	O
as	O
"	O
radius	O
of	O
a	O
circle	O
in	O
the	O
plane	O
"	O
,	O
and	O
then	O
ask	O
if	O
this	O
function	O
is	O
invariant	B-Application
under	O
a	O
group	O
action	O
,	O
such	O
as	O
rigid	B-Algorithm
motions	I-Algorithm
.	O
</s>
<s>
Dual	O
to	O
the	O
notion	O
of	O
invariants	B-Application
are	O
coinvariants	O
,	O
also	O
known	O
as	O
orbits	O
,	O
which	O
formalizes	O
the	O
notion	O
of	O
congruence	O
:	O
objects	O
which	O
can	O
be	O
taken	O
to	O
each	O
other	O
by	O
a	O
group	O
action	O
.	O
</s>
<s>
For	O
example	O
,	O
under	O
the	O
group	O
of	O
rigid	B-Algorithm
motions	I-Algorithm
of	O
the	O
plane	O
,	O
the	O
perimeter	B-Application
of	O
a	O
triangle	O
is	O
an	O
invariant	B-Application
,	O
while	O
the	O
set	O
of	O
triangles	O
congruent	O
to	O
a	O
given	O
triangle	O
is	O
a	O
coinvariant	O
.	O
</s>
<s>
These	O
are	O
connected	O
as	O
follows	O
:	O
invariants	B-Application
are	O
constant	O
on	O
coinvariants	O
(	O
for	O
example	O
,	O
congruent	O
triangles	O
have	O
the	O
same	O
perimeter	B-Application
)	O
,	O
while	O
two	O
objects	O
which	O
agree	O
in	O
the	O
value	O
of	O
one	O
invariant	B-Application
may	O
or	O
may	O
not	O
be	O
congruent	O
(	O
for	O
example	O
,	O
two	O
triangles	O
with	O
the	O
same	O
perimeter	B-Application
need	O
not	O
be	O
congruent	O
)	O
.	O
</s>
<s>
In	O
classification	O
problems	O
,	O
one	O
might	O
seek	O
to	O
find	O
a	O
complete	O
set	O
of	O
invariants	B-Application
,	O
such	O
that	O
if	O
two	O
objects	O
have	O
the	O
same	O
values	O
for	O
this	O
set	O
of	O
invariants	B-Application
,	O
then	O
they	O
are	O
congruent	O
.	O
</s>
<s>
For	O
example	O
,	O
triangles	O
such	O
that	O
all	O
three	O
sides	O
are	O
equal	O
are	O
congruent	O
under	O
rigid	B-Algorithm
motions	I-Algorithm
,	O
via	O
SSS	O
congruence	O
,	O
and	O
thus	O
the	O
lengths	O
of	O
all	O
three	O
sides	O
form	O
a	O
complete	O
set	O
of	O
invariants	B-Application
for	O
triangles	O
.	O
</s>
<s>
The	O
three	O
angle	O
measures	O
of	O
a	O
triangle	O
are	O
also	O
invariant	B-Application
under	O
rigid	B-Algorithm
motions	I-Algorithm
,	O
but	O
do	O
not	O
form	O
a	O
complete	O
set	O
as	O
incongruent	O
triangles	O
can	O
share	O
the	O
same	O
angle	O
measures	O
.	O
</s>
<s>
However	O
,	O
if	O
one	O
allows	O
scaling	B-Algorithm
in	O
addition	O
to	O
rigid	B-Algorithm
motions	I-Algorithm
,	O
then	O
the	O
AAA	O
similarity	O
criterion	O
shows	O
that	O
this	O
is	O
a	O
complete	O
set	O
of	O
invariants	B-Application
.	O
</s>
<s>
One	O
may	O
forget	O
the	O
cell	O
complex	O
structure	O
and	O
look	O
only	O
at	O
the	O
underlying	O
topological	O
space	O
(	O
the	O
manifold	B-Architecture
)	O
–	O
as	O
different	O
cell	O
complexes	O
give	O
the	O
same	O
underlying	O
manifold	B-Architecture
,	O
one	O
may	O
ask	O
if	O
the	O
function	O
is	O
independent	O
of	O
choice	O
of	O
presentation	O
,	O
in	O
which	O
case	O
it	O
is	O
an	O
intrinsically	O
defined	O
invariant	B-Application
.	O
</s>
<s>
This	O
is	O
the	O
case	O
for	O
the	O
Euler	O
characteristic	O
,	O
and	O
a	O
general	O
method	O
for	O
defining	O
and	O
computing	O
invariants	B-Application
is	O
to	O
define	O
them	O
for	O
a	O
given	O
presentation	O
,	O
and	O
then	O
show	O
that	O
they	O
are	O
independent	O
of	O
the	O
choice	O
of	O
presentation	O
.	O
</s>
<s>
The	O
presentation	O
of	O
a	O
manifold	B-Architecture
in	O
terms	O
of	O
coordinate	O
charts	O
–	O
invariants	B-Application
must	O
be	O
unchanged	O
under	O
change	O
of	O
coordinates	O
.	O
</s>
<s>
Various	O
manifold	B-Architecture
decompositions	O
,	O
as	O
discussed	O
for	O
Euler	O
characteristic	O
.	O
</s>
<s>
Invariants	B-Application
of	O
a	O
presentation	O
of	O
a	O
group	O
.	O
</s>
<s>
Thirdly	O
,	O
if	O
one	O
is	O
studying	O
an	O
object	O
which	O
varies	O
in	O
a	O
family	O
,	O
as	O
is	O
common	O
in	O
algebraic	O
geometry	O
and	O
differential	B-Language
geometry	I-Language
,	O
one	O
may	O
ask	O
if	O
the	O
property	B-Algorithm
is	O
unchanged	O
under	O
perturbation	O
(	O
for	O
example	O
,	O
if	O
an	O
object	O
is	O
constant	O
on	O
families	O
or	O
invariant	B-Application
under	O
change	O
of	O
metric	O
)	O
.	O
</s>
<s>
In	O
computer	B-General_Concept
science	I-General_Concept
,	O
an	O
invariant	B-Application
is	O
a	O
logical	O
assertion	O
that	O
is	O
always	O
held	O
to	O
be	O
true	O
during	O
a	O
certain	O
phase	O
of	O
execution	O
of	O
a	O
computer	B-Application
program	I-Application
.	O
</s>
<s>
For	O
example	O
,	O
a	O
loop	B-Application
invariant	I-Application
is	O
a	O
condition	O
that	O
is	O
true	O
at	O
the	O
beginning	O
and	O
the	O
end	O
of	O
every	O
iteration	O
of	O
a	O
loop	O
.	O
</s>
<s>
Invariants	B-Application
are	O
especially	O
useful	O
when	O
reasoning	O
about	O
the	O
correctness	O
of	O
a	O
computer	B-Application
program	I-Application
.	O
</s>
<s>
The	O
theory	O
of	O
optimizing	B-Application
compilers	I-Application
,	O
the	O
methodology	O
of	O
design	B-Application
by	I-Application
contract	I-Application
,	O
and	O
formal	B-Architecture
methods	I-Architecture
for	O
determining	O
program	O
correctness	O
,	O
all	O
rely	O
heavily	O
on	O
invariants	B-Application
.	O
</s>
<s>
Programmers	O
often	O
use	O
assertions	O
in	O
their	O
code	O
to	O
make	O
invariants	B-Application
explicit	O
.	O
</s>
<s>
Some	O
object	B-Language
oriented	I-Language
programming	I-Language
languages	I-Language
have	O
a	O
special	O
syntax	O
for	O
specifying	O
class	B-Application
invariants	I-Application
.	O
</s>
<s>
Abstract	O
interpretation	O
tools	O
can	O
compute	O
simple	O
invariants	B-Application
of	O
given	O
imperative	O
computer	B-Application
programs	I-Application
.	O
</s>
<s>
More	O
sophisticated	O
invariants	B-Application
generally	O
have	O
to	O
be	O
provided	O
manually	O
.	O
</s>
<s>
In	O
particular	O
,	O
when	O
verifying	O
an	O
imperative	O
program	O
using	O
the	O
Hoare	O
calculus	O
,	O
a	O
loop	B-Application
invariant	I-Application
has	O
to	O
be	O
provided	O
manually	O
for	O
each	O
loop	O
in	O
the	O
program	O
,	O
which	O
is	O
one	O
of	O
the	O
reasons	O
that	O
this	O
approach	O
is	O
generally	O
impractical	O
for	O
most	O
programs	O
.	O
</s>
