1

Sorry it can be silly but i am stuck and can't get my head around this.

I have an equation like;

$b = \frac{qc}{p} + \frac{p}{2}$

Now $p$ and $q$ are known integer values whereas $b$ and $c$ are the variables. How can I test on $p$ and $q$ that the equation allows integer $b$ and $c$?

RobPratt
  • 45,619
Redu
  • 231
  • 1
    If $p | q$, and $p$ is even, there are infinitely-many solutions for $b$ and $c$. – Doug Jun 18 '22 at 19:06
  • 1
    Scaling by $p$ yields a bivariate linear diophantine equation whose solvability condition is well known - see here in the linked dupe, viz. $,pb-qc = n,$ has integer solutions $,b,c\iff \gcd(p,q)\mid n\ \ $ – Bill Dubuque Jun 18 '22 at 19:11
  • @BillDubuque Thanks. – Redu Jun 18 '22 at 19:12

0 Answers0