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

Home > Just Math
Very Large Triangles (Posted on 2019-11-21) Difficulty: 4 of 5
How many different triangles with integer side lengths are there such that the sum of the lengths of any 2 sides is at least 5 units more than the length of the third side, and that the area is numerically twice the perimeter?

No Solution Yet Submitted by Danish Ahmed Khan    
No Rating

Comments: ( Back to comment list | You must be logged in to post comments.)
Solution Solution | Comment 1 of 3
I found 8

 x  y  z area perim
 9 40 41 180  90
 9 75 78 324 162
10 24 26 120  60
10 35 39 168  84
11 25 30 132  66
12 16 20  96  48
13 14 15  84  42
15 15 24 108  54

I haven't proved that there are none for triangles with a side larger than 1,000.

Code follows:

count = 0
threshold = .0001
print('  x  ' , 'y   ' , 'z ' , 'diff,' , 'area,' ,  'perimeter')
for x in (range(1,1000)):
    for y in (range(x,1000)):
        for z in (range(y,1000)):
            if x+y-z < 5:
                continue

            s = (x+y+z)/2
            area = ((s*(s-x)*(s-y)*(s-z))**.5)

            if abs(area - 2*(x+y+z)) < threshold:
                    print(x , y,  z,  int(area), x+y+z)
                    count += 1
           
print('number of solutions is: ', count)


Edited on November 21, 2019, 11:26 am
  Posted by Larry on 2019-11-21 11:14:56

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 (11)
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