르장드르 기호: 두 판 사이의 차이

잔글 (HotCat을 사용해서 분류:정수론을(를) 추가함)
잔글 (불필요한 공백 제거)
 
(사용자 6명의 중간 판 23개는 보이지 않습니다)
1번째 줄: 1번째 줄:
{{학술}}
{{토막글}}
== 정의 ==
== 정의 ==
\(p\)가 3 이상의 [[소수]]이고 \(a\)\((a,p)=1\)인 [[정수]]일 때, 다음 기호
<math>p</math>가 3 이상의 [[소수]]이고 <math>a</math><math>(a,p)=1</math>인 [[정수]]일 때, 다음 기호
: <math>\left(\frac{a}{p}\right)=\begin{cases}
:<math>\left(\frac{a}{p}\right)=\begin{cases}
1,& (\exists x\in \mathbb{Z})[x^2 = a]\\
1,& (\exists x\in \mathbb{Z})[x^2 = a]\\
-1,& (\forall x\in\mathbb{Z})[x^2\ne a]
-1,& (\forall x\in\mathbb{Z})[x^2\ne a]
\end{cases}</math>
\end{cases}</math>
를 '''르장드르 기호(Legendre symbol)'''라고 한다. 즉, \(a\)가 법 \(p\)에 대한 [[이차잉여]]이면 \(\left(\frac{a}{p}\right)=1\)이고 그렇지 않으면 \(\left(\frac{a}{p}\right)=-1\)이다.
를 '''르장드르 기호(Legendre symbol)'''라고 한다. 즉, <math>a</math>가 법 <math>p</math>에 대한 [[이차잉여]]이면 <math>\left(\frac{a}{p}\right)=1</math>이고 그렇지 않으면 <math>\left(\frac{a}{p}\right)=-1</math>이다. 책에 따라서 정의를 조금 확장하여, <math>p\mid a</math>이면 <math>\left(\frac{a}{p}\right)=0</math>이라 하기도 한다. 여기서는 <math>(a,p)=1</math>인 경우만 고려한다.


== 성질 ==
== 기본 성질 ==
\(p,q\)가 서로 다른 3 이상의 소수이고 정수 \(a,b\)에 대해 \((a,p)=(b,p)=1\)일 때,
<math>p,q</math>가 서로 다른 3 이상의 소수이고 정수 <math>a,b</math>에 대해 <math>(a,p)=(b,p)=1</math>일 때,
* \(\left(\frac{a^2}{p}\right)=1\)
#<math>\left(\frac{a^2}{p}\right)=1</math>
\(x=a\)는 합동식 \(x^2\equiv a^2\pmod p\)의 해이므로 자명하다.
#:<math>x=a</math>는 합동식 <math>x^2\equiv a^2\pmod p</math>의 해이므로 자명하다.
* \(a\equiv b \pmod p\)이면 \(\left(\frac{a}{p}\right)=\left(\frac{b}{p}\right)\)이다.
#<math>a\equiv b \pmod p</math>이면 <math>\left(\frac{a}{p}\right)=\left(\frac{b}{p}\right)</math>이다.
\(a\equiv b \pmod p\)라고 가정하면 두 합동식 \(x^2\equiv a\pmod p\)\(x^2\equiv b\pmod p\)는 동치이므로 원하는 결론을 얻는다.
#:<math>a\equiv b \pmod p</math>라고 가정하면 두 합동식 <math>x^2\equiv a\pmod p</math><math>x^2\equiv b\pmod p</math>는 동치이므로 원하는 결론을 얻는다.
* \(\left(\frac{a}{p}\right)\equiv a^{\frac{p-1}{2}} \pmod p\)
#<math>\left(\frac{ab}{p}\right)=\left(\frac{a}{p}\right)\left(\frac{b}{p}\right)</math>
[[오일러의 규준]]에 의해 성립한다.
#:[[최대공약수]]의 성질에 의해 <math>(ab,p)=1</math>이므로, [[지수법칙]]에 의해 <math>\left(\frac{ab}{p}\right)=(ab)^{\frac{p-1}{2}}=a^{\frac{p-1}{2}}b^{\frac{p-1}{2}}=\left(\frac{a}{p}\right)\left(\frac{b}{p}\right)</math>이므로 원하는 결론을 얻는다. 여기서 르장드르 기호는 완전 [[곱셈적 함수]]임을 알 수 있다. 좀 더 엄밀히 표현하면, <math>L:{\mathbb{F}_p}^\times\to\left\{\pm1\right\}</math>가 완전 곱셈적 함수인 것.
* \(\left(\frac{ab}{p}\right)=\left(\frac{a}{p}\right)\left(\frac{b}{p}\right)\)
한 예로, <math>\left(\frac{860}{103}\right)</math>의 값을 구해 보자. 103은 소수이고,
[[지수법칙]]에 의해
:<math>860=8\cdot 103 + 36</math>
: <math>\begin{align}
이므로 <math>860 \equiv 36 \pmod{103}</math>이다. 따라서
\left(\frac{ab}{p}\right)&=(ab)^{\frac{p-1}{2}}\\
:<math>\left(\frac{860}{103}\right)=\left(\frac{36}{103}\right)</math>
&=a^{\frac{p-1}{2}}b^{\frac{p-1}{2}}\\
이다. 그런데 <math>36=6^2</math>이므로
&=\left(\frac{a}{p}\right)\left(\frac{b}{p}\right)
:<math>\left(\frac{860}{103}\right)=\left(\frac{36}{103}\right)=1</math>
\end{align}</math>
임을 알 수 있다.
이므로 원하는 결론을 얻는다.
 
* <math>\left(\frac{-1}{p}\right)=\begin{cases}
== 오일러 판정법 ==
[[오일러의 규준]]이라고도 부른다.
*<math>\left(\frac{a}{p}\right)\equiv a^{\frac{p-1}{2}} \pmod p</math>
*:<math>x_1,\ldots. x_{\frac{p-1}{2}}</math>를 법 <math>p</math>의 [[이차잉여]]라 하자. <math>a</math>가 이차잉여인 경우 <math>\{ax_1,\ldots, ax_{\frac{p-1}{2}} \} </math>는 집합으로서 <math>\{x_1,\ldots, x_{\frac{p-1}{2}} \}</math> 와 일치할 것이다. 따라서 모든 원소의 곱도 일치하고, <math> a^{\frac{p-1}{2}} x_1\cdots x_{\frac{p-1}{2}} \equiv x_1\cdots x_{\frac{p-1}{2}} \pmod{p} </math>가 성립한다. 양변을 소거하면 오일러의 규준을 얻는다.
*:<math>a</math> 가 이차잉여가 아닐 경우, <math>ax_i</math> 들 또한 이차잉여가 아닐 것이고, 마찬가지로 <math> ax_i^{-1}</math> 또한 이차잉여가 아닐 것이다. 따라서 <math> \{x_1,\ldots, x_{\frac{p-1}{2}} \} \cup \{ax_1^{-1} ,\ldots, ax_{\frac{p-1}{2}} ^{-1} \} = \{1,2,\ldots, p-1\}</math> 이다. 모든 원소의 곱을 비교하면 <math>a^{\frac{p-1}{2}} \equiv (p-1)! \equiv -1 \pmod p </math> 를 얻는다. 여기서 마지막 등호는 [[윌슨의 정리]]의 결과이다.
오일러 판정법을 사용해 다음을 보일 수 있다.
*<math>\left(\frac{-1}{p}\right)=\begin{cases}
1,&\text{if }p\equiv 1\pmod 4\\
1,&\text{if }p\equiv 1\pmod 4\\
-1,&\text{if }p\equiv -1\pmod 4
-1,&\text{if }p\equiv -1\pmod 4
\end{cases}</math>
\end{cases}</math>
* <math>\left(\frac{2}{p}\right)=\begin{cases}
*:오일러의 규준에 의해 <math>\left(\frac{-1}{p}\right)\equiv (-1)^{\frac{p-1}{2}}\pmod p</math>인데 <math>\left(\frac{-1}{p}\right)=\pm 1</math>이므로 <math>\left(\frac{-1}{p}\right)= (-1)^{\frac{p-1}{2}}</math>이다. <math>p</math>는 홀수이므로 <math>4k+1</math> 또는 <math>4k-1</math> 꼴인데, <math>(-1)^{2k}=1</math>이고 <math>(-1)^{2k-1}=-1</math>이므로 원하는 결론을 얻는다.
 
== 가우스 판정법 ==
*<math>a,\,2a,\,\ldots,\,\left(\frac{p-1}{2}\right)a</math>를 법 <math>p</math>에 관해서 최소 양수 나머지로 바꾸자. 저 중에 <math>\frac{p}{2}</math>보다 큰 수의 개수를 <math>s</math>라 할 때, <math>\left(\frac{a}{p}\right)=\left(-1\right)^s</math>이다.
*:<math>u_1,\,u_2,\,\ldots,\,u_s</math>를 <math>\frac{p}{2}</math>보다 큰 최소 양수 나머지라 하자. 그리고 <math>v_1,\,v_2,\,\ldots,\,v_t</math>를 <math>\frac{p}{2}</math>보다 작은 최소 양수 나머지라 하자. 먼저, <math>\left\{v_1,\,\ldots,\,v_t,\,p-u_1,\,\ldots,\,p-u_s\right\}=\left\{1,\,2,\,\ldots,\,\frac{p-1}{2}\right\}</math>임을 보일 것이다.
*:#먼저, 모든 원소는 1에서 <math>\frac{p-1}{2}</math>사이.
*:#총 <math>\frac{p-1}{2}</math>개의 원소가 있다.
*:#만약 <math>v_i\equiv v_j\pmod p</math>이면, 적당한 [[정수]] <math>n,\,m</math>에 대해 <math>na\equiv ma\pmod p</math>이다. 그런데 <math>\gcd\left(a,p\right)=1</math>이므로 <math>n\equiv m\pmod p</math>이다. 그런데 <math>n,\,m</math>은 1에서 <math>\frac{p-1}{2}</math>사이의 정수이므로, <math>n=m</math>이다. 비슷한 방법으로, <math>p-u_i\equiv p-u_j\pmod p</math>이면 <math>i=j</math>임을 보일 수 있다. 만약 <math>v_i\equiv p-u_j\pmod p</math>이면, 적당한 정수 <math>n,\,m</math>에 대해 <math>na\equiv-ma\pmod p</math>이다. 즉, <math>n+m\equiv0\pmod p</math> 그런데 <math>n,\,m</math>은 1에서 <math>\frac{p-1}{2}</math>사이의 정수이므로 이는 불가능하다.
*:위 세 명제를 합하면 원하는 결과를 얻는다. 따라서, <math>v_1\cdots v_t\left(p-u_1\right)\cdots\left(p-u_s\right)\equiv1\cdot2\cdots\frac{p-1}{2}\pmod p</math>이고, 정리하면 <math>\left(-1\right)^sv_1\cdots v_t u_1\cdots u_s\equiv\left(\frac{p-1}{2}\right)!\pmod p</math>이다. 여기서 좌변은 <math>\left(-1\right)^sa^{\frac{p-1}{2}}\left(\frac{p-1}{2}\right)!</math>과 합동이고, <math>p\not\mid\left(\frac{p-1}{2}\right)!</math>이므로 <math>\left(-1\right)^sa^{\frac{p-1}{2}}\equiv1\pmod p</math>이다. 따라서, 위 오일러 판정법에 의해 <math>\left(-1\right)^s\equiv a^{\frac{p-1}{2}}\equiv\left(\frac{a}{p}\right)\pmod p</math>.
한 예시를 통해 가우스 판정법이 어떻게 쓰이는지 확인해 보자. 만약 <math>a=5,\,p=11</math>이면, <math>\frac{p-1}{2}=5</math>이고, <math>\left\{a,2a,3a,4a,5a\right\}=\left\{5,10,15,20,25\right\}</math>를 법 11에 관한 최소 양수 나머지로 바꾸면 <math>\left\{5,11,4,9,3\right\}</math>이다. 이중 <math>\frac{p-1}{2}=5.5</math>보다 큰 수의 개수는 2이다. 따라서, <math>s=2</math>이고, <math>\left(\frac{5}{11}\right)\equiv\left(-1\right)^s\equiv1\pmod p</math>이다.
 
가우스 판정법을 사용하면 2가 어떨 때 이차잉여인지 확인할 수 있다.
*<math>\left\{2,2\cdot2,\cdots,\frac{p-1}{2}\cdot2\right\}</math>는 법 <math>p</math>에 대해 이미 최소 양수 나머지이다. 또한, <math>i\cdot2<\frac{p}{2}</math>이기 위한 조건은 <math>i<\frac{p}{4}</math>인 것이다. 즉, <math>s=\frac{p-1}{2}-\left\lfloor\frac{p}{4}\right\rfloor</math>. 따라서, <math>\left(\frac{2}{p}\right)=\left(-1\right)^{\frac{p-1}{2}-\left\lfloor\frac{p}{4}\right\rfloor}</math>. 만약 <math>p\equiv\pm1\pmod8</math>이면, 직접 계산을 통해 <math>\left(\frac{2}{p}\right)=1</math>임을 확인할 수 있다. 만약 <math>p\equiv\pm3\pmod8</math>이면, 마찬가지로 <math>\left(\frac{2}{p}\right)=-1</math>임을 확인할 수 있다. 정리하면 다음과 같다.
*<math>\left(\frac{2}{p}\right)=\begin{cases}
1,&\text{if }p\equiv \pm 1\pmod 8\\
1,&\text{if }p\equiv \pm 1\pmod 8\\
-1,&\text{if }p\equiv \pm 3\pmod 8
-1,&\text{if }p\equiv \pm 3\pmod 8
\end{cases}</math>
\end{cases}</math>
* \(\left(\frac{q}{p}\right)\left(\frac{p}{q}\right)=(-1)^{\frac{p-1}{2}\frac{q-1}{2}}\) ([[이차상반성]])
위 두 조건을 하나로 합치면, <math>\left(\frac{2}{p}\right)=\left(-1\right)^{\frac{p^2-1}{8}}</math>이다. 증명은 생략.
 
== 이차 상호법칙 ==
{{본문|이차 상호 법칙}}
 
<math>p,\,q</math>가 서로 다른 홀수인 소수일 때,
:<math>\left(\frac{q}{p}\right)\left(\frac{p}{q}\right)=(-1)^{\frac{p-1}{2}\frac{q-1}{2}}</math>
 
르장드르 기호의 값을 계산할 때 유용하게 쓰는 법칙이다. [[카를 프리히드리 가우스]]가 1798년에 처음 증명했다. 자세한 내용은 [[이차 상호 법칙]] 문서 참조.
 
== 관련 항목 ==
* [[이차잉여]]
 
{{각주}}


[[분류:정수론]]
[[분류:정수론]]

2021년 6월 15일 (화) 18:24 기준 최신판

정의[편집 | 원본 편집]

[math]\displaystyle{ p }[/math]가 3 이상의 소수이고 [math]\displaystyle{ a }[/math][math]\displaystyle{ (a,p)=1 }[/math]정수일 때, 다음 기호

[math]\displaystyle{ \left(\frac{a}{p}\right)=\begin{cases} 1,& (\exists x\in \mathbb{Z})[x^2 = a]\\ -1,& (\forall x\in\mathbb{Z})[x^2\ne a] \end{cases} }[/math]

르장드르 기호(Legendre symbol)라고 한다. 즉, [math]\displaystyle{ a }[/math]가 법 [math]\displaystyle{ p }[/math]에 대한 이차잉여이면 [math]\displaystyle{ \left(\frac{a}{p}\right)=1 }[/math]이고 그렇지 않으면 [math]\displaystyle{ \left(\frac{a}{p}\right)=-1 }[/math]이다. 책에 따라서 정의를 조금 확장하여, [math]\displaystyle{ p\mid a }[/math]이면 [math]\displaystyle{ \left(\frac{a}{p}\right)=0 }[/math]이라 하기도 한다. 여기서는 [math]\displaystyle{ (a,p)=1 }[/math]인 경우만 고려한다.

기본 성질[편집 | 원본 편집]

[math]\displaystyle{ p,q }[/math]가 서로 다른 3 이상의 소수이고 정수 [math]\displaystyle{ a,b }[/math]에 대해 [math]\displaystyle{ (a,p)=(b,p)=1 }[/math]일 때,

  1. [math]\displaystyle{ \left(\frac{a^2}{p}\right)=1 }[/math]
    [math]\displaystyle{ x=a }[/math]는 합동식 [math]\displaystyle{ x^2\equiv a^2\pmod p }[/math]의 해이므로 자명하다.
  2. [math]\displaystyle{ a\equiv b \pmod p }[/math]이면 [math]\displaystyle{ \left(\frac{a}{p}\right)=\left(\frac{b}{p}\right) }[/math]이다.
    [math]\displaystyle{ a\equiv b \pmod p }[/math]라고 가정하면 두 합동식 [math]\displaystyle{ x^2\equiv a\pmod p }[/math][math]\displaystyle{ x^2\equiv b\pmod p }[/math]는 동치이므로 원하는 결론을 얻는다.
  3. [math]\displaystyle{ \left(\frac{ab}{p}\right)=\left(\frac{a}{p}\right)\left(\frac{b}{p}\right) }[/math]
    최대공약수의 성질에 의해 [math]\displaystyle{ (ab,p)=1 }[/math]이므로, 지수법칙에 의해 [math]\displaystyle{ \left(\frac{ab}{p}\right)=(ab)^{\frac{p-1}{2}}=a^{\frac{p-1}{2}}b^{\frac{p-1}{2}}=\left(\frac{a}{p}\right)\left(\frac{b}{p}\right) }[/math]이므로 원하는 결론을 얻는다. 여기서 르장드르 기호는 완전 곱셈적 함수임을 알 수 있다. 좀 더 엄밀히 표현하면, [math]\displaystyle{ L:{\mathbb{F}_p}^\times\to\left\{\pm1\right\} }[/math]가 완전 곱셈적 함수인 것.

한 예로, [math]\displaystyle{ \left(\frac{860}{103}\right) }[/math]의 값을 구해 보자. 103은 소수이고,

[math]\displaystyle{ 860=8\cdot 103 + 36 }[/math]

이므로 [math]\displaystyle{ 860 \equiv 36 \pmod{103} }[/math]이다. 따라서

[math]\displaystyle{ \left(\frac{860}{103}\right)=\left(\frac{36}{103}\right) }[/math]

이다. 그런데 [math]\displaystyle{ 36=6^2 }[/math]이므로

[math]\displaystyle{ \left(\frac{860}{103}\right)=\left(\frac{36}{103}\right)=1 }[/math]

임을 알 수 있다.

오일러 판정법[편집 | 원본 편집]

오일러의 규준이라고도 부른다.

  • [math]\displaystyle{ \left(\frac{a}{p}\right)\equiv a^{\frac{p-1}{2}} \pmod p }[/math]
    [math]\displaystyle{ x_1,\ldots. x_{\frac{p-1}{2}} }[/math]를 법 [math]\displaystyle{ p }[/math]이차잉여라 하자. [math]\displaystyle{ a }[/math]가 이차잉여인 경우 [math]\displaystyle{ \{ax_1,\ldots, ax_{\frac{p-1}{2}} \} }[/math]는 집합으로서 [math]\displaystyle{ \{x_1,\ldots, x_{\frac{p-1}{2}} \} }[/math] 와 일치할 것이다. 따라서 모든 원소의 곱도 일치하고, [math]\displaystyle{ a^{\frac{p-1}{2}} x_1\cdots x_{\frac{p-1}{2}} \equiv x_1\cdots x_{\frac{p-1}{2}} \pmod{p} }[/math]가 성립한다. 양변을 소거하면 오일러의 규준을 얻는다.
    [math]\displaystyle{ a }[/math] 가 이차잉여가 아닐 경우, [math]\displaystyle{ ax_i }[/math] 들 또한 이차잉여가 아닐 것이고, 마찬가지로 [math]\displaystyle{ ax_i^{-1} }[/math] 또한 이차잉여가 아닐 것이다. 따라서 [math]\displaystyle{ \{x_1,\ldots, x_{\frac{p-1}{2}} \} \cup \{ax_1^{-1} ,\ldots, ax_{\frac{p-1}{2}} ^{-1} \} = \{1,2,\ldots, p-1\} }[/math] 이다. 모든 원소의 곱을 비교하면 [math]\displaystyle{ a^{\frac{p-1}{2}} \equiv (p-1)! \equiv -1 \pmod p }[/math] 를 얻는다. 여기서 마지막 등호는 윌슨의 정리의 결과이다.

오일러 판정법을 사용해 다음을 보일 수 있다.

  • [math]\displaystyle{ \left(\frac{-1}{p}\right)=\begin{cases} 1,&\text{if }p\equiv 1\pmod 4\\ -1,&\text{if }p\equiv -1\pmod 4 \end{cases} }[/math]
    오일러의 규준에 의해 [math]\displaystyle{ \left(\frac{-1}{p}\right)\equiv (-1)^{\frac{p-1}{2}}\pmod p }[/math]인데 [math]\displaystyle{ \left(\frac{-1}{p}\right)=\pm 1 }[/math]이므로 [math]\displaystyle{ \left(\frac{-1}{p}\right)= (-1)^{\frac{p-1}{2}} }[/math]이다. [math]\displaystyle{ p }[/math]는 홀수이므로 [math]\displaystyle{ 4k+1 }[/math] 또는 [math]\displaystyle{ 4k-1 }[/math] 꼴인데, [math]\displaystyle{ (-1)^{2k}=1 }[/math]이고 [math]\displaystyle{ (-1)^{2k-1}=-1 }[/math]이므로 원하는 결론을 얻는다.

가우스 판정법[편집 | 원본 편집]

  • [math]\displaystyle{ a,\,2a,\,\ldots,\,\left(\frac{p-1}{2}\right)a }[/math]를 법 [math]\displaystyle{ p }[/math]에 관해서 최소 양수 나머지로 바꾸자. 저 중에 [math]\displaystyle{ \frac{p}{2} }[/math]보다 큰 수의 개수를 [math]\displaystyle{ s }[/math]라 할 때, [math]\displaystyle{ \left(\frac{a}{p}\right)=\left(-1\right)^s }[/math]이다.
    [math]\displaystyle{ u_1,\,u_2,\,\ldots,\,u_s }[/math][math]\displaystyle{ \frac{p}{2} }[/math]보다 큰 최소 양수 나머지라 하자. 그리고 [math]\displaystyle{ v_1,\,v_2,\,\ldots,\,v_t }[/math][math]\displaystyle{ \frac{p}{2} }[/math]보다 작은 최소 양수 나머지라 하자. 먼저, [math]\displaystyle{ \left\{v_1,\,\ldots,\,v_t,\,p-u_1,\,\ldots,\,p-u_s\right\}=\left\{1,\,2,\,\ldots,\,\frac{p-1}{2}\right\} }[/math]임을 보일 것이다.
    1. 먼저, 모든 원소는 1에서 [math]\displaystyle{ \frac{p-1}{2} }[/math]사이.
    2. [math]\displaystyle{ \frac{p-1}{2} }[/math]개의 원소가 있다.
    3. 만약 [math]\displaystyle{ v_i\equiv v_j\pmod p }[/math]이면, 적당한 정수 [math]\displaystyle{ n,\,m }[/math]에 대해 [math]\displaystyle{ na\equiv ma\pmod p }[/math]이다. 그런데 [math]\displaystyle{ \gcd\left(a,p\right)=1 }[/math]이므로 [math]\displaystyle{ n\equiv m\pmod p }[/math]이다. 그런데 [math]\displaystyle{ n,\,m }[/math]은 1에서 [math]\displaystyle{ \frac{p-1}{2} }[/math]사이의 정수이므로, [math]\displaystyle{ n=m }[/math]이다. 비슷한 방법으로, [math]\displaystyle{ p-u_i\equiv p-u_j\pmod p }[/math]이면 [math]\displaystyle{ i=j }[/math]임을 보일 수 있다. 만약 [math]\displaystyle{ v_i\equiv p-u_j\pmod p }[/math]이면, 적당한 정수 [math]\displaystyle{ n,\,m }[/math]에 대해 [math]\displaystyle{ na\equiv-ma\pmod p }[/math]이다. 즉, [math]\displaystyle{ n+m\equiv0\pmod p }[/math] 그런데 [math]\displaystyle{ n,\,m }[/math]은 1에서 [math]\displaystyle{ \frac{p-1}{2} }[/math]사이의 정수이므로 이는 불가능하다.
    위 세 명제를 합하면 원하는 결과를 얻는다. 따라서, [math]\displaystyle{ v_1\cdots v_t\left(p-u_1\right)\cdots\left(p-u_s\right)\equiv1\cdot2\cdots\frac{p-1}{2}\pmod p }[/math]이고, 정리하면 [math]\displaystyle{ \left(-1\right)^sv_1\cdots v_t u_1\cdots u_s\equiv\left(\frac{p-1}{2}\right)!\pmod p }[/math]이다. 여기서 좌변은 [math]\displaystyle{ \left(-1\right)^sa^{\frac{p-1}{2}}\left(\frac{p-1}{2}\right)! }[/math]과 합동이고, [math]\displaystyle{ p\not\mid\left(\frac{p-1}{2}\right)! }[/math]이므로 [math]\displaystyle{ \left(-1\right)^sa^{\frac{p-1}{2}}\equiv1\pmod p }[/math]이다. 따라서, 위 오일러 판정법에 의해 [math]\displaystyle{ \left(-1\right)^s\equiv a^{\frac{p-1}{2}}\equiv\left(\frac{a}{p}\right)\pmod p }[/math].

한 예시를 통해 가우스 판정법이 어떻게 쓰이는지 확인해 보자. 만약 [math]\displaystyle{ a=5,\,p=11 }[/math]이면, [math]\displaystyle{ \frac{p-1}{2}=5 }[/math]이고, [math]\displaystyle{ \left\{a,2a,3a,4a,5a\right\}=\left\{5,10,15,20,25\right\} }[/math]를 법 11에 관한 최소 양수 나머지로 바꾸면 [math]\displaystyle{ \left\{5,11,4,9,3\right\} }[/math]이다. 이중 [math]\displaystyle{ \frac{p-1}{2}=5.5 }[/math]보다 큰 수의 개수는 2이다. 따라서, [math]\displaystyle{ s=2 }[/math]이고, [math]\displaystyle{ \left(\frac{5}{11}\right)\equiv\left(-1\right)^s\equiv1\pmod p }[/math]이다.

가우스 판정법을 사용하면 2가 어떨 때 이차잉여인지 확인할 수 있다.

  • [math]\displaystyle{ \left\{2,2\cdot2,\cdots,\frac{p-1}{2}\cdot2\right\} }[/math]는 법 [math]\displaystyle{ p }[/math]에 대해 이미 최소 양수 나머지이다. 또한, [math]\displaystyle{ i\cdot2\lt \frac{p}{2} }[/math]이기 위한 조건은 [math]\displaystyle{ i\lt \frac{p}{4} }[/math]인 것이다. 즉, [math]\displaystyle{ s=\frac{p-1}{2}-\left\lfloor\frac{p}{4}\right\rfloor }[/math]. 따라서, [math]\displaystyle{ \left(\frac{2}{p}\right)=\left(-1\right)^{\frac{p-1}{2}-\left\lfloor\frac{p}{4}\right\rfloor} }[/math]. 만약 [math]\displaystyle{ p\equiv\pm1\pmod8 }[/math]이면, 직접 계산을 통해 [math]\displaystyle{ \left(\frac{2}{p}\right)=1 }[/math]임을 확인할 수 있다. 만약 [math]\displaystyle{ p\equiv\pm3\pmod8 }[/math]이면, 마찬가지로 [math]\displaystyle{ \left(\frac{2}{p}\right)=-1 }[/math]임을 확인할 수 있다. 정리하면 다음과 같다.
  • [math]\displaystyle{ \left(\frac{2}{p}\right)=\begin{cases} 1,&\text{if }p\equiv \pm 1\pmod 8\\ -1,&\text{if }p\equiv \pm 3\pmod 8 \end{cases} }[/math]

위 두 조건을 하나로 합치면, [math]\displaystyle{ \left(\frac{2}{p}\right)=\left(-1\right)^{\frac{p^2-1}{8}} }[/math]이다. 증명은 생략.

이차 상호법칙[편집 | 원본 편집]

[math]\displaystyle{ p,\,q }[/math]가 서로 다른 홀수인 소수일 때,

[math]\displaystyle{ \left(\frac{q}{p}\right)\left(\frac{p}{q}\right)=(-1)^{\frac{p-1}{2}\frac{q-1}{2}} }[/math]

르장드르 기호의 값을 계산할 때 유용하게 쓰는 법칙이다. 카를 프리히드리 가우스가 1798년에 처음 증명했다. 자세한 내용은 이차 상호 법칙 문서 참조.

관련 항목[편집 | 원본 편집]

각주