Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations MintJulep on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Changing dimension reference in sketcher

Status
Not open for further replies.

vitulin

Automotive
Nov 1, 2007
79
Hi,

I hope, there exists a way to change references of dimensions in sketcher (similar to one in drafting)...
What is my problem?

I have created a law curve of spiral, that is driven by 2 diameters and angles in a sketch. There is also a line tangent to the spiral. Unfortunately, when I change the orientation of the spiral (growing either clockwise or counterclockwise) I need to change also the line, so that is tangent to the other end. But because I want to drive the diameter somehow, I have set a distance of center of spiral to the end poin of spiral/start point of line and this variable is used to drive the law curve. That means, that when I swap them, the dimension is still on the same place and pointing to the wrong end of the spiral. I cannot delete it and recreate it because its used in the expression.Therefore I need to somehow change the references of the dimension.

Thanks for help
Vit

 
Replies continue below

Recommended for you

Vit,

Dimensions appear to be just a fancy form of constraint in the sketcher. Due to the way it works you should be able to delete any dimension or constraint as required and apply a different method to the other end of the line. When you re-evaluate the sketch and/or exit the sketcher then the dependent geometry will update.

In your case you ought to be able to delete the tangency constraint to one side of the circle, move the end of the line to somewhere near the other side, and then create a new tangency constraint.

Line tangent to a curve has always been a condition that is crying out for an alternate solution button, both inside sketcher and for basic curves.

Best Regards

Hudson
 
It would really be helpful if you would specify which version of NX you're using in your initial post. Many things change from one version to another and it's almost impossible to accurately answer a question when we have no idea which version you're using.

A prime example being the Reattach Dimension command in Sketcher. It was added in NX5 but if you're not using NX5, then we need to think of another workflow to achieve the results you desire.

Tim Flater
Senior Designer
Enkei America, Inc.

Some people are like slinkies....they don't really have a purpose, but they still bring a smile to your face when you push them down the stairs.
 
Tim,

I may be wrong about some of this I haven't been using NX-5 for that long that I want to get too cocky about what I do or don't know. If you have a read and can fill in my gaps then Vit among others may be the better for it.

I thought that even prior to NX-5 it didn't seem to matter if you simply deleted the dimension and re-created it seeing that the sketch evaluation can be forestalled without losing anything external to the sketch.

I've seen re-attach dimension in NX-5 sketcher. It would be news to me at this stage if other constraints worked similarly. Anyway in this case it simply assumes the wrong end of the spiral law curve, so you're going to have to break the constraint in order to re-define it aren't you?

In other words would not the other workflow be somewhat as I described above. The only thing I could add after testing a similar example would be that for lines tangent to arcs or other spline curve you usually need to define two constraints per end. These would be the tangency arc to line, and the line endpoint to be on the arc.

Regards

Hudson
 
Hi,
thanks for the response. I am using NX 4.04...As I said, deleting the dimension doesnt work. I named the dimension for example WP_D1..and when I delete the dimension, I cannot create one with the same name, because UG complains, that this value is used in expressions.
 
I suspect that you're not going to like this much but what you do is to delete the dimension you can no longer use. It should let you. When you delete the dimension the expression WP_D1 will still be retained because as you rightly pointed out it is referenced elsewhere, (it would likely persist until you run part cleanup anyway). Now in order to re-establish the sketch constraints that were lost when you deleted the first dimension you need to create a new dimension. When you create that new dimension assign it the expression value WP_D1 and it should work. Now you can manipulate the dimension by changing the value of WP_D1 using the expression editor.

It isn't so hard really. But if you're going to tell us that it isn't that way in some other CAD system then you're probably wasting you breath because it has been changed in NX-5. Funnily enough what they don't tell you is that if you do this same sort of thing when you go to reattach the dimensions you will need to re-assert the value or type in the expression anyway. And it probably is better that way as the alternative could produce some fairly unexpected results. The point is that it is a whole new dimension in either case and the fact the you have to re-assert the value just makes sense in either the NX-4 or the NX-5 sketching scenario.

Best Regards

Hudson
 
Yes, you are right. i dont like it :eek:) the reason, why I kept the name of the dimension is, that I can change all the parameters of the spiral by simply editing sketch parameters in one go without going into expression editor. It is a little bit odd, but there are two ways of doing it and I dont like neither of them. First is to rename the parameter in the equations, delete the dimension, create new one and then change the parameter in the equation. And the second one is, what you suggested...
 
Vit,

If it is any consolation you can edit the expressions while you're still in the sketcher in NX-5. I tested earlier under NX-5 and noting your recent comment went back and checked it again under NX-4. It isn't very convenient in NX-4. So at least you know a couple of things about how you can do it and what works now and into the future.

Now as you describe what you want to do, and recognizing that there are certain limits placed on how the expressions can be accessed from within the sketch, there is still a way that you can kind of trick the system into doing what you want. Try creating a reference line in the sketch which will initially be named something like P1. Then make the dimension that you need to drive your sketch with and assign that the value P1. When you have that working you can change the name of that expression from P1 to WP_D1. Now your working dimension has the correct value it equals WP_D1, and you can change WP_D1 from inside the sketcher using NX-4. [wink] QED.

Regards

Hudson
 
P1 is a dimension that you give to the length of the line. You need to know that or it doesn't make sense. I managed to edit over the relevant part of my sentence there.

Hudson
 
...or you could assign a value of WP_D1=P1 (after creating P1 of course). Another expression to deal with, but it should work.

Believe it if you need it or leave it if you dare. - [small]Robert Hunter[/small]
 
Well that's what I thought to do in the first place, but since in NX-4 you can't edit those expressions in from within the sketcher I contrived to have the parameter live in the sketch by using it to define the length of a reference line. It requires to add the reference line as a device to embed the parameter inside the sketch but it gets around the problem of having to go in and out of the sketcher twice to make the change. That is to say that assuming you can't stop the model from evaluating itself and failing to rebuild properly as part of that process you really need to do something like this to make the change manageably easy to do.

Regards

Hudson

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor