首页 > 其他分享 >欧拉函数性质证明

欧拉函数性质证明

时间:2023-04-26 18:33:06浏览次数:33  
标签:frac 函数 sum varphi times cdots therefore 证明 欧拉

欧拉函数性质

前言:欧拉函数的定义 \(\varphi(n)\) 为 \(1-n\) 中与 \(n\) 互质的数。

1证明: \(\varphi(1)=1\)

\[\because 只有1与1本身互质\\ \therefore \varphi(1)=1 \]

2证明:\(当p是质数时,\varphi(p)=p-1\)

\[\because p是质数\\ \therefore \forall x(1<x<p) gcd(x,p)=1\\ \therefore \varphi(p)=p-1 \]

3证明:\(当p是质数时,对于n=p^k,\varphi(n)=p^k-p^{k-1}=(p-1)\times p^{k-1}\)

\[\because n=p^k\\ \therefore \varphi(n)=n-\frac n p\\ =n(1-\frac 1 p)\\ =p^k\times1-p^k\times \frac 1 p\\ =p^k-p^{k-1}\\ =p^{k-1}\times \frac {p^k-p^{k-1}} {p^{k-1}}\\ =p^{k-1}\times (\frac {p^k} {p^{k-1}}-\frac {p^k} {p^k})\\ =p^{k-1}\times (p-1)\\ =p^k-p^{k-1} \]

4证明:\(对于gcd(a,b)=1,\varphi(a\times b)=\varphi(a)\times \varphi(b)\)

\[设a=p_1^{c_1}p_2^{c_2}\cdots p_n^{c_n},b=q_1^{d_1}q_2^{d_2}\cdots q_m^{d_m}\\ \therefore \varphi(a\times b)=a\times b(1-\frac 1 {p_1})(1-\frac 1 {p_2})\cdots (1-\frac 1 {p_n})(1-\frac 1 {q_1})(1-\frac 1 {q_2})\cdots (1-\frac 1 {q_m})\\ =(a\times (1-\frac 1 {p_1})(1-\frac 1 {p_2})\cdots (1-\frac 1 {p_n}))(b\times (1-\frac 1 {q_1})(1-\frac 1 {q_2})\cdots (1-\frac 1 {q_m}))\\ =\varphi(a) \times \varphi(b) \]

5证明1:\(对于质数p,若n\%p=0,则\varphi(n\times p)=\varphi(n)\times p\)

\[设n=p_1^{c_1}p_2^{c_2}\cdots p_n^{c_n}\\ \because n\%p=0\\ \therefore lcm(n,p)=n\\ \therefore \varphi(n\times p)=p\times n(1-\frac 1 {p_1})(1-\frac 1 {p_2})\cdots (1-\frac 1 {p_n})=\varphi(n)\times p \]

证明2:\(对于质数p,若n\%p!=0,则\varphi(n\times p)=\varphi(n)\times (p-1)\)

\[\because p是质数\\ \therefore \varphi(p)=p-1,p与n互质\\ \therefore \varphi(n\times p)=\varphi(n)\times \varphi(p)=\varphi(n)\times (p-1) \]

7证明: \(\sum_{d\vert n} \varphi(d)=n\)

\[设 f(n)=\sum_{d\vert n} \varphi(d)\\ \because f(n\times m)=\sum_{d\vert nm} \varphi(d)=\sum_{d\vert n} \varphi(d)\cdot\sum_{d\vert m} \varphi(d)=f(n) \times f(m)\\ \therefore f(x)是积性函数\\ f(p^m)=\sum_{d|p^m} \varphi(d)=\varphi(p^0) + \varphi(p^1) + \cdots + \varphi(p^m)=1+(p^1-1)+(p^2-p^1)+\cdots +(p^m-p^{m-1})=p^m\\ 设n=p_1^{c_1}p_2^{c_2}\cdots p_n^{c_n}\\ \therefore f(n)=f(p_1^{c_1}p_2^{c_2}\cdots p_n^{c_n})=f(p_1^{c_1})f(p_2^{c_2})\cdots f(p_n^{c_n})=p_1^{c_1}p_2^{c_2}\cdots p_n^{c_n}=n \therefore \sum_{d\vert n} \varphi(d)=f(n)=n \]

标签:frac,函数,sum,varphi,times,cdots,therefore,证明,欧拉
From: https://www.cnblogs.com/lyz09-blog/p/Prove-PhiFunction.html

相关文章

  • python 函数是对象
    defhi(name="yasoob"):return"hi"+nameprint(hi())#output:'hiyasoob'#我们甚至可以将一个函数赋值给一个变量,比如greet=hi#我们这里没有在使用小括号,因为我们并不是在调用hi函数#而是在将它放在greet变量里头。我们尝试运行下这个print(greet())#out......
  • php升级 编译安装php7 支持openeuler欧拉
    php版本下载包查询:https://www.php.net/releases/ yum-yinstallcmakelibxml2libxml2-developensslopenssl-develcurl-devellibjpeg-devellibpng-develfreetype-devellibziplibzip-devellibsodiumsqlitesqlite-develonigurumaoniguruma-devellibwebp-devel......
  • 【go】go语言变量类型 常量 函数基础 函数高级 setuptools将python项目打包 前后端联
    目录昨日回顾使用setuptools将python项目打包前后端联调今日内容1go语言变量类型2常量3函数基础4函数高级补充昨日回顾使用setuptools将python项目打包#https://zhuanlan.zhihu.com/p/624648232#python----》setuptools--》whl包结构 公司内部写了包---》公司内部用---......
  • 第七章:函数
    学习要点:1.函数声明2.return返回值3.arguments对象 函数是定义一次但却可以调用或执行任意多次的一段JS代码。函数有时会有参数,即函数被调用时指定了值的局部变量。函数常常使用这些参数来计算一个返回值,这个值也成为函数调用表达式的值。一.函数声明函数对任何语言来说都是......
  • STM32F407 宏定义实现函数错误返回
    开发环境:Window10+MDK+STM32F407实现目的:针对在函数内部需要对各个执行的子函数判断错误返回的场合,用宏定义替换繁琐的编码代码实现:1/*这种写法怎样注册宏定义,故障返回批量处理注册函数不能写在线程内部*/2#defineET_(...)if(!__VA_ARGS__)......
  • 函数高级、包的使用、if-else、循环、switch、数组
    目录1函数高级2包的使用3if-else4循环5switch6数组1函数高级packagemainimport"fmt"//1函数的参数和返回值都是类型的一部分,函数可以赋值给一个变量//test3函数,接收一个参,参数是函数类型:没有参数没有返回值//test有返回值,返回值是个函数:函数有两个参数,一......
  • 我的C++常用函数
    /*根据多个分隔符来分隔字符串.比如":,]"*/std::vector<std::string>SplitString(conststd::string&str,conststd::string&delimiters){std::vector<std::string>tokens;size_tprev=0,pos;while((pos=str.find_first_of(d......
  • 12 | C语言中的函数类型和函数指针类型
    函数类型和函数指针类型的区别,让我们先看一个例子#include<iostream>usingnamespacestd;typedefint(Func)(int);typedefint(*Func_p)(int);intf(inta){returna;}intmain(){Func_pp=f;Func*p_ptr=f;cout<<p(0)<<endl;cout<<p_ptr(1)......
  • pid算法函数实现,c语言版
     #include<stdio.h>floatpid(floatsetpoint,floatprocess_variable,floatkp,floatki,floatkd,floatdt,float*integral,float*last_error){//Calculateerrorfloaterror=setpoint-process_variable;//Calculateintegral......
  • PB常用函数
    弹出窗口:messagebox()基本写法:Messagebox('标题','内容')完整写法: MessageBox('标题','内容',图标,按键,默认值)           (1)其中标题与内容为要显示的字符串,不可省略,但可以省略,即什么也不显示,例如Messagebox('','')这样也是正确的单里面的东西一样也不能少!   ......