title: Python - How do I find the x and y coordinates of the circle to create an arc on a map
body: <p>I am writing a python script that will map some points and curved on a map based on data that I receive. I am attempting to get the center coordinates of a arc/circle using any of the data that I receive below. I am having a hard time wrapping my brain around it.</p>
  
  <ul>
  <li>Point1 Lat and Lon</li>
  <li>Point2 Lat and Lon</li>
  <li>Starting Angle</li>
  <li>Ending Angle</li>
  <li>Radius Of the Circle</li>
  </ul>
  
  <p>I do realize that I don't need all of this data to solve this.</p>
  
  <p>I also have a flag that tells me if its a left or right hand turn.</p>
  
  <p>Would getting the x and y cords be possible to calculate with the information I am receiving above.</p>
  
  <p>I already have a function that is ran in javascript to draw the arc.</p>
  
  <pre><code>function drawArc(center, initialBearing, finalBearing, radius) {{
      var d2r = Math.PI / 180;   // degrees to radians 
      var r2d = 180 / Math.PI;   // radians to degrees 
  
      var points = 32; 
  
      // find the raidus in lat/lon 
      var rlat = (radius / EarthRadiusMeters) * r2d;
      var rlng = rlat / Math.cos(center.lat() * d2r); 
  
      var extp = new Array();
  
      if (initialBearing &gt; finalBearing) finalBearing += 360;
      var deltaBearing = finalBearing - initialBearing;
      deltaBearing = deltaBearing/points;
      for (var i=0; (i &lt; points+1); i++) 
      {{ 
        extp.push(center.DestinationPoint(initialBearing + i*deltaBearing, radius)); 
        bounds.extend(extp[extp.length-1]);
      }}
      return extp;
  }}
  </code></pre>
  
  <p>I cant for the life of me find a good way to get the x and y coordinates of the center of the circle.</p>
  
  <p><img src="https://i.stack.imgur.com/BhoIy.png" alt="enter image description here"> </p>