[中译] ProjectEuler 456 Triangles containing the ori

楼主: tml (流刑人形)   2014-02-25 07:16:15
456. Triangles containing the origin II
http://projecteuler.net/problem=456
定义:
x_n = (1248^n mod 32323) - 16161
y_n = (8421^n mod 30103) - 15051
P_n = {(x_1, y_1), (x_2, y_2), ..., (x_n, y_n)}
例如,P_8 = {(-14913, -6630), (-10161, 5625), (5226, 11896), (8340, -10778),
(15852, -5203), (-15165, 11295), (-1427, -14495), (12407, 1060)}。
令C(n)为三顶点都在P_n上且包含原点在其内部的三角形的个数。
例如:
C(8) = 20
C(600) = 8950634
C(40000) = 2666610948988
请求出C(2000000)。

Links booklink

Contact Us: admin [ a t ] ucptt.com