Properties: Attachment Position vs. Base Position, etc.

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!
RussG
Posts: 124
Joined: Wed Apr 27, 2022 11:27 pm

Properties: Attachment Position vs. Base Position, etc.

Post by RussG »

OS: macOS 10.16
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.24366 (Git)
Build type: Release
Python version: 3.9.7
Qt version: 5.12.9
Coin version: 4.0.0
OCC version: 7.5.3
Locale: C/Default (C)


So, this is very confusing for me…

I created a sketch of a square constraining it to the origin with the symmetry constraint and padded it in both directions equally so that the 3D block would appear with its center where the X, Y, and Z axes intersect: 0, 0, 0.

In the attached screenshot you can see in the Data pane of the Combo View that I have moved the Sketch to Z -30 in the Attachment/Attachment/Position section. I expected that the block shown in the 3D view would thus move downward along the Z Axis, but it appears to have moved backward along the Y Axis.

At the same time that I changed the Position Z to -30 and pressed the Enter key, Position Y in the Base/Placement/Position section of the Data pane of the Combo View changed to 30 mm.

I have no clue as to why I see movement along the Y axis when I entered movement in the Z text entry field. I don’t understand the difference between the Attachment and Base sections of the Data window. I don’t know why positioning something along one axis (if that’s what I’m doing) would effect change along a different axis instead… I have no idea what changing the values in the Axis section of Property/Attachment/Attachment/Axis are supposed to do. Clearly, I have little to no understanding of the workings of these parameters in the Data section of Combo View.

I have not yet found documentation that explains in terms I can understand how things work. I’ve seen <https://wiki.freecadweb.org/Placement> to which the most intelligent response I can make is “Huh, say what?”. Does anyone know of documentation that I might find helpful, something a mere mortal lacking a degree in computational quantum geo-spacial physics might be able to grasp?

Thanks.
Body003.FCStd
(9.56 KiB) Downloaded 14 times
Body003.jpg
Body003.jpg (195.72 KiB) Viewed 1135 times
Bance
Veteran
Posts: 4286
Joined: Wed Feb 11, 2015 3:00 pm
Location: London

Re: Properties: Attachment Position vs. Base Position, etc.

Post by Bance »

Why did you place your sketch on the XZ plane?
edwilliams16
Veteran
Posts: 3193
Joined: Thu Sep 24, 2020 10:31 pm
Location: Hawaii
Contact:

Re: Properties: Attachment Position vs. Base Position, etc.

Post by edwilliams16 »

Screen Shot 2022-06-20 at 7.41.30 AM.png
Screen Shot 2022-06-20 at 7.41.30 AM.png (57.79 KiB) Viewed 1093 times
Your sketch is attached to the Support (XZ_plane/Flat Face) as illustrated. The sketch is then moved relative to that location by the Attachment in the sketch coordinates, that is z always means perpendicular to the sketch and x and y are along the x and y axes of the sketch. The Placement fields are computed by FreeCAD. You will note they are read-only. They show the result of the effects of the Attachment (which rotates the sketch from its XY plane into the XZ Plane, and the effect of the Attachment offset - which being perpendicular to the sketch is -30 mm along the global negative z-axis.)
RussG
Posts: 124
Joined: Wed Apr 27, 2022 11:27 pm

Re: Properties: Attachment Position vs. Base Position, etc.

Post by RussG »

Bance wrote: Mon Jun 20, 2022 5:57 pm Why did you place your sketch on the XZ plane?
It may have been precisely so as to be able to illustrate my confusion. It may have been because I need to place an object on the XZ Plane for a project I'm working on. I don't remember.

It's unclear to me if you intend there to be some cryptic take-away for me to be found in your question of it was merely a matter of curiosity. Is there some reason not to place a sketch on the XZ Plane? Was your question somehow supposed to be an answer to mine? If so, please explain because I don't get it.
Bance
Veteran
Posts: 4286
Joined: Wed Feb 11, 2015 3:00 pm
Location: London

Re: Properties: Attachment Position vs. Base Position, etc.

Post by Bance »

Well, since you are clearly not a rocket scientist (as I note you suppose everyone else is?)

I thought you might learn something if you thought of drawing on paper flat on the desk.

Away from you is 'Y' to your right is 'X' and If you put a book under the paper to 'Pad' it up you have 'Z'.

This is the way that sketches always work whether you place the paper on the wall in front of you ('XZ' Plane) or the wall to your left ('YZ' plane.)

And by the way, the sketch in your example was not constrained to be central to any axis, nor was it padded symmetrically.

And there really is no need for dramatising your posts, most people understand that the learning curve is steep to begin with, we have after-all, been there ourselves.
User avatar
wandererfan
Veteran
Posts: 6326
Joined: Tue Nov 06, 2012 5:42 pm
Contact:

Re: Properties: Attachment Position vs. Base Position, etc.

Post by wandererfan »

RussG wrote: Mon Jun 20, 2022 5:06 pm So, this is very confusing for me…
Yeah, I sympathize. This trips me regularly.

In PartDesign, Sketches are always built on (ie attached to) some kind of support. The user can ignore the sketch's Placement as it is calculated by the system using the support and Attachment. Things are different if you a using SketcherWB directly, but that's another topic.

The XYZ axes in the Sketch's Attachment are relative to the Sketch (well, technically to the Sketch's support, but we don't need to know that here), so if your Sketch is built on the XZ plane, AttachmentX is sketch horizontal (Global X), AttachmentY is sketch vertical (Global Z) and AttachmentZ is perpendicular to the sketch (GlobalY in this case). When you modify AttachmentZ you are moving the Sketch towards you or away from you.

Hope this helps a bit.
RussG
Posts: 124
Joined: Wed Apr 27, 2022 11:27 pm

Re: Properties: Attachment Position vs. Base Position, etc.

Post by RussG »

Bance wrote: Mon Jun 20, 2022 7:17 pm Well, since you are clearly not a rocket scientist (as I note you suppose everyone else is?)
Please don’t put words in my mouth. Any comments I might make about my own inabilities are simply a reflection of my own modesty and are not meant to include a reference to anybody else, rocket-scientist or not. I've said nothing, nor meant to imply anything about anybody other than myself.
Bance wrote: Mon Jun 20, 2022 7:17 pm I thought you might learn something if you thought of drawing on paper flat on the desk.
That might have been a useful suggestion but it is not one you made. There was really no way for me to know what you were thinking, which is why I asked.
Bance wrote: Mon Jun 20, 2022 7:17 pm Away from you is 'Y' to your right is 'X' and If you put a book under the paper to 'Pad' it up you have 'Z'.
Here is how I think about X, Y, Z: X = left (-) and right (+), Y = forward (-) and back (+), or away from me (+) and closer to me (-), Z = up (+) and down (-).
Bance wrote: Mon Jun 20, 2022 7:17 pm This is the way that sketches always work whether you place the paper on the wall in front of you ('XZ' Plane) or the wall to your left ('YZ' plane.)

And by the way, the sketch in your example was not constrained to be central to any axis, nor was it padded symmetrically.
Sorry, I must have attached the wrong file.
Bance wrote: Mon Jun 20, 2022 7:17 pm And there really is no need for dramatising your posts, most people understand that the learning curve is steep to begin with, we have after-all, been there ourselves.
I’m sorry if it seems to you as if I have dramatized anything. That’s never been my intention. Injecting humor is more my style. Perhaps you mistook an attempt at humor as something else. I will endeavor to be more clear. I’m not entirely sure how you arrived at the conclusion I was being dramatic, but it seems it might be fair of me to make a similar comment about your opening remark. Going forward, if you feel something I've said is inappropriate please bring it to my attention via a personal message and I will endeavor to do likewise.

I'm here to learn, and you've been kind enough to help, which I appreciate.

Thanks for your help.
RussG
Posts: 124
Joined: Wed Apr 27, 2022 11:27 pm

Re: Properties: Attachment Position vs. Base Position, etc.

Post by RussG »

wandererfan wrote: Mon Jun 20, 2022 7:31 pm
RussG wrote: Mon Jun 20, 2022 5:06 pm So, this is very confusing for me…
Yeah, I sympathize. This trips me regularly.

In PartDesign, Sketches are always built on (ie attached to) some kind of support. The user can ignore the sketch's Placement as it is calculated by the system using the support and Attachment. Things are different if you a using SketcherWB directly, but that's another topic.

The XYZ axes in the Sketch's Attachment are relative to the Sketch (well, technically to the Sketch's support, but we don't need to know that here), so if your Sketch is built on the XZ plane, AttachmentX is sketch horizontal (Global X), AttachmentY is sketch vertical (Global Z) and AttachmentZ is perpendicular to the sketch (GlobalY in this case). When you modify AttachmentZ you are moving the Sketch towards you or away from you.

Hope this helps a bit.
Yes, thanks. I think edwilliams16 explained the same things (above) and that I get it.
RussG
Posts: 124
Joined: Wed Apr 27, 2022 11:27 pm

Re: Properties: Attachment Position vs. Base Position, etc.

Post by RussG »

edwilliams16 wrote: Mon Jun 20, 2022 6:02 pm Screen Shot 2022-06-20 at 7.41.30 AM.png

Your sketch is attached to the Support (XZ_plane/Flat Face) as illustrated. The sketch is then moved relative to that location by the Attachment in the sketch coordinates, that is z always means perpendicular to the sketch and x and y are along the x and y axes of the sketch.
That's very helpful. Thanks!

I had no idea the Position entry field moved a sketch relative to the Support to which the sketch is attached. That's new to me. I had assumed that the direction of Z in the Attachment/Position section of the Data pane was the same direction as Z in the 3D View. I see now that this is not always the case, that it's only true if the sketch is drawn on the XY Plane (if I understand things correctly).
edwilliams16 wrote: Mon Jun 20, 2022 6:02 pm The Placement fields are computed by FreeCAD. You will note they are read-only.
Understood.
edwilliams16 wrote: Mon Jun 20, 2022 6:02 pm They show the result of the effects of the Attachment (which rotates the sketch from its XY plane into the XZ Plane, and the effect of the Attachment offset - which being perpendicular to the sketch is -30 mm along the global negative z-axis.)
I've read and re-read this part of your comments at least a dozen times. Would this be another way of saying what you did?: When the Attachment of my sketch which was drawn on the XY plane is translated by FreeCAD into the Global 3D space of the 3D View Window, the Z axis of my sketch translates to (aligns with) the Y axis of the Global space so that when I change the Z value of the sketch in the Position dialog it moves along the Y axis in the Global Space. Am I understanding this correctly?
drmacro
Veteran
Posts: 9010
Joined: Sun Mar 02, 2014 4:35 pm

Re: Properties: Attachment Position vs. Base Position, etc.

Post by drmacro »

If you select the Sketcher workbench. (Thus you are NOT using Part Design) And create a sketch on the XY plane.

The the x and y and z axis of the sketch happen to map to the global coordinate system.

If you create a sketch on the YZ plane, then the z axis of the sketch is the global x.

Create a sketch on the XZ plane, then the z axis of the sketch is the global y.

If, in Part Design, you are creating the sketches in a Body, the Body.Origin (by default) is a proxy for the global origin. And the sketch axes are relative to the Body.Origin.
Star Trek II: The Wrath of Khan: Spock: "...His pattern indicates two-dimensional thinking."
Post Reply