<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
The author of the question (Tony Morris) actually asked two different
questions, and so people gave two different replies :)<br>
<br>
To quote Tony:<br>
<pre wrap="">"I may have misunderstood his problem (we were drawing in dirt) and actually, it is
the straight line between the two points on the circumference that are
known and not the specified 'b', but I figure I could derive one
solution from another if I have misunderstood him."

So, the solution to the drawing, where a is the radius and b is the arc:

x = a * (1 - cos(b/2a)) (because cosine = adjacent / hypotenuse)

The solution to the textual question, where a is the radius and b is the distance between the two points on the circumference:

(a-x)<sup class="moz-txt-sup">2</sup> + (b/2)<sup class="moz-txt-sup">2</sup>  = a<sup
 class="moz-txt-sup">2</sup>  
&nbsp;
=&gt; x<sup>2</sup> - 2ax + a<sup>2</sup> + (b/2)<sup>2</sup> = a<sup>2</sup>
=&gt; x<sup>2</sup> - 2ax + (b/2)<sup>2</sup> = 0
=&gt; x = a &plusmn; sqrt(4a<sup>2</sup> - b<sup>2</sup>) / 2 (solution to quadratic)
=&gt; x = a - sqrt(a<sup>2</sup> - b<sup>2</sup>/4) (move /2 into sqrt, and can't be +sqrt because that would make x greater than a)

So in Haskell

sol1 a b = a * (1 - cos (b / (2*a)))
sol2 a b = a - sqrt (a*a - (b*b)/4)

Cheers,
Peter

</pre>
<br>
</body>
</html>