<s>[INST] Geometry problem on finding the diameter of a circle $AB$ is the diameter of a circle. Tangents $AD$ and $BC$ are drawn so that $AC$ and $BD$ intersect at a point on the circle. If $|AD|=a$ and $|BC|=b$, $(a \neq b)$ then find the diameter of the circle.
 [/INST] 
Lets say AC and BD intersect at E , so at right angles as diameter subtends right angle at circumference .
Using pythagorous theorem 
$$ \displaystyle\boxed{(diameter)^2 = AE^2 + BE^2} $$
So now we should calculate AE and BE to get d 
as $$CE \times CA = CB^2 ---> 1$$ 
and $$DE \times DB = DA^2 ---> 2$$ 
and as the triangles AED and CEB are similar 
$$ \frac{AE}{EC} =  \frac{DE}{EB} = \frac{a}{b}  $$ 
$$ \frac{AC}{EC} = \frac{a+b}{b} --------> 3$$ 
$$ \frac{BD}{DE} = \frac{a+b}{a} --------> 4$$ 
substitute AC of result 3 in 1 and get $CE^2 $ and from there CE ,
Similaryly get DE
$$ CE = \frac{b*\sqrt{b}}{\sqrt{a+b}} $$
$$  DE = \frac{a*\sqrt{a}}{\sqrt{a+b}} $$
so $$AE = \frac{a}{b} \times CE $$ 
   $$\displaystyle\boxed{AE = \frac{a\sqrt{b}}{\sqrt{a+b}}}$$ 
similary 
$$BE = \frac{b}{a} \times DE $$ 
   $$\displaystyle\boxed{BE = \frac{b\sqrt{a}}{\sqrt{a+b}}}$$ 
so just substitute AE and BE in $ (diameter)^2 = AE^2 + BE^2 $and find d the diameter
$$ d^2 = \frac{a^2*b}{a+b} + \frac{b^2*a}{a+b} $$
$$ d^2 = \frac{ab*(a+b)}{a+b} $$
this implies 
$$ d = \sqrt{ab}$$
</s>