Carmichael function: Difference between revisions

Content deleted Content added
Numerical example: Added an extended example, to show more detail of the Charmichael function algorithm.
Tags: Mobile edit Mobile web edit
m Numerical example: trzing to rectify good faith contribution
Line 56:
|}
 
==Numerical exampleexamples==
# Carmichael's function at 85 is 24, {{math | ''λ''(85) {{=}} 24}}, because for any number {{mvar | <math>0<a}}<5</math> coprime to 85, iti.e. holds that<math>a\in \{{math1, |2, ''a''3, 4\}~,<sup/math>2 there is </supmath>a^m \equiv 1 \,(\text{mod 8)}}. Namely5)</math> with <math>m=4,</math> namely, {{math | 1<sup>21⋅4</sup> {{=}} 1<sup>4</sup> ≡ 1 (mod 85)}}, {{math | 32<sup>24</sup> {{=}} 916 ≡ 1 (mod 85)}}, {{math | 53<sup>24</sup> {{=}} 2581 ≡ 1 (mod 85)}} and {{math | 74<sup>22⋅2</sup> {{=}} 4916<sup>2</sup> ≡ 1<sup>2</sup> (mod 85)}}. And this {{math | ''m'' {{=}} 4}} is the smallest exponent with this property, because <math>2^2 =4 \not\equiv 1 \,(\text{mod } 5)</math> (and <math>3^2 = 9 \not\equiv 1 \,(\text{mod } 5)</math> as well.)<br />Moreover, Euler's [[totient function]] at 85 is 4, {{math | ''φ''(85) {{=}} 4}}, because there are exactly 4 numbers less than and coprime to 85 (1, 32, 53, and 74). [[Euler's theorem]] assures that {{math | ''a''<sup>4</sup> ≡ 1 (mod 85)}} for all {{mvar | a}} coprime to 85, butand 4 is not the smallest such exponent.
# Carmichael's function at 58 is 42, {{math | ''λ''(58) {{=}} 42}}, because for any number {{mvar | a}} coprime to 58, =i.e. <math>a\in (\{1, 2, 3, 4)5, where {{mvar | m7\}} {{=}} 2~,</math> it '''does not hold'''holds that {{math | ''a''<sup>''m''2</sup> ≡ 1 (mod 58)}}. Namely, {{math | 1<sup>21⋅2</sup> {{=}} 1<sup>2</sup> ≡ 1 (mod 58)}}, {{math | 23<sup>2</sup> {{=}} 49 !≡ 1 (mod 58)}}, {{math | 35<sup>2</sup> {{=}} 925 !≡ 1 (mod 58)}} and {{math | 47<sup>2</sup> {{=}} 1649 ≡ 1 (mod 58)}}.<br Because/>Euler's at[[totient leastfunction]] oneat equation8 is not4, modular{{math congruent| ''φ''(!≡8); therefor{{=}} increase4}}, because there are exactly 4 numbers less than and coprime to 8 (1, 3, 5, and 7). Moreover, [[Euler's theorem]] assures that {{math | 'm'a''<sup>4</sup> ≡ 1 (mod 8)}} for all {{mvar | a}} coprime to 8, but 4 is not the smallest such exponent.
 
<h3>Extended Example</h3>
Carmichael's function at 5 is 4, {{math | ''λ''(5) {{=}} 4}}, because for any number {{mvar | a}} coprime to 5 => (1, 2, 3, 4), where {{mvar | m}} {{=}} 2, it '''does not hold''' that {{math | ''a''<sup>''m''</sup> ≡ 1 (mod 5)}}. Namely, {{math | 1<sup>2</sup> {{=}} 1 (mod 5)}}, {{math | 2<sup>2</sup> {{=}} 4 !≡ 1 (mod 5)}}, {{math | 3<sup>2</sup> {{=}} 9 !≡ 1 (mod 5)}} and {{math | 4<sup>2</sup> {{=}} 16 ≡ 1 (mod 5)}}. Because at least one equation is not modular congruent (!≡); therefor increase ''m''.
When {{math | ''m'' {{=}} 3}} there is at least one equation were modular congruence does not hold. Namely {{math | 1<sup>3</sup> {{=}} 1 (mod 5)}}, {{math | 2<sup>3</sup> {{=}} 8 !≡ 1 (mod 5)}}, {{math | 3<sup>3</sup> {{=}} 27 !≡ 1 (mod 5)}} and {{math | 4<sup>3</sup> {{=}} 64 !≡ 1 (mod 5)}}.
 
But modular congruence is true for all coprime of 5 => (1,2,3,4), when ''m'' {{=}} 4. Namely {{math | 1<sup>4</sup> {{=}} 1 (mod 5)}}, {{math | 2<sup>4</sup> {{=}} 16 ≡ 1 (mod 5)}}, {{math | 3<sup>4</sup> {{=}} 71 ≡ 1 (mod 5)}} and {{math | 4<sup>4</sup> {{=}} 256 ≡ 1 (mod 5)}}.
 
== Computing {{math | ''λ''(''n'')}} with Carmichael's theorem ==