Sectional arc

Post here for help on using FreeCAD's graphical user interface (GUI).
Forum rules
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help

Also, be nice to others! Read the FreeCAD code of conduct!
freedman
Veteran
Posts: 3466
Joined: Thu Mar 22, 2018 3:02 am
Location: Washington State, USA

Re: Sectional arc

Post by freedman »

Another way to go about this is to use the Nth Polygon tool. It can give equal spacing and sketcher points.
Attachments
poly1.PNG
poly1.PNG (25.43 KiB) Viewed 432 times
heda
Veteran
Posts: 1348
Joined: Sat Dec 12, 2015 5:49 pm

Re: Sectional arc

Post by heda »

inspired by mario52 macros...

this could very well be a task where it is more easy for everyone involved,
to explain how to code the creation of the wheel,
rather than how to do it in the gui :-)

Code: Select all

import Draft
Vector = Draft.Vector

n = int(18)
angle = 360/n
radius = 10

line = Draft.makeLine(Vector(0,0,0), Vector(radius, 0, 0))
arc = Draft.makeCircle(radius, startangle=0, endangle=angle)
for i in range(1, n):
  Draft.rotate(line, angle*i, copy=True)
  Draft.rotate(arc, angle*i, copy=True)
User avatar
papyblaise
Veteran
Posts: 8001
Joined: Thu Jun 13, 2019 4:28 pm
Location: France

Re: Sectional arc

Post by papyblaise »

We don't know what the purpose is
- cut a pizza into 18 parts, :?:
- cut a birthday cake for 18 kids :?:
- make a western cart wheel with 18 spokes :?:
one of the best solutions is that of Freedman
another is to make a sector at 20 ° and reproduce it by Polar Array 18 occurs
mario52
Veteran
Posts: 4692
Joined: Wed May 16, 2012 2:13 pm

Re: Sectional arc

Post by mario52 »

Hi
degarb wrote: Sun Apr 18, 2021 4:43 am I want to draw an arc and have it sectioned in 18 equal parts. I wonder how I can do it?
just sectional one arc not circle

mario
Maybe you need a special feature, go into Macros_recipes and Code_snippets, Topological_data_scripting.
My macros on Gist.github here complete macros Wiki and forum.
degarb
Posts: 58
Joined: Fri Apr 16, 2021 7:49 pm

Re: Sectional arc

Post by degarb »

heda wrote: Mon Apr 19, 2021 9:43 pm inspired by mario52 macros...

this could very well be a task where it is more easy for everyone involved,
to explain how to code the creation of the wheel,
rather than how to do it in the gui :-)


I actually understood your explanation heda. However, I couldn't get the line to anchor when holding alt when I drew it. So, when I changed the angle of the copied line, the line sometimes would rotate, sometimes move all around the screen. I ended up importing your drawing and modifying that one, then moving the fan deck to the place where I needed it to align my other items.

That solved, I still have a huge 90 degree arc, and I added thingamigs on the one side. However the laser cutter will likely lop off the thingys because I cannot recreate my arc with mini arcs to allow the thingamabobs to attach without the arc line under them. The stop start values are too random and impossible to calculate to type in the mini arch numbers and the mouse method is too imprecise. ...Life would be so much easier if the line split tool would work on my arc. I could just click and split my arch into 15 sections, not equal, but at the edge where my dohickies are attaching. Deleting my big arc ad doing trial and error start and stop digits for 25 minor lines will take me hours. Drawing many little arcs by mouse is impossible on a 17 inch screen.

Thanks for the help, heda I can't understand why I couldn't always get my lines anchored to the one spot. I chalk it up to another weird quirk of the software, or my greenness. I read, watched videos, and tried to figure out the polar array. Other people were doing quite different things, using different versions. I have an array button, not the polar array button other people, used. I would select and object, hit array, modify it to polar, it would properly nest my object under the array in the tree. But then I was dead in the water, seeing nothing more I could do, finding nothing applicable in the docs, videos, or searches.
User avatar
papyblaise
Veteran
Posts: 8001
Joined: Thu Jun 13, 2019 4:28 pm
Location: France

Re: Sectional arc

Post by papyblaise »

Ha this time, if I understood correctly, you want to cut an arc of any length in 18 equal parts
You draw your arc, place a Draft WB point at the origin (important)
select arc and point, use PathArray = 18 ocures
Attachments
18arcs.PNG
18arcs.PNG (9.99 KiB) Viewed 347 times
18arcs.FCStd
(10.29 KiB) Downloaded 13 times
Post Reply