Right now I have a problem with one mathematical problem that has been troubling me. What I need to do is to find values of x and y for which x and y are whole numbers. The equation is:

6xy - x - y - 6142 = 0

My friend tells me that it is impossible to solve without having the another equation (which I could not derive). So the only method left is to use "trial and error" which is pretty time consuming.

So my question now is whether there is a better method than "trial and error" for the finding the values of x and y which are whole numbers for the above equation.

PS: The negative values of x and y are of no importance to me, though I know they exist. If anyone need a graph of the equation, I can post it.
Posted on 2003-09-30 07:23:42 by roticv
I would think that you would pick a value for x and solve for y, or pick a value for y and solve for x. It's an equation that will have many correct answers.

Just a guess.
Posted on 2003-09-30 09:16:39 by djinn
It seems like your equation is a kind of diophantine eq. Search for it!:)
And please post your graph.
Posted on 2003-09-30 09:26:42 by inFinie

For your method, you just need to "try" a value of x (whole number) and see if y is a whole number. But isn't this the "trial and error" I spoke of. It just too time consuming if your number has over 100 digits.

Interesting, I have never heard of a diophantine equation, I will try to do some research on it. Thanks for sheding some light to me anyway. Here's the graph for the equation, sure it does look like 1/x graph
Posted on 2003-09-30 09:54:34 by roticv
I think that the diophantine equasion was the try-method you specified :)
I studied it in 4th grade, I don't remember it now :grin:
Posted on 2003-09-30 14:54:36 by Ultrano
y=(6142 5/6)/(6x-1)+1/6

The only to solve this is by factoring 36851. If you get at least two factors who can be written as 6n-1, you can get all the solutions by combining them with the remaining factors.
Posted on 2003-09-30 18:35:01 by Sephiroth3

Here's the graph for the equation, sure it does look like 1/x graph

Well not really. Not sure where or how you obtained it, but its really the shape of the solution (an may even be the solution, didnt test with a point from your graph).

Your equation is what is called a "Parametric Equation". Its a function of many variables. To solve this takes partial derivatives, and some vector math with the gradiant function. Been a couple years since i've done this and am not going to try now (will take me all night to refresh those forgotten skills ;) ).

So in short, i will instead show you the true graph to your question below:

z = 6xy - x - y - 6142 = 0 is your problem. Find a function of x,y such z = 0. Or in other terms, F(x,y,z) = 6xy - x - y - 6142 - z. This is a 3D plot!
Posted on 2003-10-01 18:13:08 by NaN
When you rotate it on the corner between x and y and look parallel to the (x,y) plane you will see:
Posted on 2003-10-01 18:14:24 by NaN
If you now look a the 0 value on the Z axis it cuts through the edges and misses the center of the surface. if you were to take a SLICE at z = 0 on the shown image(s) you will end up with a 2 dimentions plot similar to your origional graph.

Weather or not you plot is the slice at the Z = 0 is yet to be determined by me. But eazy to check. pick any point on the curve. And stuff its values into the origional equation. If the answer is 0 you have your solution set (any point on the curve).

Posted on 2003-10-01 18:17:39 by NaN
NaN, the problem is to find a solution such that X and Y are whole numbers.
Posted on 2003-10-01 18:29:13 by iblis
Which is the same as all the graph points (x, y, 0) where x and y are both whole numbers.

Since the original problem equation had "=0" in it and only x and y, the problem can also be restated as finding the zeros of z = f(x,y). Which is the "slice" at z=0. Which is what roticv's graph shows.

There are approximately 6100 integers between 0 and 36853 of the form 6x-1. The solution is easily brute forced with a computer. (Are we allowed to do this?) Pick an x, solve for y, if y is an integer, (x, y) is one solution. Because of symmetry, (y, x) is also a solution.
Posted on 2003-10-01 19:47:48 by tenkey
Iblis, whats your point? What i outlined above will give you such, if one exists.
Posted on 2003-10-01 19:48:53 by NaN
Hey guys, thanks for your reply, I will think about them.
Posted on 2003-10-02 01:17:13 by roticv