10 for Tot=3 to 1000
20 for X=2 to int(Tot/2)
30 Xp=X^X
40 Y=Tot-X
50 Yp=Y^Y
60 Prod=Xp*Yp
70 Low=2:High=2*Y
72 while log(High)*High<=log(Prod)
73 inc High
74 wend
85 repeat
90 M=int((Low+High)/2)
95 M2=M^M
100 if M2>Prod then High=M-1
110 if M2<Prod then Low=M+1
120 until Low>High or M2=Prod
130 Z=M
210 Z=int(Z+0.5)
220 if Z^Z=Prod then print X;Y;Z,X^X;Y^Y,Prod,Z^Z:inc Solct
225 if Solct>30 then end
230 next X
240 next Tot
does not find any solutions up to the point where the total of x and y reaches 595 and the product of x^x * y^y reaches
1983978175966114206105992795156965609830078354477006722055266903216207615848029
70995127753831672467947056009777276939232774901947206435565141972385217470939481
58230540485333531628612973217479276245706045866659680030506543343377953660813355
98908717311537773431730447450224917774560173379960741291730503940290267402949770
17015036642965390235605716431064138034607205905571246810274527919092089919515152
91200628496356429580061439275187419123643114364914113537174420360873691875221452
88315895330644728410273603286239351660712838121526566104825966889641346086117438
37700106539029768716299516367993120638172780125849247927191324126028678811950797
21927924877302487655042933245733145167133551069001073090763852912657043050641179
80576476464324968601241075757564647504969094963804249073889516408965602009667893
06425635410208577871652184935516292157826517111059626532788754192169720012614988
27613417925565957220857225669488301292064803996390565306121012136732250199355731
05962373530010533152443757459033975758449360627666467252351862946890846389142156
06331281250000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000
where x=5 and y=590.
All possible totals of x and y up through 594 were searched for solutions, using a binary search through z values that might fit.
|
Posted by Charlie
on 2014-07-04 11:51:38 |