{3,3,3,3,3,3} is a set of six integers such that the sum of the squares of the reciprocals totals 2/3.
(1/3)^2 + (1/3)^2 + (1/3)^2 + (1/3)^2 + (1/3)^2 + (1/3)^2 = 2/3
Does there exist a set of integers with fewer than 6 members whose sum of the squares of the reciprocals totals 2/3?
Problem inspired by
Find the triplets
computer, brute force:
2 2 3 6 6 (also - no solutions found for 4 fractions)
program cub
implicit none
integer i1,i2,i3,i4,i5,itol,itop,itell
real x1,x2,x3,x4,x5,a2,a3,a4,sum,tt,err
itell=10
tt=2./3.
itop=200
itol=6
err=10.**(-itol)
do 1 i1=2,itop
if((i1/itell)*itell.eq.i1)print*,i1, 'out of ',itop
x1=1./i1**2
do 2 i2=2,itop
x2=1./i2**2
a2=x1+x2
if(a2.gt.tt) go to 2
do 3 i3=2,itop
x3=1./i3**2
a3=a2+x3
if(a3.gt.tt)go to 3
do 4 i4=1,itop
x4=1./i4**2
a4=a3+x4
if(a4.gt.tt)go to 4
do 5 i5=2,itop
x5=1./i5**2
sum=a4+x5
if(sum.gt.tt)go to 5
if(abs(sum-tt).lt.err)then
print*,i1,i2,i3,i4,i5
stop
endif
5 enddo
4 enddo
3 enddo
2 enddo
1 enddo
end
Edited on August 25, 2020, 10:05 am