All about flooble | fun stuff | Get a free chatterbox | Free JavaScript | Avatars    
perplexus dot info

Home > Just Math
A! + B! + C! = 3D (Posted on 2009-08-27) Difficulty: 2 of 5
Determine all possible quadruplet(s) (A, B, C, D) of nonnegative integer(s), with A < B < C, that satisfy this equation:

A! + B! + C! = 3D

See The Solution Submitted by K Sengupta    
Rating: 5.0000 (1 votes)

Comments: ( Back to comment list | You must be logged in to post comments.)
Spreadsheet & Computer without proof | Comment 2 of 5 |
 I had determined the table below using an Excel spreadsheet considering they were the only values, but I cannot really provide a reason for making that assumption.

I further decided to write a QuickBasic to test my findings. That appears below.

Factorial
range       Sum          Cube Power
 0  0  0      3                3      1
 0  0  1      3                3      1
 0  1  1      3                3      1
 0  2  3      9                9      2
 0  2  4      27              27     3
 1  1  1      3                3      1
 1  2  3      9                9      2
 1  2  4      27              27     3

However there is the consideration that A < B < C and those values are only in the last two lines of my table making the required sets: {1, 2, 3, 2} and {1, 2, 4, 3}.

Having read the comment by Dej Mar , which follows this one, I note that in oversight I did miss two quadruplets, they appear in lines 4 and 5 of the table, {0, 2, 3, 2} and {0, 2, 4, 3}.

Note that the QuickBasic does not seek to eliminate values but just confirms my table.

QuickBasic does not have a factorial function so I had to 'invent' one.  The j, k and l For..Next loops do that service.

The variable "z" appears as the upper limit of 4 For..Next loops.  I decided to make just one point of value change rather than 4.

DEFDBL A-Z
OPEN "cubfact.txt" FOR OUTPUT AS #1

 z = 20
CLS

Rem initial values for factorials to ensure 0! =1
m = 1: n = 1: o = 1   

FOR a = 0 TO z
FOR b = a TO z
FOR c = b TO z
FOR d = 0 TO z

Rem Compute the respective factorials, loops must begin at 1 else m, n and o would always be zero.
FOR j = 1 TO a: m = m * j: NEXT
FOR k = 1 TO b: n = n * k: NEXT
FOR l = 1 TO c: o = o * l: NEXT

sum = m + n + o
cube = 3 ^ d

IF sum = cube THEN
     PRINT      a; b; c; "    "; sum, "  "; cube; d
     PRINT #1, a; b; c; "    "; sum, "  "; cube; d
END IF
m = 1: n = 1: o = 1

NEXT
NEXT
NEXT
NEXT
CLOSE 1


Edited on August 28, 2009, 9:47 pm
  Posted by brianjn on 2009-08-27 22:46:37

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 (24)
Unsolved Problems
Top Rated Problems
This month's top
Most Commented On

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