Story
Martians have been observing Aussie rules football matches from space with great curiosity. Having totally fallen in love with the game, they have been inspired to start their very own football league. However, being dim-witted creatures, they are unable to comprehend the scoring system.*
We know that in Aussie rules, a goal is worth 6 points (\$G=6\$) and a behind is worth 1 point (\$B=1\$). The Martians are cluey enough to work out that there are two types of scores, but not smart enough to realise that they can deduce the point values of these scores by analysing match outcomes. Undeterred, the International Olympus Mons Committee decrees that in all Martian rules football matches, the point values for goals and behinds (i.e. \$G\$ and \$B\$) will be chosen at random.
'Perfect' scores
When \$G = 6\$ and \$B = 1\$ (as in Aussie rules), there are exactly four integer pairs \$[g,b]\$ such that a team with \$g\$ goals and \$b\$ behinds has a score of \$gb\$ points. We will refer to \$[g,b]\$ pairs that satisfy $$gG+bB=gb$$ as perfect scores. The four perfect scores in Aussie rules are \$[g,b]=[2,12]\$, \$[3,9]\$, \$[4,8]\$, and \$[7,7]\$.
Challenge
Given two strictly positive integers \$G\$ and \$B\$ representing the point values of goals and behinds in a Martian rules football match, write a program or function that determines all possible perfect scores for that match. Rules:
- Input may be taken in any convenient format (pair of integers, list, string, etc.). You may not assume that \$G>B\$.
- Output may also be in any format, provided that the \$[g,b]\$ pairs are unambiguously identifiable (e.g. successive elements in a list or string). The order of pairs does not matter. You may output pairs in \$[b,g]\$ order instead provided that you state this in your answer. You may not output the total scores (the products \$gb\$) instead, because in general there are multiple non-perfect ways to achieve the same total score.
- Your program/function must terminate/return in finite time.
This is code-golf: the shortest submission (in bytes) in each language wins.
Test cases
Input -> Output
[6, 1] -> [[2, 12], [3, 9], [4, 8], [7, 7]]
[6, 2] -> [[3, 18], [4, 12], [5, 10], [6, 9], [8, 8], [14, 7]]
[1, 1] -> [[2, 2]]
[1, 6] -> [[7, 7], [8, 4], [9, 3], [12, 2]]
[7, 1] -> [[2, 14], [8, 8]]
[7, 5] -> [[6, 42], [10, 14], [12, 12], [40, 8]]
[13, 8] -> [[9, 117], [10, 65], [12, 39], [16, 26], [21, 21], [34, 17], [60, 15], [112, 14]]
* This problem never, ever, occurs on Earth.
This problem never, ever, occurs on Earth
. That's bold of you to assert that statement... I'm Australian and I sometimes struggle to comprehend our own scoring methods. \$\endgroup\$However, being dim-witted creatures, they are unable to comprehend the scoring system.
How are they dim-witted, given they've invented such a powerful telescope!? \$\endgroup\$