Welcome to the Onshape forum! Ask questions and join in the discussions about everything Onshape.

First time visiting? Here are some places to start:
  1. Looking for a certain topic? Check out the categories filter or use Search (upper right).
  2. Need support? Ask a question to our Community Support category.
  3. Please submit support tickets for bugs but you can request improvements in the Product Feedback category.
  4. Be respectful, on topic and if you see a problem, Flag it.

If you would like to contact our Community Manager personally, feel free to send a private message or an email.

Fully-defined sketches: what are they, and why care?

paul_chastellpaul_chastell Onshape Employees Posts: 126

I've seen a few comments and questions about the new feature list badge that says "Sketch is not fully defined" and I wanted to give an Onshape developer perspective.

TL;DR. Fully defined sketches don't protect us from Onshape, they protect us from co-workers and our future selves.

A sketch is a bunch of geometry, plus a bunch of constraints and dimensions that tell that geometry what its size is or where it should be. A "fully defined" sketch is a sketch that has enough constraints that there is no ambiguity at all as to where the geometry should be, or its size. There is only one way to "solve" the sketch. In contrast an "under defined" sketch is one where there is some ambiguity, multiple choices of where things could be. There is a subtle color scheme used in the sketch, black means something is fully defined, and blue means it is under defined (in light mode, at least).

Why did we add the indicator? Because customers asked us to.

Why did customers ask us to add the indicator? Because it matters that a sketch is not fully defined.

Why does it matter? Maybe you've made a bunch of sketches that are showing as "not fully defined" and you've never had issues with them (that you know of). That will be because Onshape does its best to move geometry as little as possible and it is quite possible that sketches haven't moved for you. However, any time you change a feature before that sketch, and that change affects the sketch in some way then the sketch must re-solve to meet the constraints. Onshape will try to move things as little as possible but if a sketch is not fully defined Onshape doesn't know where everything should be.

Here's a simple example. I started out with a rectangle, 100mm x 150mm. I then added a circle for a hole in a second sketch, it needs to be 40mm in diameter and midway between the top and bottom, and I constrained it like that but I left the distance between the circle center and right hand edge unconstrained. It happens to be 50mm, which is what I wanted, and I effectively eyeballed it in.

Now, maybe weeks or months later I go back into this design and I need a part that is larger, with the base being 150mm x 200mm. So I change the dimensions in the base sketch.

Onshape has done exactly what I said, it moved geometry as little as possible. The rectangle went 50mm wider to the right and 50mm wider upwards. Onshape kept the line's horizontal position exactly where it was, indeed it is 100mm from the right-hand side. The problem is that isn't where I wanted it to be. Where did I want it to be? Well, the best person to answer that is the me that originally made the sketch. Maybe by now I have forgotten the design intent. Much better for me to add that dimension when I make the sketch, not when I break it later. If you now complicate this situation with co-workers that are also making changes to this design, well then it gets even more tricky.

So that's why we have the badge. There are customers that want to know that the sketch could move in an unexpected way later, or that want to ensure that every bit of design intent is captured as early as possible. But if you want to ignore the badge, feel free, nothing bad will happen right then and there, just know that future you may wish you hadn't.

Paul Chastell
TVP, Onshape R&D

Comments

  • charles_greenacrecharles_greenacre Member Posts: 5 ✭✭

    Paul, I appreciate your explanation, and for the most part, my sketches are fully defined. However, I have a few sketches where just one or two items (lines, points, etc) are not fully defined, and I am trying to fix them before I take the sketch, convert it to a drawing, export the drawing to a .dxf file, downlload that file, then send it to a laser cutter. So yes, I want everything to be fully defined.

    There are instances where the sketch has hundreds of lines and points, and for the life of me, I cannot see the blue point or blue line. Yes I can see the circle filled with blue except for the white horizontal bar, over in the features panel. Yes, I zoom in and pan around looking for anything blue. Yet, I don't find the problem point or line.

    Is there anyway of changing the color of the lines or points (in my case) from #0000ff (pure blue) to some other color? PS. I just found the profile inspector via the glossary, and I have found that to be somewhat helpful. Yes it told me what item wasn't fully defined, but I swear the color is black not blue. I wonder if there is a second point (fully constrained) sitting on top of the first (unconstrained) part.

  • S1monS1mon Member Posts: 3,100 PRO

    I agree the blue is way too close to the black in the standard black on white mode. One trick is to - even temporarily - switch on dark mode. The color/value contrast is much more obvious.

  • MDesignMDesign Member Posts: 365 ✭✭✭

    agreed…feels like deja vu. when this comes up. A high quality monitor helps but when your company limits you to cheaper equipment and hasn't updated you in 10 years… its not as easy. (Couldn't talk em into anything bigger than 22". I had to give a ROI report for dual monitors. smh. 🤣

  • martin_kopplowmartin_kopplow Member Posts: 606 PRO

    Short sighted management. ROI on a dual monitor setup happens immediately and repeatedly each time an error is not made due to better oversight. But there is no honour to be gained in prevention. Heroes are born when an error made has to be corrected.

    BTW.: These days, one large monitor is cheaper than two mid-sized ones.

  • MDesignMDesign Member Posts: 365 ✭✭✭

    add in an image in the background and eewwwww!!! is there a way lighten images while sketching other than pre processing?

  • vondes_vodesvondes_vodes Member Posts: 4 ✭✭
    edited January 6

    Great explanation! Fully defining sketches is crucial for ensuring stability and predictability in your designs, especially when future edits or changes come into play. As your example shows, leaving even a single element under-defined can introduce ambiguity, which might not be an issue now but could cause unexpected behavior later. The new badge is a helpful addition, as it encourages best practices that save time and frustration down the line. Similarly, efficiency matters in other aspects of life, like online dating. Platforms like local big tits on TenderBang.com allow you to meet multiple people and quickly gauge compatibility without investing too much time upfront. It’s all about making smart, efficient choices—whether in design or dating!

  • kees_bijkerkees_bijker Member Posts: 122 ✭✭

    I agree with the fact that a sketch should be fully defined. Although there are situations thinkable where it is either incredibly difficult, or near impossible to do so. Best explanation I have is when you use a complicated image to make a sketch from and you are using polylines and splines and other sketch tools to approximate the original item from the image. Sometimes it is simply too much work and not needed to go and search for a way to fully define the sketch. And if you are having to change it because it does not end up looking like the original after you extrude or project your curves, when you have forced your sketch to be fully defined it becomes difficult to change it fluidly.

    The other thing I would respectfully disagree with is the statement that onshape will always does its best to move as little geometry to achieve what you want. This is simply false.

    If you try the following:

    undefined sketch of a circle with a line through the middle. you return to this sketch and now add a short line to extend the first line, you want this to be 0.6mm but you drew it 0.9mm. You click and you can put a measurement in, you say 0.6mm. You will see that onshape actually will leave your final input, the end of your short extension, in the place where it is and it will move the whole sketch towards this end point, making it 0.6mm.

    It has complied with your wishes, so I am not complaining about this for this reason. I do however find this behaviour totally counter intuitive and against logic. It would be more logical to assume your last input is actually what you wanted to be according to your measurement. So I feel it should shorten the line and move your last end point so it matches the 0.6 mm!

    But ok, the sketch should be defined before you attempt to change it so again I should not complain.

    It does infuriate me though 😉

Sign In or Register to comment.