We have 2 general term of A.P. as
Tn = a + (n - 1) * b
Fm = b + (m - 1) * d
Solving Tn = Fm
nb - md = b - d - a + b
which then i interpreted as Ax - By = C
ans solved using linear diophantine equation, but i am not getting the first intersection point
for eg. let a = 52 , b = 39, c = 78, d = 88
using above method i am getting solution as 207 92 which is not even a solution to given equation.
I am directly using the implementation of cp-algorithm.