|
[Sponsors] | |||||
Boundary conditions of UDF writing speed changing with time |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Display Modes |
|
|
|
#1 |
|
New Member
Join Date: May 2020
Posts: 8
Rep Power: 7 ![]() |
The speed changes periodically with time, and UDF is loaded by means of compilation. Fluent is parallel computing, and there are other UDFs. But the recorded data shows that the speed has not changed over time. Please help to see what might be the reason. The following is UDF:
#include"udf.h" DEFINE_PROFILE(air_inlet_velocity,thread,position) { real t,v,a; face_t f; begin_f_loop(f,thread) { t=RP_Get_Real("flow-time"); { a=(int)t%240; if(a>=0&&a<60) { v=(float)a/60+4.63; } else if(a>=60&&a<180) { v=-(float)a/60+6.63; } else if(a>=180&&a<240) { v=(float)a/60+0.63; } } F_PROFILE(f,thread,position)=v; } end_f_loop(f,thread) } |
|
|
|
|
|
|
|
|
#2 |
|
New Member
Dico Nico
Join Date: Oct 2018
Posts: 12
Rep Power: 9 ![]() |
Could it be because you are running in parallel? Maybe, because your domain is solved by diferent nodes, and you are looping in the domain, it is overwriting something, try running in serial, just to see if the velocity changes. When I have more time, I'll give a better look to give you a proper answer.
|
|
|
|
|
|
|
|
|
#3 | |
|
New Member
Join Date: May 2020
Posts: 8
Rep Power: 7 ![]() |
Quote:
|
||
|
|
|
||
![]() |
| Thread Tools | Search this Thread |
| Display Modes | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| bash script for pseudo-parallel usage of reconstructPar | kwardle | OpenFOAM Post-Processing | 43 | October 28, 2025 04:19 |
| courant number increases to rather large values | 6863523 | OpenFOAM Running, Solving & CFD | 22 | July 6, 2023 00:48 |
| AMI speed performance | danny123 | OpenFOAM | 21 | October 24, 2020 05:13 |
| Moving mesh | Niklas Wikstrom (Wikstrom) | OpenFOAM Running, Solving & CFD | 122 | June 15, 2014 07:20 |
| dynamic Mesh is faster than MRF???? | sharonyue | OpenFOAM Running, Solving & CFD | 14 | August 26, 2013 08:47 |