上一页 1 ··· 8 9 10 11 12 13 下一页
摘要: 一、题目 We say that integer x, 0 < x < p, is a primitive root modulo odd prime p if and only if the set { (x i mod p) | 1 <= i <= p-1 } is equal to { 1, 阅读全文
posted @ 2018-10-06 16:03 Dybala21 阅读(234) 评论(0) 推荐(0)
摘要: 一、题目 Given n, a positive integer, how many positive integers less than n are relatively prime to n? Two integers a and b are relatively prime if there 阅读全文
posted @ 2018-10-06 15:06 Dybala21 阅读(180) 评论(0) 推荐(0)
摘要: 一、引文 1.欧拉函数:指不超过n且与n互素的正整数的个数,其中,n是一个正整数。 二、相关知识 1.算数函数:定义在所有正整数上的函数称为算数函数。 2.乘性函数(积性函数):对算数函数ƒ 如果满足对任意两个互素的正整数n和m,均有ƒ(nm)=ƒ(n)ƒ(m)。 3.完全乘性函数(完全积性函数): 阅读全文
posted @ 2018-10-06 12:03 Dybala21 阅读(466) 评论(0) 推荐(0)
摘要: 引文:如果要对比较大的整数分解,显然之前所学的筛选法和是试除法都将不再适用。所以我们需要学习速度更快的Pollard_Rho算法。 算法原理: 生成两个整数a和b,计算p=gcd(a-b, n),知道p不为1或a,b出现循环为止,若p=n,则n为质数,否则p为n的一个约数。 对于如何生成这两个数,选 阅读全文
posted @ 2018-10-04 20:00 Dybala21 阅读(351) 评论(0) 推荐(0)
摘要: 定义:给出一个正整数,将其携程几个素数的乘积,这个过程称为整数分解。 例题:HDU_1164 https://vjudge.net/problem/HDU-1164 一、试除法 算法:令m = n,从2~sqrt(N) 一一枚举,如果当前数能够整除m,那么当前数就是n的素因子,并用整数m将当前数除尽 阅读全文
posted @ 2018-10-04 10:34 Dybala21 阅读(617) 评论(0) 推荐(0)
摘要: 引语:在数论中,对于素数的研究一直就很多,素数测试的方法也是非常多,如埃式筛法,6N±1法,或者直接暴力判(试除法)。但是如果要判断比较大的数是否为素数,那么传统的试除法和筛法都不再适用。所以我们需要学习Miller_Rabin算法。 知识准备 + 算法推导: 1.威尔逊定理:若p是素数,则 (p- 阅读全文
posted @ 2018-10-04 09:37 Dybala21 阅读(442) 评论(0) 推荐(0)
摘要: 题目: 十年前读大学的时候,中国每年都要从国外引进一些电影大片,其中有一部电影就叫《勇敢者的游戏》(英文名称:Zathura),一直到现在,我依然对于电影中的部分电脑特技印象深刻。 今天,大家选择上机考试,就是一种勇敢(brave)的选择;这个短学期,我们讲的是博弈(game)专题;所以,大家现在玩 阅读全文
posted @ 2018-09-23 10:51 Dybala21 阅读(123) 评论(0) 推荐(0)
摘要: 题目: Mr. F has nn positive integers, a1,a2,…,an. He thinks the greatest common divisor of these integers is too small. So he wants to enlarge it by rem 阅读全文
posted @ 2018-09-23 10:20 Dybala21 阅读(156) 评论(0) 推荐(0)
摘要: 题目: There are nn points on the plane, (x1,y1),(x2,y2),…,(xn,yn)(x1,y1),(x2,y2),…,(xn,yn). You need to place an isosceles triangle with two sides on th 阅读全文
posted @ 2018-09-23 10:05 Dybala21 阅读(230) 评论(0) 推荐(0)
摘要: 题目: 题目: Little C loves number «3» very much. He loves all things about it. Now he has a positive integer nn. He wants to split nn into 3 positive inte 阅读全文
posted @ 2018-09-23 09:49 Dybala21 阅读(126) 评论(0) 推荐(0)
上一页 1 ··· 8 9 10 11 12 13 下一页