You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

312 lines
10 KiB

  1. \documentclass{article}
  2. \usepackage[utf8]{inputenc}
  3. \usepackage{amsfonts}
  4. \usepackage{amsthm}
  5. \usepackage{amsmath}
  6. \usepackage{amssymb}
  7. \usepackage{mathtools}
  8. \usepackage{enumerate}
  9. \usepackage{hyperref}
  10. \hypersetup{
  11. colorlinks,
  12. citecolor=black,
  13. filecolor=black,
  14. linkcolor=black,
  15. urlcolor=blue
  16. }
  17. % \usepackage{xcolor}
  18. % prevent warnings of underfull \hbox:
  19. % \usepackage{etoolbox}
  20. % \apptocmd{\sloppy}{\hbadness 4000\relax}{}{}
  21. \theoremstyle{definition}
  22. \newtheorem{definition}{Def}[section]
  23. \newtheorem{theorem}[definition]{Thm}
  24. \newtheorem{innersolution}{}
  25. \newenvironment{solution}[1]
  26. {\renewcommand\theinnersolution{#1}\innersolution}
  27. {\endinnersolution}
  28. \title{Weil Pairing - study}
  29. \author{arnaucube}
  30. \date{August 2022}
  31. \begin{document}
  32. \maketitle
  33. \begin{abstract}
  34. Notes taken from \href{https://sites.google.com/site/matanprasma/artifact}{Matan Prasma} math seminars and also while reading about Bilinear Pairings. Usually while reading papers and books I take handwritten notes, this document contains some of them re-written to $LaTeX$.
  35. The notes are not complete, don't include all the steps neither all the proofs. I use these notes to revisit the concepts after some time of reading the topic.
  36. \end{abstract}
  37. \tableofcontents
  38. \section{Rational functions}
  39. Let $E/\Bbbk$ be an elliptic curve defined by: $y^2 = x^3 + Ax + B$.
  40. \paragraph{set of polynomials over $E$:}
  41. $\Bbbk[E] := \Bbbk[x,y] / (y^2 - x^3 - Ax - B =0)$
  42. we can replace $y^2$ in the polynomial $f \in \Bbbk[E]$ with $x^3 + Ax + B$
  43. \paragraph{canonical form:} $f(x,y) = v(x)+y w(x)$ for $v, w \in \Bbbk[x]$
  44. \paragraph{conjugate:} $\overline{f} = v(x) - y w(x)$
  45. \paragraph{norm:} $N_f = f \cdot \overline{f} = v(x)^2 - y^2 w(x)^2 = v(x)^2 - (x^3 + Ax + B) w(x)^2 \in \Bbbk[x] \subset \Bbbk[E]$
  46. we can see that $N_{fg} = N_f \cdot N_g$
  47. \paragraph{set of rational functions over $E$:}
  48. $\Bbbk(E) := \Bbbk[E] \times \Bbbk[E]/ \thicksim$
  49. For $r\in \Bbbk(E)$ and a finite point $P \in E(\Bbbk)$, $r$ is \emph{finite} at $P$ iff
  50. $$\exists~ r=\frac{f}{g} ~\text{with}~ f,g \in \Bbbk[E],~ s.t.~ g(P) \neq 0$$
  51. We define $r(P)=\frac{f(P)}{g(P)}$. Otherwise, $r(P)=\infty$.
  52. Remark: $r=\frac{f}{g} \in \Bbbk(E)$, $r=\frac{f}{g}=\frac{f \cdot \overline{g}}{g \cdot \overline{g}} = \frac{f \overline{g}}{N_g}$, thus
  53. $$r(x,y)=\frac{ (f \overline{g})(x,y)}{N_g(x,y)} = \underbrace{ \frac{v(x)}{N_g(x)} + y \frac{w(x)}{N_g(x)} }_\text{canonical form of $r(x,y)$}$$
  54. \paragraph{degree of $f$:} Let $f\in \Bbbk[E]$, in canonical form: $f(x,y) = v(x) + y w(x)$,
  55. $$deg(f) := max\{ 2 \cdot deg_x(v), 3+2 \cdot deg_x(w) \}$$
  56. For $f,g \in \Bbbk[E]$:
  57. \begin{enumerate}[i.]
  58. \item $deg(f) = deg_x(N_f)$
  59. \item $deg(f \cdot g) = deg(f) + deg(g)$
  60. \end{enumerate}
  61. \begin{definition}
  62. Let $r=\frac{f}{g} \in \Bbbk(E)$
  63. \begin{enumerate}[i.]
  64. \item if $deg(f) < deg(g):~ r(0)=0$
  65. \item if $deg(f) > deg(g):~ r ~\text{is not finite at}~ 0$
  66. \item if $deg(f) = deg(g)$ with $deg(f)$ even:\\
  67. $f$'s canonical form leading terms $ax^d$\\
  68. $g$'s canonical form leading terms $bx^d$\\
  69. $a,b \in \Bbbk^\times,~ d=\frac{deg(f)}{2}$, set $r(0)=\frac{a}{b}$
  70. \item if $deg(f) = deg(g)$ with $deg(f)$ odd\\
  71. $f$'s canonical form leading terms $ax^d$\\
  72. $g$'s canonical form leading terms $bx^d$\\
  73. $a,b \in \Bbbk^\times,~ deg(f)=deg(g)=3+2d$, set $r(0)=\frac{a}{b}$
  74. \end{enumerate}
  75. \end{definition}
  76. \subsection{Zeros, poles, uniformizers and multiplicities}
  77. $r \in \Bbbk(E)$ has a \emph{zero} in $P\in E$ if $r(P)=0$\\
  78. $r \in \Bbbk(E)$ has a \emph{pole} in $P\in E$ if $r(P)$ is not finite.
  79. \paragraph{uniformizer:} Let $P\in E$,
  80. uniformizer: rational function $u \in \Bbbk(E)$ with $u(P)=0$ if
  81. $\forall r\in \Bbbk(E) \setminus \{0\},~ \exists d \in \mathbb{Z},~ s\in \Bbbk(E)$ finite at $P$ with $s(P) \neq 0$ s.t.
  82. $$r=u^d \cdot s$$
  83. \paragraph{order:} Let $P \in E(\Bbbk)$, let $u \in \Bbbk(E)$ be a uniformizer at $P$.
  84. For $r \in \Bbbk(E) \setminus \{0\}$ being a rational function with $r=u^d \cdot s$ with $s(P)\neq 0, \infty$, we say that $r$ has \emph{order} $d$ at $P$ ($ord_P(r)=d$).
  85. \paragraph{multiplicity:} \emph{multiplicity of a zero} of $r$ is the order of $r$ at that point, \emph{multiplicity of a pole} of $r$ is the order of $r$ at that point.
  86. if $P \in E(\Bbbk)$ is neither a zero or pole of $r$, then $ord_P(r)=0$ ($=d,~ r=u^0s$).
  87. \vspace{0.5cm}
  88. \begin{minipage}{4.3 in}
  89. \paragraph{Multiplicities, from the book "Elliptic Tales"} (p.69), to provide intuition
  90. Factorization into \emph{linear factors}: $p(x)=c\cdot (x-a_1) \cdots (x-a_d)$\\
  91. $d$: degree of $p(x)$, $a_i \in \Bbbk$\\
  92. Solutions to $p(x)=0$ are $x=a_1, \ldots, a_d$ (some $a_i$ can be repeated)\\
  93. eg.: $p(x)=(x-1)(x-1)(x-3)$, solutions to $p(x)=0:~ 1, 1, 3$\\
  94. $x=1$ is a solution to $p(x)=0$ of \emph{multiplicity} 2.
  95. The total number of solutions (counted with multiplicity) is $d$, the degree of the polynomial whose roots we are finding.
  96. \end{minipage}
  97. \section{Divisors}
  98. \begin{definition}{Divisor}
  99. $$D= \sum_{P \in E(\Bbbk)} n_p \cdot [P]$$
  100. \end{definition}
  101. \begin{definition}{Degree \& Sum}
  102. $$deg(D)= \sum_{P \in E(\Bbbk)} n_p$$
  103. $$sum(D)= \sum_{P \in E(\Bbbk)} n_p \cdot P$$
  104. \end{definition}
  105. The set of all divisors on $E$ forms a group: for $D = \sum_{P\in E(\Bbbk)} n_P[P]$ and $D' = \sum_{P\in E(\Bbbk)} m_P[P]$,
  106. $$D+D' = \sum_{P\in E(\Bbbk)} (n_P + m_P)[P]$$
  107. \begin{definition}{Associated divisor}
  108. $$div(r) = \sum_{P \in E(\Bbbk)} ord_P(r)[P]$$
  109. \end{definition}
  110. Observe that
  111. \begin{enumerate}
  112. \item[] $div(rs) = div(r)+div(s)$
  113. \item[] $div(\frac{r}{s}) = div(r)-div(s)$
  114. \end{enumerate}
  115. Observe that
  116. $$\sum_{P \in E(\Bbbk)} ord_P(r) \cdot P = 0$$
  117. \begin{definition}{Support of a divisor}
  118. $$\sum_P n_P[P], ~\forall P \in E(\Bbbk) ~\text{s.t.}~ n_P \neq 0$$
  119. \end{definition}
  120. \begin{definition}{Principal divisor}
  121. iff
  122. $$deg(D)=0$$
  123. $$sum(D)=0$$
  124. \end{definition}
  125. $D \sim D'$ iff $D - D'$ is principal.
  126. \begin{definition}{Evaluation of a rational function} (function $r$ evaluated at $D$)
  127. $$r(D)= \prod r(P)^{n_p}$$
  128. \end{definition}
  129. \section{Weil reciprocity}
  130. \begin{theorem}{(Weil reciprocity)}
  131. Let $E/ \Bbbk$ be an e.c. over an algebraically closed field. If $r,~s \in \Bbbk\setminus \{0\}$ are rational functions whose divisors have disjoint support, then
  132. $$r(div(s)) = s(div(r))$$
  133. \end{theorem}
  134. Proof. (todo)
  135. \paragraph{Example}
  136. \begin{align*}
  137. p(x)=x^2 - 1,&~ q(x)=\frac{x}{x-2}\\
  138. div(p)&= 1 \cdot [1] + 1 \cdot [-1] - 2 \cdot [\infty]\\
  139. div(q)&= 1 \cdot [0] - 1 \cdot [2]\\
  140. &\text{(they have disjoint support)}\\
  141. p(div(q)) &= p(0)^1 \cdot p(2)^{-1}= (0^2 - 1)^1 \cdot (2^2 - 1)^{-1} = \frac{-1}{3}\\
  142. q(div(p)) &= q(1)^1 \cdot q(-1)^1 - q(\infty)^2\\
  143. &= (\frac{1}{1-2})^1 \cdot (\frac{-1}{-1-2})^1 \cdot (\frac{\infty}{\infty - 2})^2 = \frac{-1}{3}
  144. \end{align*}
  145. so, $p(div(q))=q(div(p))$.
  146. \section{Generic Weil Pairing}
  147. Let $E(\Bbbk)$, with $\Bbbk$ of char $p$, $n$ s.t. $p \nmid n$.
  148. $\Bbbk$ large enough: $E(\Bbbk)[n] = E(\overline{\Bbbk}) = \mathbb{Z}_n \oplus \mathbb{Z}_n$ (with $n^2$ elements).
  149. For $P, Q \in E[n]$,
  150. \begin{align*}
  151. D_P &\sim [P] - [0]\\
  152. D_Q &\sim [Q] - [0]
  153. \end{align*}
  154. We need them to have disjoint support:
  155. \begin{align*}
  156. D_P &\sim [P] - [0]\\
  157. D_Q' &\sim [Q+T] - [T]
  158. \end{align*}
  159. $$\Delta D = D_Q - D_Q' = [Q] - [0] - [Q+T] + [T]$$
  160. Note that $n D_P$ and $n D_Q$ are principal. Proof:
  161. \begin{align*}
  162. n D_P &= n [P] - n [O]\\
  163. deg(n D_P) &= n - n = 0\\
  164. sum(n D_P) &= nP - nO = 0
  165. \end{align*}
  166. ($nP = 0$ bcs. $P$ is n-torsion)
  167. Since $n D_P,~ n D_Q$ are principal, we know that $f_P,~ f_Q$ exist.
  168. Take
  169. \begin{align*}
  170. f_P &: div(f_P) = n D_P\\
  171. f_Q &: div(f_Q) = n D_Q
  172. \end{align*}
  173. We define
  174. $$
  175. e_n(P, Q) = \frac{f_P(D_Q)}{f_Q(D_P)}
  176. $$
  177. Remind: evaluation of a rational function over a divisor $D$:
  178. \begin{align*}
  179. D &= \sum n_P [P]\\
  180. r(D) &= \prod r(P)^{n_P}
  181. \end{align*}
  182. If $D_P = [P+S] - [S],~~ D_Q=[Q-T]-[T]$ what is $e_n(P, Q)$?
  183. \begin{align*}
  184. f_P(D_Q) &= f_P(Q+T)^1 \cdot f_P(T)^{-1}\\
  185. f_Q(D_P) &= f_Q(P+S)^1 \cdot f_Q(S)^{-1}
  186. \end{align*}
  187. $$
  188. e_n(P, Q) = \frac{f_P(Q+T)}{f_P(T)} / \frac{f_Q(P+S)}{f_Q(S)}
  189. $$
  190. with $S \neq \{O, P, -Q, P-Q \}$.
  191. \section{Properties}
  192. \begin{enumerate}[i.]
  193. \item $e_n(P, Q)^n = 1 ~\forall P,Q \in E[n]$\\
  194. ($\Rightarrow~ e_n(P,Q)$ is a $n^{th}$ root of unity)
  195. \item Bilinearity
  196. $$e_n(P_1+P_2, Q) = e_n(P_1, Q) \cdot e_n(P_2, Q)$$
  197. $$e_n(P, Q_1+Q_2) = e_n(P, Q_1) \cdot e_n(P, Q_2)$$
  198. \emph{proof:}
  199. recall that $e_n(P,Q)=\frac{g(S+P)}{g(S)}$, then,
  200. \begin{align*}
  201. e_n(P_1, Q) &\cdot e_n(P_2, Q) = \frac{g(P_1 + S)}{g(S)} \cdot \frac{g(P_2 + P_1 + S)}{g(P_1 + S)}\\
  202. &\text{(replace $S$ by $S+P_1$)}\\
  203. &= \frac{g(P_2 + P_1 + S)}{g(S)} = e_n(P_1+P_2, Q)
  204. \end{align*}
  205. \item Alternating
  206. $$e_n(P, P)=1 ~\forall P\in E[n]$$
  207. \item Nondegenerate
  208. $$\text{if}~ e_n(P,Q)=1 ~\forall Q\in E[n],~ \text{then}~ P=0$$
  209. \end{enumerate}
  210. \section{Exercises}
  211. \emph{An Introduction to Mathematical Cryptography, 2nd Edition} - Section 6.8. Bilinear pairings on elliptic curves
  212. \begin{solution}{6.29}
  213. $div(R(x) \cdot S(x)) = div( R(x)) + div( S(x))$, where $R(x), S(x)$ are rational functions.
  214. \\proof:\\
  215. \emph{Norm} of $f$: $N_f = f \cdot \overline{f}$, and we know that $N_{fg} = N_f \cdot N_g~\forall~\Bbbk[E]$,\\
  216. then $$deg(f) = deg_x(N_f)$$\\
  217. and $$deg(f \cdot g) = deg(f) + deg(g)$$
  218. Proof:
  219. $$deg(f \cdot g) = deg_x(N_{fg}) = deg_x(N_f \cdot N_g)$$
  220. $$= deg_x(N_f) + deg_x(N_g) = deg(f) + deg(g)$$
  221. So, $\forall P \in E(\Bbbk),~ ord_P(rs) = ord_P(r) + ord_P(s)$.\\
  222. As $div(r) = \sum_{P\in E(\Bbbk)} ord_P(r)[P]$, $div(s) = \sum ord_P(s)[P]$.
  223. So,
  224. $$div(rs) = \sum ord_P(rs)[P]$$
  225. $$= \sum ord_P(r)[P] + \sum ord_P(s)[P] = div(r) + div(s)$$
  226. \end{solution}
  227. \vspace{0.5cm}
  228. \begin{solution}{6.31}
  229. $$e_m(P, Q) = e_m(Q, P)^{-1} \forall P, Q \in E[m]$$
  230. Proof:
  231. We know that $e_m(P, P) = 1$, so:
  232. $$1 = e_m(P+Q, P+Q) = e_m(P, P) \cdot e_m(P, Q) \cdot e_m(Q, P) \cdot e_m(Q, Q)$$
  233. and we know that $e_m(P, P) = 1$, then we have:
  234. $$1 = e_m(P, Q) \cdot e_m(Q, P)$$
  235. $$\Longrightarrow e_m(P, Q) = e_m(Q, P)^{-1}$$
  236. \end{solution}
  237. \end{document}