`cot theta = x/h`
`cot alpha = (a + x)/h`
`cot beta = (b + x)/h`
`cot alpha = ( a + h cot theta)/h`
`h cot alpha = a + h cot theta`
`h(cot alpha - cot theta) = a`
`h = a/(cot alpha - cot theta)`
now, `cot beta = (b+x)/h`
`cot beta = ( b+ hcot theta)/h`
`h cot beta = b + hcot theta`
h(cot beta - cot theta) = b``
`h = b/(cot beta - cot theta)`
`a cot beta - a cot theta = b cot alpha - b cot theta`
`b cot theta - a cot theta = b cot alpha - acot beta`
`cot theta(b-a) = bcot alpha - a cot beta`
`cot theta = (bcot alpha - a cot beta)(b-a)`
Hence proved