Assume we have a finite list of indices of the form $(i+B*\alpha)$, where B is a positive integer constant. The variables $i,\alpha$ are also restricted to positive integers. In particular, $i \in [1,N]$ and $\alpha \in [0,M-1]$, with $M>N>B$.
The elements in our list respect the three following constraints:
1) Two and only two elements in the list have the same first term ($i$ above).
2) Two and only two elements in the list have the same second term ($\alpha$ above)
3) No two elements have the same first AND second term.
For example, a valid such list would be:
[$i+\alpha*B, j+\alpha*B, j+\beta*B, k+\beta*B, k+\gamma*B, l+\gamma*B, l+\delta*B, i+\delta*B$].
Now, we construct a system of diophantine equations equating these indices in pairs. One such system for a list of 6 elements would look like:
$i + \alpha*B = j + \alpha*B$
$j + \beta*B = k + \beta*B$
$k + \gamma*B = i + \gamma*B$
The above example is trivial, as equating indices with same first or second term result in Kroneker $\delta$s and these make our job much simpler when it comes to counting solutions.
My question is: is there a clever way of counting the number of solutions to systems of diophantine equations constructed in this way as a function of N,B,M and the (even) number of elements in the original list? I was able to do such counting for lists up to 6 elements with some handwaving reasoning based on matrix null spaces but I would appreciated if someone could suggest a more general approach. Thanks a lot!