# Min or Max Value in CFX-Pre

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

 February 2, 2015, 11:29 Min or Max Value in CFX-Pre #1 New Member   Andreas Join Date: Dec 2014 Posts: 16 Rep Power: 2 Hello Guys, i have a problem simulating scour around a cylindric pile. I want to calculate a dynamic timestep with an empirical equation. for this i need the maximum value of the wall shear stress at the ground for the prevailing moment. CFX says, that it is not possible, to use maxVal(Wall Shear)@... in CFX-Pre. So how is it possible, the get a max or min value for a variable? I did a steady state simulation first, which i load as an initial .res-file for the following transient simulation, just to have initial values to read out. But as i said, i dont know a code to get the maximum of a variable in pre. Is there anybody who knows how to do it??? thanks in advance! greets flashi

 February 2, 2015, 17:51 #2 Super Moderator   Glenn Horrocks Join Date: Mar 2009 Location: Sydney, Australia Posts: 10,652 Rep Power: 84 First a comment - you will find the value of maxVal(Wall Shear) is a very noisy parameter. I think you will find it is not a good parameter to link to time step size. I suspect you will find your equation using maxVal(Wall Shear)@... will work in the solver despite the error in CFX-Pre. CFX_Pre does not have a full CEL parser so does say some expressions are in error when they are correct and work in the solver.

February 3, 2015, 04:19
Error in Solver
#3
New Member

Andreas
Join Date: Dec 2014
Posts: 16
Rep Power: 2
Hey ghorrocks,

i forgot to write that i get an error in cfx-pre (reason: maxVal) and the main error in the solver:

+--------------------------------------------------------------------+
| ERROR #001100279 has occurred in subroutine ErrAction.
| Message:
| Invalid iteration, simulation time or timestep specifications fou-
| nd. Please review these settings and restart the simulation.

+--------------------------------------------------------------------+
| ERROR #001100279 has occurred in subroutine ErrAction.
| Message:
| Stopped in routine ALG_TIMSTEP_INFO

The mesh quality < 0,2 is about 0,4%. Is it still ok? This is because i built a structured mesh for a cylinder, so 4 critical areas appear at perimeter (see attachement). the cylinder is connected per GGI to the surroundings. I can reduce Mesh-Size, but the critical quality zones will stay.

I cannot reduce the timesteps, because it is to be calculated dynamically, which is the problem

Maybe i should work with an unstructured mesh to improve mesh quality?

What do you mean with wall shear is a noisy parameter?

I could calculate Wall Shear Stress with equations and surface velocity, but i would prefer to read out the simulated values for it.

Best regards Flashi
Attached Images
 MQ_Cyl.jpg (60.7 KB, 17 views)

 February 3, 2015, 19:26 #4 Super Moderator   Glenn Horrocks Join Date: Mar 2009 Location: Sydney, Australia Posts: 10,652 Rep Power: 84 Your mesh does look pretty bad. Those very squashed elements at the boundary need fixing. Things will improve significantly when you fix that. Wall shear stress is a derivative of the velocity field. Derivatives amplify noise. Max and min are noisy functions as they are affected by isolated spurious spikes. You are taking the max of a derivative function - I bet the result of this function is so noisy as to be useless. Average and medians reduce noise, as does integrated quantities. By the way: what is the empirical function you want to use to control time step and why do you want to use it?

 February 4, 2015, 02:36 #5 New Member   Andreas Join Date: Dec 2014 Posts: 16 Rep Power: 2 Hello, i have to develop a scour model for an offshore-structure. the first step was to develope a simple model with one phase and a dynamic mesh. So i found out, that there are papers showing how to do it with a displacement of mesh. My displacement for the z-coordinate is Dsoilnew = Dsoilold - DeltaZ where Dsoilold = areaAve(Mesh Displacement Z)@Soil and DeltaZ = MeshvelocityZ * Deltat and Deltat = DeltaZmax (here diameter of a sand particle) / MeshvelocityZmax and MeshvelocityZmax is an empirical function and includes taumax/taucrit. So i planned to import the max value of wall shear stress. Furthermore I changed taubed from an areaAve - command to a calculation taubed = sqrt(taux^2+tauy^2+tauz^2) with taux = Nx*Mu*(Velocity u.Gradient X ...) commands, and so on. Think this is the better way and hope this will work. But the maxVal problem stays. To turn the structure and to simulate easily different current-angles i built the cylindric mesh and connected it per GGI. I will try to get a better mesh then or to bury the idea of a rotating cylinder. Thank you very much for your help. Greetings Flashi

 February 4, 2015, 04:54 #6 Super Moderator   Glenn Horrocks Join Date: Mar 2009 Location: Sydney, Australia Posts: 10,652 Rep Power: 84 With regard to time step, you have two criteria to consider. You need the time step size to be small enough for your scour/mesh motion stuff to be stable and accurately model the scour, and you need the time step to be small enough for the Navier-Stokes solver in CFX to be accurate and stable. I bet the time step size you are talking about only considers the scour modelling, and I further bet the time step size CFX requires is more restrictive. In other words, if you use your proposed time step size the time step will be too big for CFX to be accurate. If what I am saying is correct then you should use the normal CFX time step size, not your proposed one - And your problem of maxVal(Wall Shear) disappears. Have you shown that your scour model requires a finer time step than CFX requires?

 February 4, 2015, 05:52 #7 New Member   Andreas Join Date: Dec 2014 Posts: 16 Rep Power: 2 I'll use a fixed small timestep now instead of a resetting dynamic one and hope to get it work. I'll post some results then. (Next BIG problem for me is a remeshing option, but only if the previous steps will be fine. I couldnt find good info for remeshing though.) I saw your forum-engagement and want to say thanks again