![](https://img-blog.csdnimg.cn/20201014180756913.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
欧拉
文章平均质量分 58
liluoyu_1016
这个作者很懒,什么都没留下…
展开
-
Bi-shoe and Phi-shoe LightOJ - 1370 欧拉打表
Bamboo Pole-vault is a massively popular sport in Xzhiland. And Master Phi-shoe is a very popular coach for his success. He needs some bamboos for his students, so he asked his assistant Bi-Shoe to go原创 2017-10-28 10:48:51 · 213 阅读 · 0 评论 -
莫比乌斯函数 51Nod - 1240
莫比乌斯函数,由德国数学家和天文学家莫比乌斯提出。梅滕斯(Mertens)首先使用μ(n)(miu(n))作为莫比乌斯函数的记号。(据说,高斯(Gauss)比莫比乌斯早三十年就曾考虑过这个函数)。 具体定义如下: 如果一个数包含平方因子,那么miu(n) = 0。例如:miu(4), miu(12), miu(18) = 0。 如果一个数不包含平方因子,并且有k个不同的质因子,那么miu原创 2018-01-29 11:21:13 · 176 阅读 · 0 评论 -
欧拉函数
1.求小于n与n互质的个数 int euler(int n) { int ret=1,i; for( i=2;i*i<=n;i++) { if(n%i==0) { ret*=i-1; n/=i; } while(n%i==0)原创 2017-08-02 16:01:52 · 238 阅读 · 0 评论 -
bzoj 2818 Gcd 线性筛欧拉+想法
Description 给定整数N,求1<=x,y<=N且Gcd(x,y)为素数的 数对(x,y)有多少对. Input 一个整数N Output 如题 Sample Input 4 Sample Output 4 HINT hint 对于样例(2,2),(2,4),(3,3),(4,2) 1<=N<=10^7 思路:假...原创 2018-08-18 17:21:44 · 140 阅读 · 0 评论