general geometric formula is
then we replace using A3
now replace using A5
now we have two equations and two unknow
we can solve A1 or r from any equation and replace on the other
I will solve A1 from the first equation
and replace on the second to solve r
now replace r on the other equation to find A1
now we have the two unknows A1 and r then replace on the general geometric equation