# the arc using the chord

7 visualizzazioni (ultimi 30 giorni)
nil la il 20 Feb 2024
Commentato: Matt J il 20 Feb 2024
Hello Dears
Is it possible to draw an arc using only the chord in front of it without any other information?
##### 9 CommentiMostra 7 commenti meno recentiNascondi 7 commenti meno recenti
Catalytic il 20 Feb 2024
Is it possible to draw an arc using only the chord in front of it
Several problems -
1. Not all arcs are circular, although the others seem to have assumed that's what you mean.
2. There is no unique circle passing through two given chord tips (see also David Goodmanson).
3. A chord has no "front". You will need to decide somehow on which side of the line segment the arc is supposed to run.
nil la il 20 Feb 2024
Yes that's right.

Accedi per commentare.

### Risposte (2)

Matt J il 20 Feb 2024
Modificato: Matt J il 20 Feb 2024
Assume the chord is of length L and, with no loss of generality, assume also that it is aligned with the x-axis with end points at ±L/2. Let the user select any 3rd point on the y-axis [0,b]. Then you can use circularFit from this FEX download to render the circular arc running through all three points,
Once you've done this, you can rotate translate the points to any desired position off the x-axis.
L=10; b=2; %User input
xy=[-L/2,0;+L/2,0;0,b]';
plot( circularFit(xy) )
##### 6 CommentiMostra 4 commenti meno recentiNascondi 4 commenti meno recenti
nil la il 20 Feb 2024
Matt J il 20 Feb 2024

Accedi per commentare.

John D'Errico il 20 Feb 2024
Your question is far too general, too vague to have an answer.
There are infinitely many "arcs" that will pass through two points. Even if we assume specifically circular arcs, there are infinitely many such arcs, as the radius of that circle can be almost anything. So, is it possible? Um, no. There is no unique circular arc, given only a chord. As such, "THE" arc cannot be drawn, since it is not unique.
Worse, even if you know the radius of the circle you would choose, assuming that the radus is validly chosen, there are always FOUR possible circular arcs for any chord. So again, no, it is not possible to choose between them. (You might guess there are two, but in fact, there are four possible circular arcs. Think about it. Two of the possible arcs are longer than the other two arcs.) For example, consider the chord connecting two points, I'll choose them arbitrarily as (0,0) and (1,1). Pick a circular radius of 5 units. (I chose 5 units her because it allows the centers to be integers. And I needed to solve a variation of the Pell equation to know that, specifically one of the form 2*R^2-1==z^2. Here we are interested in integer solutions for R.) Anyway, there are two possible circles we might care about, each of which can supply two potential arcs.
R = 5;
syms x y cx cy
Circ = (x - cx)^2 + (y - cy)^2 == R^2;
cxy = solve(subs(Circ,[x,y],[0 0]),subs(Circ,[x,y],[1 1]),[cx,cy])
cxy = struct with fields:
cx: [2×1 sym] cy: [2×1 sym]
cxy.cx
ans =
cxy.cy
ans =
So those represent the two possible circles that have the indicated chord, AND have a radius of 5 units. We can draw the circles and the chord as...
t = linspace(0,2*pi);
plot([0 1],[0 1],'k-o',4 + R*cos(t),-3 + R*sin(t),'r-',-3 + R*cos(t),4 + R*sin(t),'r-')
axis equal
Again, there are 4 such possibe arcs drawn there.
If you further specify you desire the shorter of those potential circular arc for a given radius and a given chord, there are still two such arcs, and no valid way to choose between them, as they have the same arc length. So again, you still will not have sufficient information to decide between them.
So is it possible to draw an arc? Well, yes, in theory. But to do so automatically, no. You have not provided sufficient information.
##### 1 CommentoMostra -1 commenti meno recentiNascondi -1 commenti meno recenti
nil la il 20 Feb 2024
Yes, you are right, thank you for your help

Accedi per commentare.

### Categorie

Scopri di più su Matrix Indexing in Help Center e File Exchange

### Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by
{"found_math": false, "script_math_tex": 0, "script_math_asciimath": 0, "math_annotations": 0, "math_alttext": 0, "mathml": 0, "mathjax_tag": 0, "mathjax_inline_tex": 0, "mathjax_display_tex": 0, "mathjax_asciimath": 0, "img_math": 0, "codecogs_latex": 0, "wp_latex": 0, "mimetex.cgi": 0, "/images/math/codecogs": 0, "mathtex.cgi": 0, "katex": 0, "math-container": 0, "wp-katex-eq": 0, "align": 0, "equation": 0, "x-ck12": 0, "texerror": 0}