a^2+ab+b^2=c^2的整数解
a^2+ab+b^2=c^2的所有整数解有通项公式吗?
比如
7,8,13是一组解答 一般都是考虑对于哪些c有解 我给出mathematica的代码,能够找到一部分解答.
暴力求解
(*求整数解答*)
Do};(*调用reduce函数求解*)
If,(*如果解答存在的话*)
outabc={a,b,c}/.out;(*去掉a->这类符号,只保留结果*)
Map(*通过映射打印出所有解答*)
],
{n,0,200}
]
求解结果.
{3,5,7}
{7,8,13}
{6,10,14}
{5,16,19}
{9,15,21}
{14,16,26}
{12,20,28}
{11,24,31}
{15,25,35}
{7,33,37}
{10,32,38}
{21,24,39}
{18,30,42}
{13,35,43}
{16,39,49}
{21,35,49}
{28,32,52}
{24,40,56}
{15,48,57}
{9,56,61}
{22,48,62}
{27,45,63}
{35,40,65}
{32,45,67}
{30,50,70}
{17,63,73}
{14,66,74}
{20,64,76}
{33,55,77}
{42,48,78}
{40,51,79}
{36,60,84}
{26,70,86}
{11,85,91}
{19,80,91}
{39,65,91}
{49,56,91}
{33,72,93}
{25,80,95}
{55,57,97}
{32,78,98}
{42,70,98}
{40,77,103}
{56,64,104}
{45,75,105}
{24,95,109}
{21,99,111}
{48,80,112}
{30,96,114}
{63,72,117}
{51,85,119}
{18,112,122}
{44,96,124}
{54,90,126}
{13,120,127}
{39,105,129}
{70,80,130}
{23,120,133}
{35,112,133}
{57,95,133}
{65,88,133}
{64,90,134}
{69,91,139}
{60,100,140}
{77,88,143}
{34,126,146}
{48,117,147}
{63,105,147}
{28,132,148}
{56,115,151}
{40,128,152}
{66,110,154}
{55,120,155}
{84,96,156}
{25,143,157}
{80,102,158}
{69,115,161}
{75,112,163}
{72,120,168}
{15,161,169}
{91,104,169}
{45,144,171}
{52,140,172}
{75,125,175}
{104,105,181}
{22,170,182}
{38,160,182}
{78,130,182}
{98,112,182}
{27,168,183}
{35,165,185}
{66,144,186}
{81,135,189}
{50,160,190}
{32,175,193}
{110,114,194}
{105,120,195}
{64,156,196}
{84,140,196}
{56,165,199} 再加一个限制条件吧,
如果a=0或者b=0,这个解答是平凡的,没有意义的.
同时限制c>0
以及由于对称,限制a<b
以及
a与b互质!
综上:
0<a<b
c>0
GCD=1
这是几个求解条件 cn8888 发表于 2014-7-1 18:20
再加一个限制条件吧,
如果a=0或者b=0,这个解答是平凡的,没有意义的.
同时限制c>0
在上面的条件限制下:
(*求整数解答*)
Do==1,{a,b,c},Integers]};(*调用reduce函数求解*)
If,(*如果解答存在的话*)
outabc={a,b,c}/.out;(*去掉a->这类符号,只保留结果*)
Map(*通过映射打印出所有解答*)
],
{n,0,200}
]
求解结果如下:
{3,5,7}
{7,8,13}
{5,16,19}
{11,24,31}
{7,33,37}
{13,35,43}
{16,39,49}
{9,56,61}
{32,45,67}
{17,63,73}
{40,51,79}
{11,85,91}
{19,80,91}
{55,57,97}
{40,77,103}
{24,95,109}
{13,120,127}
{23,120,133}
{65,88,133}
{69,91,139}
{56,115,151}
{25,143,157}
{75,112,163}
{15,161,169}
{104,105,181}
{32,175,193}
{56,165,199}
\(\D a^2+ab+b^2=c^2 \implies \left(\frac a c\right)^2+\left(\frac a c\right)\left(\frac b c\right)+\left(\frac b c\right)^2=1\implies m^2+mn+n^2=1\)
令 \(n=km-1\),
可得到 \(m^2+m(km-1)+(km-1)^2=1\)
\((k^2+k+1)m^2-(2k+1)m=0\)
\(\D m=0;\ m=\frac{2k+1}{k^2+k+1}\) 对于$m=0$的情况,可得到一组通解$(0,k,k)$ cn8888 发表于 2014-7-1 18:23
在上面的条件限制下:
求解结果如下:
在上面的解答中,只有
{49, 91, 91, 133, 133, 169}
是合数
其中49与169是完全平方
91与133都是给出了两组解答 在c的可能解答中
{199, 211, 217, 217, 223, 229, 241, 247, 247, 259, 259, 271, 277, \
283, 301, 301, 307, 313, 331, 337, 343, 349, 361, 367, 373, 379, 397}
不是素数的
{217, 217, 247, 247, 259, 259, 301, 301, 343, 361}
要么是两组解答,要么是立方数或者平方数
页:
[1]
2