|
[Sponsors] |
![]() |
![]() |
#1 |
Member
Join Date: Jun 2012
Posts: 32
Rep Power: 14 ![]() |
Hi all,
Hi am unexperienced in UDF compiling. So I'd like to show you my case and hope to receive some help... I want to move the hole I have in my domain as shown in the picture attached. For that, I suppose to make an UDF as follows: # include "udf.h" # include "dynamesh_tools.h" *************HOle Movement************************** DEFINE_CG_MOTION(holemov, dt, vel, omega, time, dtime) { Thread *t; face_t f; vel[1]=40; } So the walls of the hole have a constant speed of 40 m/s. I know that I miss some things in the UDF, but as the case is quite simple, it is sure that there is somebody that could help me... ![]() Thank you for your help!!! ![]() |
|
![]() |
![]() |
![]() |
![]() |
#2 |
New Member
phanh
Join Date: Feb 2011
Posts: 20
Rep Power: 15 ![]() |
Quote:
Tell me exactly which problem are you facing with your UDF code? I may help you |
|
![]() |
![]() |
![]() |
![]() |
#3 |
Member
Join Date: Jun 2012
Posts: 32
Rep Power: 14 ![]() |
Thank you phanh for your interest. I have tested the UDF and it seems to do what I wanted (to move the hole in one direction). So the problem is solved and the dynamic mesh not produces any.
But thank you again ![]() Regards |
|
![]() |
![]() |
![]() |
![]() |
#4 |
New Member
songjianxin
Join Date: Nov 2012
Posts: 4
Rep Power: 14 ![]() |
Quote:
|
|
![]() |
![]() |
![]() |
![]() |
#5 |
Senior Member
Rick
Join Date: Oct 2010
Posts: 1,016
Rep Power: 27 ![]() |
vel[1] moves in y direction; looking at the picture DonQuijote wants to move the object in +- x direction, so he must use vel[0]; supposing you want to move the object with constant 40 m/s velocity in +x direction you have to write vel[0]=40;
Daniele |
|
![]() |
![]() |
![]() |
![]() |
#6 |
Member
Join Date: Jun 2012
Posts: 32
Rep Power: 14 ![]() |
Sorry, I forgot this post since I finally didn't develop so much the model.
What ghost82 comments is totally right! I had to change the direction of velocity to vel[0] (when I first began the thread I didin't know what [1] means...). Since I only wanted to move in one direction (x+), vel[0]=40. Regards |
|
![]() |
![]() |
![]() |
![]() |
#7 | |
New Member
songjianxin
Join Date: Nov 2012
Posts: 4
Rep Power: 14 ![]() |
Quote:
![]() |
||
![]() |
![]() |
![]() |
![]() |
#8 | |
New Member
songjianxin
Join Date: Nov 2012
Posts: 4
Rep Power: 14 ![]() |
Quote:
|
||
![]() |
![]() |
![]() |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Explanation moving mesh, moving frame, or dynamic mesh | fbar | FLUENT | 1 | April 13, 2012 08:57 |
Turbulent compressible solver rhoTurbFoam with dynamic moving mesh | eno | OpenFOAM Running, Solving & CFD | 4 | December 12, 2011 04:38 |
Dynamic 'moving' mesh | DarrenC | Main CFD Forum | 3 | March 17, 2010 02:45 |
Question on InterFoam moving mesh capabilities | ziv | OpenFOAM Running, Solving & CFD | 0 | April 23, 2008 10:11 |
fluent add additional zones for the mesh file | SSL | FLUENT | 2 | January 26, 2008 12:55 |