CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   CFX (https://www.cfd-online.com/Forums/cfx/)
-   -   Limiting an expression (https://www.cfd-online.com/Forums/cfx/122883-limiting-expression.html)

 philblitz August 30, 2013 08:25

Limiting an expression

Hi everyone,

my question is about limiting an expression in CFX post.

I know how to get the total force on a certain surface, just define "force_x()@surface".

But is it also possible to just evaluate the force of a certain part of a surface without splitting the surface in different parts?

My geometry for example extends from x=0 to x=1000 and i now want to calculate the force at this surface between x=0 and x=200.

 philblitz August 30, 2013 12:57

In the meantime, i found a way to calculate what i asked before.

1. Open the .res file in CFX post
2. Search for the "export" command
3. In the new window, select the surface you want to work on and "Force X"
4. Save the .csv file (contains four columns X, Y, Z and ForceX )
5. Import the .csv file into Excel or OpenOffice
6. Sort all four columns according to X
7. Sum up the ForceX column for a certain X range and voila!

 flotus1 August 30, 2013 16:10

This method will surely do the trick, but wouldnt it be easier to create a new clipped plane from the actual plane in CFD post?

 ghorrocks August 30, 2013 21:54

Also - the method described by Phil will be approximate. When evaluated in CFX it uses the integration points to calculate to forces, whereas the exported data is simplified back to the nodes. So you will get a more accurate force measurement with Alex's suggestion.

 philblitz August 31, 2013 02:15

But will the clip plane method really work? I can't access CFX at the weekends, so i'll have to wait until Monday to try it.

From the cfx_post.pdf, i get the following:

"10.11 clip command

...A clip plane will act on all objects in the Viewer, including the Wireframe, but will not affect other functions such as calculations (that is, a calculation will still use the entire location, whether visible or not)."

Another method to use could be a contour plot of X, as described here:
http://www.cfd-online.com/Forums/cfx...html#post82873

 flotus1 August 31, 2013 03:36

Quote:
 Originally Posted by philblitz (Post 448997) ...A clip plane will act on all objects in the Viewer, including the Wireframe, but will not affect other functions such as calculations (that is, a calculation will still use the entire location, whether visible or not)
"force_x()@surface" "force_x()@clipped_surface"

 ghorrocks August 31, 2013 08:12

CFD-Post has a lot of options for generating surfaces. You can also generate them by planes, between contour lines and from isosurfaces. So if the clip plane option does not work there are plenty of others.

 philblitz September 2, 2013 13:18

Today it compared the different methods with the expression "force_x()@surface", which has a value of 1,09183 N.

My "export to Excel" method resulted in 1,09183 N.

The second method (Iso Clip from the original surface) gave a result of 1,08742 N.

The third method (user surface from Contour plot level) showed a value of 0,29218 N.

The following picture shows where how much drag is produced across my surface (from ~-2,15m to 0,9m). The upper two lines (Excel and Iso Clip method) match each other, but the third (Contour) shows huge differences. The overall shape is the same although.

http://img689.imageshack.us/img689/4525/u6vd.png

 brunoc September 2, 2013 13:48

Use the method which calculates the force based on the iso-clip. That should be the correct one.

For future simulations, split the surface on the place you'll want to measure. That way you'll be able to measure forces directly from the solver, eliminating any possible sources of error from interpolation the mesh/results.

By the way, how are you measuring force with a contour?

 philblitz September 3, 2013 03:37

Measuring a force via a contour plot works the following. But i would not recommend it as the differences are to big compared to the other methods for my geometry.

1. Create a contour plot on a surface, in my case contour of X
2. Create an user surface from this contour and select the contour level
3. Create an expression: force_x()@user surface

 All times are GMT -4. The time now is 19:53.