<?xml version="1.0"?>
<div class="add">

<b>let </b><font color="Maroon" title="c1">m</font>, <font color="Maroon" title="c2">n</font> be   <a href="nat_1.html#NM1" title="NAT_1:NM.1">Nat</a>;<br/>



<b>assume </b><a NAME="E1:54"/><i><font color="Green" title="E40">A1</font></i>: 
<font color="Maroon" title="c2">n</font> <a href="xxreal_0.html#NR4" title="XXREAL_0:NR.4">&gt;</a> 1
 ;<br/>

<a NAME="E2:54"/><i><font color="Green" title="E41">A2</font></i>: 
( <font color="Maroon" title="c1">m</font> <a href="nat_d.html#K4" title="NAT_D:func.4">mod</a> <font color="Maroon" title="c2">n</font> <a href="hidden.html#R1" title="HIDDEN:pred.1">=</a> 1 implies <font color="Maroon" title="c1">m</font>,1 <a href="int_1.html#R1" title="INT_1:pred.1">are_congruent_mod</a> <font color="Maroon" title="c2">n</font> )
 
<div><a class="txt" onclick="hs2(this)" href="javascript:()" title="54_1"><b>proof </b></a><div class="add">

<b>assume </b><a NAME="E1:54_1"/>
<font color="Maroon" title="c1">m</font> <a href="nat_d.html#K4" title="NAT_D:func.4">mod</a> <font color="Maroon" title="c2">n</font> <a href="hidden.html#R1" title="HIDDEN:pred.1">=</a> 1
 ;<br/>

<b>then consider </b><font color="Maroon" title="c3">k</font> being   <a href="nat_1.html#NM1" title="NAT_1:NM.1">Nat</a><b> such that </b><br/><a NAME="E3:54_1"/><i><font color="Green" title="E42">A3</font></i>: 
( <font color="Maroon" title="c1">m</font> <a href="hidden.html#R1" title="HIDDEN:pred.1">=</a> <span class="p1">(<span class="default"><font color="Maroon" title="c2">n</font> <a href="xcmplx_0.html#K3" title="XCMPLX_0:func.3">*</a> <font color="Maroon" title="c3">k</font></span>)</span> <a href="nat_1.html#K1" title="NAT_1:func.1">+</a> 1 &amp; 1 <a href="xxreal_0.html#NR3" title="XXREAL_0:NR.3">&lt;</a> <font color="Maroon" title="c2">n</font> )
 <b>by </b><i><a class="ref" href="nat_d.html#D2" title="NAT_D:def.2">NAT_D:def 2</a></i>;<br/>
<a NAME="E4:54_1"/>
<font color="Maroon" title="c2">n</font> <a href="xcmplx_0.html#K3" title="XCMPLX_0:func.3">*</a> <font color="Maroon" title="c3">k</font> <a href="hidden.html#R1" title="HIDDEN:pred.1">=</a> <font color="Maroon" title="c1">m</font> <a href="xcmplx_0.html#K6" title="XCMPLX_0:func.6">-</a> 1
 
<b>by </b><i><a class="txt" href="pepin.html#E3:54_1"><i><font color="Green" title="E42">A3</font></i></a></i>;<br/>
<b>hence </b><a NAME="E5:54_1"/>
<font color="Maroon" title="c1">m</font>,1 <a href="int_1.html#R1" title="INT_1:pred.1">are_congruent_mod</a> <font color="Maroon" title="c2">n</font>
 <b>by </b><i><a class="ref" href="int_1.html#D3" title="INT_1:def.3">INT_1:def 3</a></i>;<br/>


</div><b>end;</b></div>
<a NAME="E3:54"/>
( <font color="Maroon" title="c1">m</font>,1 <a href="int_1.html#R1" title="INT_1:pred.1">are_congruent_mod</a> <font color="Maroon" title="c2">n</font> implies <font color="Maroon" title="c1">m</font> <a href="nat_d.html#K4" title="NAT_D:func.4">mod</a> <font color="Maroon" title="c2">n</font> <a href="hidden.html#R1" title="HIDDEN:pred.1">=</a> 1 )
 
<div><a class="txt" onclick="hs2(this)" href="javascript:()" title="54_2"><b>proof </b></a><div class="add">

<b>assume </b><a NAME="E1:54_2"/>
<font color="Maroon" title="c1">m</font>,1 <a href="int_1.html#R1" title="INT_1:pred.1">are_congruent_mod</a> <font color="Maroon" title="c2">n</font>
 ;<br/>

<b>then consider </b><font color="Maroon" title="c3">t</font> being   <a href="int_1.html#NM1" title="INT_1:NM.1">Integer</a><b> such that </b><br/><a NAME="E3:54_2"/><i><font color="Green" title="E42">A4</font></i>: 
<font color="Maroon" title="c2">n</font> <a href="xcmplx_0.html#K3" title="XCMPLX_0:func.3">*</a> <font color="Maroon" title="c3">t</font> <a href="hidden.html#R1" title="HIDDEN:pred.1">=</a> <font color="Maroon" title="c1">m</font> <a href="xcmplx_0.html#K6" title="XCMPLX_0:func.6">-</a> 1
 <b>by </b><i><a class="ref" href="int_1.html#D3" title="INT_1:def.3">INT_1:def 3</a></i>;<br/>
<b>reconsider </b><font color="Maroon" title="c4">m</font> = <font color="Maroon" title="c1">m</font>, <font color="Maroon" title="c5">n</font> = <font color="Maroon" title="c2">n</font> as   <a href="int_1.html#NM1" title="INT_1:NM.1">Integer</a> ;<br/>
<font color="Maroon" title="c4">m</font> <a href="int_1.html#K6" title="INT_1:func.6">mod</a> <font color="Maroon" title="c5">n</font> = 
<span class="p1">(<span class="default"><span class="p2">(<span class="default"><font color="Maroon" title="c5">n</font> <a href="xcmplx_0.html#K3" title="XCMPLX_0:func.3">*</a> <font color="Maroon" title="c3">t</font></span>)</span> <a href="xcmplx_0.html#K2" title="XCMPLX_0:func.2">+</a> 1</span>)</span> <a href="int_1.html#K6" title="INT_1:func.6">mod</a> <font color="Maroon" title="c5">n</font>
<b>by </b><i><a class="txt" href="pepin.html#E3:54_2"><i><font color="Green" title="E42">A4</font></i></a></i>
<br/>.= 
1 <a href="int_1.html#K6" title="INT_1:func.6">mod</a> <font color="Maroon" title="c5">n</font>
<b>by </b><i><a class="ref" href="euler_1.html#T13" title="EULER_1:th.13">EULER_1:13</a></i>
;<br/>
<b>hence </b><a NAME="E6:54_2"/>
<font color="Maroon" title="c1">m</font> <a href="nat_d.html#K4" title="NAT_D:func.4">mod</a> <font color="Maroon" title="c2">n</font> <a href="hidden.html#R1" title="HIDDEN:pred.1">=</a> 1
 <b>by </b><i><a class="txt" href="pepin.html#E1:54"><i><font color="Green" title="E40">A1</font></i></a>, <a class="ref" href="nat_d.html#T14" title="NAT_D:th.14">NAT_D:14</a></i>;<br/>


</div><b>end;</b></div>
<b>hence </b><a NAME="E4:54"/>
( <font color="Maroon" title="c1">m</font> <a href="nat_d.html#K4" title="NAT_D:func.4">mod</a> <font color="Maroon" title="c2">n</font> <a href="hidden.html#R1" title="HIDDEN:pred.1">=</a> 1 iff <font color="Maroon" title="c1">m</font>,1 <a href="int_1.html#R1" title="INT_1:pred.1">are_congruent_mod</a> <font color="Maroon" title="c2">n</font> )
 <b>by </b><i><a class="txt" href="pepin.html#E2:54"><i><font color="Green" title="E41">A2</font></i></a></i>;<br/>


</div>
