Please any idea of how I can flip an arc?

2 views (last 30 days)
I have an arc of a circle which is facing the centre of the circle but I want to flip this arc by 180 degrees to make it face the opposite direction as illustrated in the attachment.

Accepted Answer

Star Strider
Star Strider on 23 Jul 2018
Try this:
a = linspace(0, pi/2);
r = 1;
x = r*cos(a);
y = r*sin(a);
figure
subplot(2,1,1)
plot(x, y)
axis equal
title('Before')
subplot(2,1,2)
plot(r-x, r-y)
axis equal
title('After')
Subtract the x and y vectors from the radius to flip the circle.
  2 Comments
Steve Arum
Steve Arum on 23 Jul 2018
Thanks a lot @Star Strider for your swift answer.

Sign in to comment.

More Answers (0)

Community Treasure Hunt

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

Start Hunting!