Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

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

Question regarding using Laws in V5

Status
Not open for further replies.

Burner2k

Aerospace
Jun 13, 2015
193
IN
My basic need is to generate a curve based on an equation (4th order polynomial).

I understand one can use FOG laws & parallel curve command to generate curves to follow an equation. To test & get a better feel, I tried a simple equation y=x^2.

My reference line (for parallel curve) length is 50 mm. I am able to create a parallel curve using laws which gives me correct shape but not the value.

My ref line starts from (0,0,0) & extends to (50,0,0). My support plane is XZ for parallel curve and if I measure the distance between the end point of the parallel curve to end point of reference line, I always get the value of 1,000 mm. I was expecting a value of 2,500. My understanding is Catia "measures" the reference line length (x coord at each small interval) and calculates the "y" (or Z in my case) coord value based on the expression (laws) and draws a curve.

I tried defining the y and x parameters in FOG laws as both real & length but get the same result.

Any ideas on what I might be doing wrong? Or is my understanding on how law works completely off? If laws are not suitable, any other functionality in Catia that can be used to accomplish my objective? End goal is to create numerous spines (using different equations) for lofting.
 
Replies continue below

Recommended for you

CATIA normalizes your reference line to be [0:1]...

regards,
LWolf
 
I was able to get the equation working when I set the x & y formal parameters to length. I had to play around with units to get the results I wanted but still not very comfortable.

For example, if I want to generate a curve using equation y = 5*cos(x) + 6*sin(x) where x = length along reference line, Catia & a spreadsheets produce completely different results.

LWolf, so what would need to be done if I want to Catia to consider my true length of my reference line.

2nd question. I've set my units length to be in mm but I understand FOG laws consider default unit to be m. So should I specify a conversion factor (1000?) in all my equations.

Ex: In the above trignometric equation, what exactly should my input be in laws editor so that curve generated in Catia matches one obtained from Excel?

This is what I enter `y` = 1000*((5*cos(PI*1rad*`x`)+(6*sin(PI*1rad*`x`)) and Catia generated curve is not matching Excel one.
 
well, use the length of your line as input: y=(length(Line.1 )* x)**2
length is a function found under measures dictionary

regards,
LWolf
 
your sine and cosine are dimensionless, so attach a dimension at the end by multiplying with 1mm i.e ((5*cos(PI*1rad*`x`)+(6*sin(PI*1rad*`x`))*1mm will give you the answer in mm.

regards,
LWolf
 
LWolf,
Thanks for your patient replies. Really appreciate it and they have been super helpful.

Regarding the trig equation...I'm still having issues with output.

So, let me describe what I am currently doing.

1. Creating a length parameter (using formula) called 'a'.

2. Offsetting one of the global planes by value 'a'

3. Creating a ref line starting from (0,0,0) and point 2 is up to length 'a' (actually up to offset plane).

4. For sake of clarity, lets say a = 90mm

5. My FOG equation looks like

`y` = ((5*cos(PI*1rad*`x`*`a`*1m)+(6*sin(PI*1rad*`x`*`a`*1m))*1mm

I want Catia to generate a curve based on evaluation of above expression from 0 to 90 mm (range of length of either 'a' or reference line).

I am still not getting the desired output.

Please do bear with me and help me understand where I am going wrong.

For some reason, I am not able to upload an image of the curve I get in Excel. Anyways, the curve starts at y=5 @ x=0 & ends at y=6 @ x=90



 
I am not quite sure what you are trying to model; if you analyse your dimensions, your trig argument should have [rad], i.e PI*x*a*1rad/1mm assuming x is real and 'a' is a length (in mm)
how many periods do you want to have on your line? one period of sine/cosine is 2*PI*x [rad]

regards,
LWolf
 
Hi LWolf,
Sorry for the late reply. Just trying to understand how syntax works in Catia laws. Your suggestions are very valuable. I would have not realized that I would need [rad].

Thanks for your help. I will try it out soon.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top