I am trying to tranform an object claw1
to create it mirror image claw2
.
I tried using GeometricTransformation
, but I did not get works.
My code follows. How should I change it?
arm = {Circle[armCenter = {0, 0}, armR = 12.5, {Pi/2, 3*(Pi/2)}],
Circle[{106.79, 0}, 20, {2.57, 3.72}],
Line[{{0, armR}, {90, armR}, {90, armR}, {90, 10.87}}],
Line[{{0, -armR}, {90, -armR}, {90, -armR}, {90, -10.87}}]};
claw1 = {Circle[{106.79, 0}, 20, claw1a = {0.8, 2.89}],
Circle[{106.79, 0}, 25, claw1a],
Circle[{85, 5.6}, 2.5, claw1b = {2.89, 6.03}],
Circle[{122.54, 16.07}, 2.5, claw1c = {0.8, -2.35}]};
claw2 = {Circle[{106.79, 0}, 20, claw1a*-1],
Circle[{106.79, 0}, 25, claw1a*-1],
Circle[{85, -5.6}, 2.5, claw1b*-1],
Circle[{122.54, -16.07}, 2.5, claw1c*-1]};
angClaw1 =
GeometricTransformation[
claw1, {RotationTransform[Pi/10, {85, 5.6}]}];
angClaw2 =
GeometricTransformation[
claw2, {RotationTransform[-Pi/10, {85, -5.6}]}];
Graphics[{arm, angClaw1, angClaw2},
PlotRange -> {{-20, 130}, {-50, 50}}, Axes -> True,
ImageSize -> Large]
Scale
. Be sure to specify a reference point.Graphics[{Triangle[], Red, Scale[Triangle[], {-1, 1}, {0, 0}]}, Axes -> True]
. $\endgroup$