Plotting noncontinuous arc segments
Mostrar comentarios más antiguos
Hey all,
I am trying to plot a non-continuous arc of a circle, given the center, radius and angle ranges of the arc(s). For instance, say I want to plot the following angle range:
0,...,0.75*pi,1.25*pi,...,2*pi
There's a gap between 0.75*pi and 1.25*pi. I don't want MATLAB to plot anything "between" these two angles, but it plots a straight vertical line.
This the basic structure of my code:
t=[];
for theta=0:0.01:2*pi
if % irrelevant condition that decides if the arc covers this angle
t=[t theta];
end
end
plot(a1*cos(t),a1*sin(t),'b--')
And here is the figure:

I want to 'skip' the vertical line. Is this possible?
Any kind of assistance would be greatly appreciated!
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Graphics Performance en Centro de ayuda y File Exchange.
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
