Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

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

Using if expressions for creating law curves 1

MbToxic

Student
Jan 22, 2025
3
I'm trying to create a law-defined curve. It has "left" and "right" parts

Knowing that there are "if" expressions in NX I tried using it, but when I create a curve using these laws constant function is displayed. Is it not possible to use "if" clauses, or am I doing something wrong?

In pic.1 are my expressions, pic.2 is what I get and how I create a curve, pic.3 is desmos variant of the "yc"

PS
I did this the stuff without using if clauses, but using two of them here creates not 4, but 8 expressions later and it snowballs into a mess of a calculation
 

Attachments

  • pic 1.jpg
    pic 1.jpg
    97.3 KB · Views: 20
  • pic 2.jpg
    pic 2.jpg
    210.3 KB · Views: 20
  • pic 3.jpg
    pic 3.jpg
    48.7 KB · Views: 20
Replies continue below

Recommended for you

I struggle to do it, can you help with this one? In first I just multiply by p, but idk what to do in the second
Only problem is select ranges:
p>t>0 and c>t1>p
 
In the camber line equation in pic #3, what do p, t, m, and c represent?
 
Hey,

I would like to help, but I am not sure:
In this expressions is "t" - unitless parameter from NX or dimension in X direction?
Best regards

MANok
1738169631726.png
 
Hello,

I try it.
You can use IF statement in Law Defined Spline, but You have wrong expression:

if (t<p)(y1)else(y2)
where:
y1 = m/p^2*(2*t*p-t^2)
y2 = m/(1-p^2)*((1-p^2)+2*p*t-t^2)

(you can type all expresions in one line)


If c= 1 and "t" in Chamber line equation is X value, Your curve is here:

1738173078906.png

Best regards
MANok
 
Looks like it works.camber line.JPG
 

Attachments

  • 059106_1.zip
    46.2 KB · Views: 4

Part and Inventory Search

Sponsor