码迷,mamicode.com
首页 >  
搜索关键字:欧拉函数    ( 1054个结果
POJ 2773-Happy 2006(欧拉函数)
Happy 2006 Time Limit:3000MS     Memory Limit:65536KB     64bit IO Format:%I64d & %I64u Submit Status Practice POJ 2773 Appoint description:  System Crawler  (2015-04-06) Description ...
分类:移动开发   时间:2015-04-09 09:05:20    阅读次数:153
POJ 2478-Farey Sequence(筛选法求欧拉函数)
Farey Sequence Time Limit:1000MS     Memory Limit:65536KB     64bit IO Format:%I64d & %I64u Submit Status Practice POJ 2478 Appoint description:  System Crawler  (2015-04-01) Descript...
分类:其他好文   时间:2015-04-09 09:00:19    阅读次数:157
POJ 1284-Primitive Roots(欧拉函数求原根)
Primitive Roots Time Limit:1000MS     Memory Limit:10000KB     64bit IO Format:%I64d & %I64u Submit Status Practice POJ 1284 Appoint description:  System Crawler  (2015-04-06) Descripti...
分类:其他好文   时间:2015-04-07 10:00:02    阅读次数:178
POJ 2407-Relatives(求一个整数的欧拉函数值)
Relatives Time Limit:1000MS     Memory Limit:65536KB     64bit IO Format:%I64d & %I64u Submit Status Practice POJ 2407 Appoint description:  System Crawler  (2015-04-04) Description ...
分类:其他好文   时间:2015-04-07 09:58:44    阅读次数:139
[BZOJ 2186] [Sdoi2008] 沙拉公主的困惑 【欧拉函数】
题目链接:BZOJ - 2186题目分析题目要求出 [1, n!] 中有多少数与 m! 互质。(m #include #include #include #include #include using namespace std;typedef long long LL;const int MaxN...
分类:其他好文   时间:2015-04-07 09:40:37    阅读次数:171
The Euler function(欧拉函数筛)
这题用欧拉函数会超时,要用函数筛。解析:(转)定义:对于正整数n,φ(n)是小于或等于n的正整数中,与n互质的数的数目。 例如:φ(8)=4,因为1,3,5,7均和8互质。性质:1.若p是质数,φ(p)= p-1. 2.若n是质数p的k次幂,φ(n)=(p-1)*p^(k-1)。因为除了p...
分类:其他好文   时间:2015-04-06 14:02:36    阅读次数:146
费马小定理,欧拉函数
在证明这些定理之前先证明一个有意思的定理。 对于0 mod m,n mod m , 2n mod m, 3n mod m, 4n mod m... (m-1)n mod m对应解集序列 一定有 m/d份 0 d 2d 3d..m-d. (不一定按照顺序) 这样的解。 其中d = gcd(n...
分类:其他好文   时间:2015-04-05 06:37:03    阅读次数:155
算法模板——单个值欧拉函数
输入N,输出phi(N)这样的单个值欧拉函数程序一般见于部分数论题,以及有时候求逆元且取模的数不是质数的情况(逆元:A/B=A*Bphi(p)-1(mod p),一般常见题中p是质数,phi(p)-1=p-2)(Tip:我是来水经验的不解释,不过话说真的好久没写这个了TT) 1 var i:int6...
分类:编程语言   时间:2015-04-03 23:43:53    阅读次数:195
【BZOJ】【2005】【NOI2010】能量采集
欧拉函数 玛雅,我应该先看看JZP的论文的……贾志鹏《线性筛法与积性函数》例题一 这题的做法……仔细想下可以得到:$ans=2*\sum_{a=1}^n\sum_{b=1}^m gcd(a,b)-n*m$ 那么重点就在于算$\sum_{a=1}^n\sum_{b=1}^m gcd(a,b)$这...
分类:其他好文   时间:2015-04-03 18:54:56    阅读次数:201
【BZOJ】【2705】【SDOI2012】Longge的问题
欧拉函数/狄利克雷卷积/积性函数 2705: [SDOI2012]Longge的问题Time Limit: 3 SecMemory Limit: 128 MBSubmit: 1275Solved: 820[Submit][Status][Discuss]DescriptionLongge的数学成绩....
分类:其他好文   时间:2015-04-03 13:03:22    阅读次数:232
1054条   上一页 1 ... 82 83 84 85 86 ... 106 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!