Creating a system of equations consisting only of integers?

AI Thread Summary
To create a simple system of equations with integer solutions, one approach involves using determinants to ensure that the solutions for x1 and x2 remain integers. The key is to ensure that the numerators of the expressions for x1 and x2 are multiples of the common denominator. For generating random equations, selecting integer values for coefficients and then calculating the constants can be effective. Additionally, exploring concepts like Euclid's lemma and linear Diophantine equations can provide further insights into constructing such systems. Overall, clarity in variable naming is essential to avoid confusion in the equations.
friedrice821
Messages
2
Reaction score
0
I'm looking for an algorithm to create a very simple (2 equations, 2 unknowns) linear system of equations that consists purely of integers. Specifically, a way to create a system of equations of integers and knowing that it can only be solved by integer answers, without actually solving it.

a11x1+a12x2=b1
a21x1+a22x2=b2
where a11, a12, a21, a22, x1, x2, b1, b2 are all integers.

The only thing I can think of is using a determinant which gives
x1 = (a22b1-a12b2) / (a11a22-a12a21)
x2 = (a11b2-a21b1) / (a11a22-a12a21)
and that the numerator must be a multiple of the denominator.

What do I do now? Am I even on the right path?
 
Last edited:
Mathematics news on Phys.org
You don't say why you want to do this, but if you want to geerate "random" questions for an online test or something similiar, the easy way is to just pick a, b, c, d, x1 and x2, and then work out y1 and y2.

If this is a more general question, look up "euclid's lemma" and linear Diophantine equations, e.g. http://en.wikipedia.org/wiki/Euclidean_algorithm
 
Thanks! the Diophantine equations really helped.
 
By the way, I wish you hadn't used y1 and y2...it just throws a curve ball as to they are supposed to be known constants or unknowns...maybe you should simply use a couple of more letters?

...just being picky.
 
Fermat's Last Theorem has long been one of the most famous mathematical problems, and is now one of the most famous theorems. It simply states that the equation $$ a^n+b^n=c^n $$ has no solutions with positive integers if ##n>2.## It was named after Pierre de Fermat (1607-1665). The problem itself stems from the book Arithmetica by Diophantus of Alexandria. It gained popularity because Fermat noted in his copy "Cubum autem in duos cubos, aut quadratoquadratum in duos quadratoquadratos, et...
Insights auto threads is broken atm, so I'm manually creating these for new Insight articles. In Dirac’s Principles of Quantum Mechanics published in 1930 he introduced a “convenient notation” he referred to as a “delta function” which he treated as a continuum analog to the discrete Kronecker delta. The Kronecker delta is simply the indexed components of the identity operator in matrix algebra Source: https://www.physicsforums.com/insights/what-exactly-is-diracs-delta-function/ by...
Thread 'Imaginary Pythagorus'
I posted this in the Lame Math thread, but it's got me thinking. Is there any validity to this? Or is it really just a mathematical trick? Naively, I see that i2 + plus 12 does equal zero2. But does this have a meaning? I know one can treat the imaginary number line as just another axis like the reals, but does that mean this does represent a triangle in the complex plane with a hypotenuse of length zero? Ibix offered a rendering of the diagram using what I assume is matrix* notation...
Back
Top