 All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars  perplexus dot info  More about 1729 (Posted on 2012-01-04) Much was said about 1729 a.k.a. Ramanujan number.or a taxicab number.
1729 is also a Carmichael number and the first absolute Euler pseudoprime, a sphenic number, a Zeisel number etc etc

Ā Please note the following (and solve):
Ā 1. 1729 is one of four positive integers (with the others being A, B and the trivial case 1) which, when its digits are added together, produces a sum which, when multiplied by its reversal, yields the original number:
1 + 7 + 2 + 9 = 19 ; 19*91 = 1729
Find A and B.

2. 1729= xyz, where x,y and z are integer members of an arithmetic progression.
Find these members.

3. 1729 can be expressed (in more than one way) as a sum of distinct Fibonacci numbers
List all the expressions.
Ā

 See The Solution Submitted by Ady TZIDON Rating: 5.0000 (3 votes) Comments: ( Back to comment list | You must be logged in to post comments.) re(3): computer solution | Comment 5 of 8 | (In reply to re(2): computer solution by Daniel)

The revised program below allows for both 1's to be used:

DECLARE SUB addon (wh#)
CLEAR , , 25000
DEFDBL A-Z
DIM SHARED sum
CLS

FOR sum = 2 TO 99999
s\$ = LTRIM\$(STR\$(sum))
r\$ = ""
FOR i = 1 TO LEN(s\$)
r\$ = MID\$(s\$, i, 1) + r\$
NEXT
rev = VAL(r\$)
prod = sum * rev
p\$ = LTRIM\$(STR\$(prod))
sum2 = 0
FOR i = 1 TO LEN(p\$)
sum2 = sum2 + VAL(MID\$(p\$, i, 1))
NEXT
IF sum = sum2 THEN
PRINT sum; rev; prod
END IF
NEXT

PRINT : PRINT

part3:
DIM SHARED fib(20), hs(20), sumto(20), solct
fib(0) = 1: fib(1) = 1
FOR i = 2 TO 20
fib(i) = fib(i - 2) + fib(i - 1)
IF fib(i) > 1729 THEN EXIT FOR
NEXT: PRINT
maxsub = i - 1

sum = 0: leastStart = 0
FOR i = 0 TO maxsub
sum = sum + fib(i): sumto(i) = sum
IF sum > 1729 AND leastStart = 0 THEN leastStart = i - 1
NEXT

FOR st = leastStart TO maxsub
hs(1) = st: sum = fib(st)
addon 2
NEXT
PRINT solct

SUB addon (wh)
newstart = hs(wh - 1) - 1
FOR try = newstart TO 0 STEP -1
IF sum + sumto(try) < 1729 THEN EXIT FOR
hs(wh) = try
sum = sum + fib(try)
IF sum = 1729 AND (hs(wh) <> 0 OR hs(wh - 1) = 1) THEN
FOR i = 1 TO wh
PRINT fib(hs(i));
NEXT
PRINT
solct = solct + 1
ELSE
IF sum < 1729 THEN
addon wh + 1
END IF
END IF
sum = sum - fib(try)
NEXT
END SUB

The revised list it finds is:

987  610  89  34  8  1
987  610  89  34  5  3  1
987  610  89  34  5  2  1  1
987  610  89  21  13  8  1
987  610  89  21  13  5  3  1
987  610  89  21  13  5  2  1  1
987  610  55  34  21  13  8  1
987  610  55  34  21  13  5  3  1
987  610  55  34  21  13  5  2  1  1
987  377  233  89  34  8  1
987  377  233  89  34  5  3  1
987  377  233  89  34  5  2  1  1
987  377  233  89  21  13  8  1
987  377  233  89  21  13  5  3  1
987  377  233  89  21  13  5  2  1  1
987  377  233  55  34  21  13  8  1
987  377  233  55  34  21  13  5  3  1
987  377  233  55  34  21  13  5  2  1  1
987  377  144  89  55  34  21  13  8  1
987  377  144  89  55  34  21  13  5  3  1
987  377  144  89  55  34  21  13  5  2  1  1
1597  89  34  8  1
1597  89  34  5  3  1
1597  89  34  5  2  1  1
1597  89  21  13  8  1
1597  89  21  13  5  3  1
1597  89  21  13  5  2  1  1
1597  55  34  21  13  8  1
1597  55  34  21  13  5  3  1
1597  55  34  21  13  5  2  1  1

in agreement with the previous posts.

 Posted by Charlie on 2012-01-04 15:03:09 Please log in:
 Login: Password: Remember me: Sign up! | Forgot password

 Search: Search body:
Forums (0)
Newest Problems
Random Problem
FAQ | About This Site
Site Statistics
New Comments (1)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

Chatterbox:
Copyright © 2002 - 2019 by Animus Pactum Consulting. All rights reserved. Privacy Information