AttachmentOffset question, why not 3 rotation angles?

Have some feature requests, feedback, cool stuff to share, or want to know where FreeCAD is going? This is the place.
Forum rules
Be nice to others! Read the FreeCAD code of conduct!
freedman
Veteran
Posts: 3438
Joined: Thu Mar 22, 2018 3:02 am
Location: Washington State, USA

AttachmentOffset question, why not 3 rotation angles?

Post by freedman »

This is all as clear as mud to me. To make a complex rotation don't we need 3 rotation angles for an attachment Offset:
Rotate X as this angle =
Rotate Y as this angle =
Rotate Z as this angle =

Currently we have one angle to share with 3 axis. :?:

Thanks for your time if you have the time.
Last edited by freedman on Mon Dec 05, 2022 10:52 pm, edited 1 time in total.
chrisb
Veteran
Posts: 53920
Joined: Tue Mar 17, 2015 9:14 am

Re: AttachmentOffet question, why not 3 rotation angles?

Post by chrisb »

freedman wrote: Sat Dec 03, 2022 7:53 am This is all as clear as mud to me. To make a complex rotation don't we need 3 rotation angles for an attachment Offset:
It's a mathematical theorem, that any sequence of rotations in space can be replaced by a single rotation around a certain axis.

While having the championship in Qatar: As a corollary to that theorem it can be said that there are always two moments in each football game where two points of the ball are in the same places.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
freedman
Veteran
Posts: 3438
Joined: Thu Mar 22, 2018 3:02 am
Location: Washington State, USA

Re: AttachmentOffet question, why not 3 rotation angles?

Post by freedman »

Edit: OK now I get it.
freedman
Veteran
Posts: 3438
Joined: Thu Mar 22, 2018 3:02 am
Location: Washington State, USA

Re: AttachmentOffet question, why not 3 rotation angles?

Post by freedman »

So if I want to input this data:
Rotation angle X = xxx
Rotation angle Y = xxx
Rotation angle Z = xxx
into an Attachment offset, how would I do those calculations. Are there standard calls for this?
Thanks
chrisb
Veteran
Posts: 53920
Joined: Tue Mar 17, 2015 9:14 am

Re: AttachmentOffet question, why not 3 rotation angles?

Post by chrisb »

freedman wrote: Sat Dec 03, 2022 5:03 pm So if I want to input this data:
Rotation angle X = xxx
Rotation angle Y = xxx
Rotation angle Z = xxx
into an Attachment offset, how would I do those calculations. Are there standard calls for this?
Let FreeCAD do it for you, by using the Placement Dialog.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
User avatar
Shalmeneser
Veteran
Posts: 9474
Joined: Wed Dec 23, 2020 12:04 am
Location: Fr

Re: AttachmentOffet question, why not 3 rotation angles?

Post by Shalmeneser »

chrisb wrote: Sat Dec 03, 2022 10:08 am While having the championship in Qatar: As a corollary to that theorem it can be said that there are always two moments in each football game where two points of the ball are in the same places.
At least a good news. 8-)
freedman
Veteran
Posts: 3438
Joined: Thu Mar 22, 2018 3:02 am
Location: Washington State, USA

Re: AttachmentOffet question, why not 3 rotation angles?

Post by freedman »

I needed to replicate the AttachmentOffset concept so I made a rotation like this (pic). If there is ever a redesign of the properties panel something like this would make more since IMO. I would imagine the properties panel was designed this way as a proof of rotation during develoment so maybe if we had a switch to make the panels a bit more friendly.
Thanks
Attachments
Attach1.png
Attach1.png (21.84 KiB) Viewed 631 times
edwilliams16
Veteran
Posts: 3106
Joined: Thu Sep 24, 2020 10:31 pm
Location: Hawaii
Contact:

Re: AttachmentOffet question, why not 3 rotation angles?

Post by edwilliams16 »

I can only guess at what Rotation your dialog represents. What rotations, in what order, around what axes does it describe?

I do know what Euler angles are, but they are only useful in rather specialized situations - like in rigid body dynamics.
Screen Shot 2022-12-03 at 11.07.38 PM.png
Screen Shot 2022-12-03 at 11.07.38 PM.png (25.97 KiB) Viewed 595 times
chrisb
Veteran
Posts: 53920
Joined: Tue Mar 17, 2015 9:14 am

Re: AttachmentOffet question, why not 3 rotation angles?

Post by chrisb »

The Placement Dialog also offers the often underrated incremental mode, where you can turn an object one by one around the axes.
A Sketcher Lecture with in-depth information is available in English, auf Deutsch, en français, en español.
freedman
Veteran
Posts: 3438
Joined: Thu Mar 22, 2018 3:02 am
Location: Washington State, USA

Re: AttachmentOffet question, why not 3 rotation angles?

Post by freedman »

Here are the controls from my PDA (PartDesign Assy). The pin has been attached to the top of the hex by assembly (sketch highlighted) so there is no need for X or Y controls, but the Z and Rotation are useful. I really like the scroll capabilities of the input fields using the double spin box, you hover and use the scroll wheel to see changes in real time. By using the Select as Body option I can click on any object and get the body selection. I think it's too easy to modify the assembly, I will need to add a lock of some kind. :)

I use a copy of the targeted sketch AttachmentOffset to make all the changes, then apply this to the Body Placement. I store the entered data in added properties.
With some mods this could be a second generation Transform tool.
Attachments
GIF rotate.gif
GIF rotate.gif (850.02 KiB) Viewed 517 times
Post Reply