If a and b are positive integers for which ab-6a+5b=373, what is the minimal possible value of |a-b|?
Perfect will be a=b, because |a−b|=>|a−a|=0 so for a=b we have:
a2−6a+5a−373=0 <=> a2−a−373=0
x=−b±√b2−4ac2a=> x=1±√1−4(1)(−373)2=>x=1±√14932=> x=1± 38.632
x1=39.632=19.81
x2=−37.632=−18.81 BUT because is negative rejected
so a=20 so 20b−120+5b=373 => b=19.72 its NOT integers so you try values until a,b integers
Finaly the answer is a=44 and b =13 like Guest says and can see it in this graph if you try values!
https://www.desmos.com/calculator/4fhytbda6x
Hope it helps!
ab - 6a + 5b = 373
We can write this as
ab - 6a + 5b - 30 = 373 - 30
(a + 5 ) ( b - 6 ) = 373 - 30
(a + 5) (b - 6) = 343
343 as a product of two factors =
1 * 343 or 343 * 1
7 * 49 or 49 * 7
So....we have the following possibilities for a, b
a b
338 7
2 55
44 13
So.... l a - b l minimized = l 44 - 13 l = 31