# What does function step mean?

 Register Blogs Members List Search Today's Posts Mark Forums Read

 June 2, 2003, 05:44 What does function step mean? #1 Miko Guest   Posts: n/a Hi all! In CFX tutorial 7(Free Surface Flow Over a Bump), before the boundary conditions are created, some values and expressions are needed to be created. I don't know what the function, "step" mean? Can somebody tell me?

 June 2, 2003, 06:02 Re: What does function step mean? #2 matej Guest   Posts: n/a Hi MIko, It will give you a step profile. If the argument is true, the returned value is 1.0, otwerwise it returns 0.0. Nice for setting for example sharp profiles for the inital conditions, without the need of extra block for it. matej Mazze[ITA] likes this.

 June 2, 2003, 06:04 Re: What does function step mean? #3 Miko Guest   Posts: n/a Oh, thank you matej!

 June 2, 2003, 06:42 Re: What does function step mean? #4 Miko Guest   Posts: n/a Hi matej! Another question is how to judge if it's true or not. For instance, step(0.1)=? step(0)=?

 June 2, 2003, 07:22 Re: What does function step mean? #5 matej Guest   Posts: n/a OK, Let's say You want to have Water.vf. at x=<0,1> as 1.0 and the rest of domain 0.0 so you define: waterVfIni=step(1-x/1[m]) and you will have the waterVfIni 1 where it should be. just make sure the argument of the step function is dimesionless. matej

 June 2, 2003, 14:42 Re: Clarification of STEP function #6 Robin Guest   Posts: n/a Hi Miko, It is not whether it is true or false, rather whether the result is positive or negative. If the expression within the step function is negative, the step function evaluates to 0, if it is postitive, the result is 1. If it is exactly zero, the result is 0.5. step(x)=y for x < 0, y = 0.0 for x = 0, y =-0.5 for x > 0, y = 1.0 Note that the expression to be evaluated must be dimensionless. To do this, simply divide the argument by it's unit to make it dimensionless. Regards, Robin Mazze[ITA] and lostworlduan like this.

 June 2, 2003, 20:31 Re: Thank you! #7 Miko Guest   Posts: n/a I think I get the satisfied answer. Thank Matej, Robin and all a lot! Best regards! Miko

 April 14, 2009, 21:23 #8 Senior Member   Bharath kumar Join Date: Apr 2009 Posts: 157 Rep Power: 8 Hi miko, could u explain me where the STEP function used?give me an example plz.

 April 15, 2009, 09:45 #9 Member   Pratik Mehta Join Date: Mar 2009 Posts: 32 Rep Power: 8 hi , First of all step function is nothing but a user defined region of interest. Consider an example, say we are observing a flow in a annulus pipe ( imagine a donut kind of shape ) . In such a case when you want to calculate some quautity of interest like say turbulent kinectic energy on some specified volume region. so to obtain this necesary volume , step function plays a vital role . For example u specify a expression as userstep= step (Y/1 [mm]) ,then you will get volume region of all that lies in the positive Y axis . You can plot a contour of your step function to see whether the region is the one you wanted or not . Hence then you could say (VolInt(turbulent kinectic energy) @ domain1 )*userstep this will give you the turbulent kinectic energy only in that particular region . I hope now have got my explanation !!! best of luck

 April 8, 2013, 07:07 #10 Member   Pjotr Join Date: Mar 2012 Posts: 30 Rep Power: 5 is also useful for a timestep. For example i want a timestep until 100 iteration of 0.01sek and after 0.05sek. it will look like: timestep=0.01[s] + step(ctstep-100)*0.04[s]

 April 9, 2013, 05:38 #11 Member   Pjotr Join Date: Mar 2012 Posts: 30 Rep Power: 5 i have just tested with cfx5solve in Expressions. step(-0.1)=0 step(0)=0.5 step(0.1)=1

 Thread Tools Display Modes Linear Mode

 Posting Rules You may not post new threads You may not post replies You may not post attachments You may not edit your posts BB code is On Smilies are On [IMG] code is On HTML code is OffTrackbacks are On Pingbacks are On Refbacks are On Forum Rules

 Similar Threads Thread Thread Starter Forum Replies Last Post anirudster CFX 22 November 3, 2013 01:07 gina Fluent UDF and Scheme Programming 7 June 2, 2009 14:04 coompressor OpenFOAM Installation 0 November 12, 2008 20:53 Tong FLUENT 0 May 2, 2008 15:51 John CFX 4 October 20, 2005 00:39

All times are GMT -4. The time now is 06:36.