-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathkryptos-k4-sage.txt
35 lines (31 loc) · 1.38 KB
/
kryptos-k4-sage.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
# p A B C E H I K L N O R S T
# c F G K L M N P Q R S T V Y Z
R.<pA,pB,pC,pE,pH,pI,pK,pL,pN,pO,pR,pS,pT,cF,cG,cK,cL,cM,cN,cP,cQ,cR,cS,cT,cV,cY,cZ,k21,k22,k23,k24,k25,k26,k27,k28,k29,k30,k31,k32,k33,k63,k64,k65,k66,k67,k68,k69,k70,k71,k72,k73> = PolynomialRing(ZZ)
gens = [pE + k21 - cF,pA + k22 - cL,pS + k23 - cR,pT + k24 - cV,pN + k25 - cQ,pO + k26 - cQ,pR + k27 - cP,pT + k28 - cR,pH + k29 - cN,pE +k30 - cG,pA + k31 - cK,pS + k32 - cS,pT + k33 - cS,pB + k63 - cN,pE + k64 - cY,pR + k65 - cP,pL + k66 - cV,pI + k67 - cT,pN + k68 - cT,pC+k69 - cM,pL + k70 - cZ,pO + k71 - cF,pC + k72 - cP,pK + k73 - cK]
J=R.ideal(gens)
#J.elimination_ideal([pA,pB,pC,pE,pH,pI,pK,pL,pN,pO,pR,pS,pT,cF,cG,cK,cL,cM,cN,cP,cQ,cR,cS,cT,cV,cY,cZ])
J.groebner_basis().ideal()
# pA - cL + k22
# pB - cN + k63
# pC - cP + k72
# pE - cY + k64
# pH - cN + k29
# pI - cY - k21 + k25 - k26 + k64 + k67 - k68 + k71
# pK - cL + k22 - k31 + k73
# pL - cZ + k70
# pN - cY - k21 + k25 - k26 + k64 + k71
# pO - cY - k21 + k64 + k71
# pR - cP + k65
# pS - cZ + k24 + k32 - k33 - k66 + k70
# pT - cZ + k24 - k66 + k70
# cF - cY - k21 + k64
# cG - cY - k30 + k64
# cK - cL + k22 - k31
# cM - cP - k69 + k72
# cQ - cY - k21 - k26 + k64 + k71
# cR - cZ + k24 - k28 - k66 + k70
# cS - cZ + k24 - k33 - k66 + k70
# cT - cY - k21 + k25 - k26 + k64 - k68 + k71
# cV - cZ - k66 + k70
# k23 - k28 - k32 + k33
# k27 - k65