|
[Sponsors] |
January 9, 2021, 20:12 |
Dynamic Mesh UDF for a Piston
|
#1 |
New Member
Mickael Perrin
Join Date: Dec 2020
Posts: 9
Rep Power: 6 |
Dear users, hello !
I work on a simulation and request your help. You can see my geometry in attachments. I am working on a thermal exchange between a solid zone (SOLID on the figure) and a fluid zone (FLUID1, 2 & 3). The flow is generated by a synchros move of boundaries (WALL A) and (WALL B). The problem i encounter is generated by the interface between (SOLID) and (FLUID 2) area : - when i assign and classic interface between the two zone, fluent returns me a SIGSEGV error - when i change this interface for a wall (so there is no longer heat echant because the solid become totally insulated), the calcul run perfectly. I suspect that i have to define additional zone but i am not sure. As SIGSEGV error generally comes in with UDF error, i request your help ! Here there is my code, the move i want to do is a simple sinusoidal signal. Code:
#include"udf.h" #include"mem.h" #include"math.h" double TimeStepSize = 0.01f; double lenght = 0.045f; double alpha = 0.56f; double frequency = 0.5f; double Vmax = 0.f; static real velx = 0.0; double Omega; DEFINE_CG_MOTION(Piston, dt, vel, omega, time, dtime) { NV_S(vel, =, 0.0); NV_S(omega, =, 0.0); Vmax = alpha * M_PI * frequency * lenght; Omega = 2 * M_PI * frequency; velx = (Vmax / Omega) * (cos(Omega * (time - TimeStepSize)) - cos(Omega * time)) / TimeStepSize; vel[0] = velx; } Do i have to make a static define motion UDF and assign it somewhere ? Is there any error in my UDF ? Thank you for reading and for your time ! Happy New Year !! |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
udf for valve closing a pipe using dynamic mesh | chem engineer | Fluent UDF and Scheme Programming | 2 | May 13, 2017 10:39 |
UDF CG_MOTION rotation dynamic mesh | Mads | FLUENT | 2 | April 15, 2014 04:30 |
UDF for Dynamic Mesh | vasava | Fluent UDF and Scheme Programming | 2 | September 25, 2013 01:54 |
Dynamic Mesh UDF Parallelization | sy_aloy | FLUENT | 0 | February 13, 2006 13:14 |
Problem related with UDF for dynamic mesh | Ryan | FLUENT | 6 | April 29, 2004 10:29 |