CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > FLUENT

UDF for Oscillations

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 10, 2004, 16:00
Default UDF for Oscillations
  #1
Cfdtoy
Guest
 
Posts: n/a
Hi

In case i want to oscillate a wall with a frequency f, does anyone know how to create a UDF for the same ? . There is a spring analogy in the website however, i want the oscillation to be somethin like a sine wave kinda.

thanks for ur time and help

Cfdtoy

  Reply With Quote

Old   February 16, 2004, 02:21
Default Re: UDF for Oscillations
  #2
FJ
Guest
 
Posts: n/a
Hi,

DEFINE_CG_MOTION is very suitable for your issue. If the wall velocity is a function of time, It's very easy to coding . You just define the following in the UDF macro.

vel[0] = sin(2*3.14*f)

Thanks

FJ
  Reply With Quote

Old   February 18, 2004, 16:50
Default "Non Positive Volumes" ..Re: UDF for Oscillations
  #3
Cfdtoy
Guest
 
Posts: n/a
Hi there

Thanks for the response. I used the sinusoidal variation, I kinda tend to get "non-positive volume Exist" Message during my simulation using Dynamic Meshes.

Although, I use min and max volumes as the same as given by the Grid Check Function

Does anyone know how to treat the message ?

Thanks

CFDtoy
  Reply With Quote

Old   February 23, 2004, 00:42
Default Re: "Non Positive Volumes" ..Re: UDF for Oscillati
  #4
FJ
Guest
 
Posts: n/a
Hi,

It must be that the time step size is too large to re-mesh. To use small time step size, it will be no problem.

FJ
  Reply With Quote

Old   February 26, 2004, 17:11
Default Re: UDF for Oscillations
  #5
Cfdtoy
Guest
 
Posts: n/a
Hello FJ...

Thanks for the response. I would like to explain my situation a little better. I have an object ( say Diameter 'd') placed in a liquid. This rod ( solid wall around) is protuding inside the domain. Now, the rod is made to move back and forth with an frequency 'f' ..so..if i take a rod placed in the domain and mesh it around, the movement of the wall (rod) would be considered as a case of dynamic meshing isnt it ? Hence, I request help for writing a UDF for the wall movement ..I did look around Fluent and came to know about the Define_CG_Motion but how about Define_Grid_motion ?

If you can ..can you help me with a sample code ?

Thanks

CFDtoy
  Reply With Quote

Old   February 27, 2004, 01:20
Default Re: UDF for Oscillations
  #6
FJ
Guest
 
Posts: n/a
Hi,

I'll send you cas file and UDF directly.

FJ
  Reply With Quote

Old   March 12, 2004, 07:21
Default Re: UDF for Oscillations
  #7
Qureshi
Guest
 
Posts: n/a
Can I also have the file and UDF?
  Reply With Quote

Old   March 15, 2004, 04:36
Default Re: UDF for Oscillations
  #8
FJ
Guest
 
Posts: n/a
Hi,

The UDF is very simple , see the followings.

---

#include "udf.h"

real freq = 1.;

DEFINE_CG_MOTION(osc, dt, vel, omega, time, dtime) {

vel[0] = sin(2*M_PI*freq*time);

}

---

This is my personal opinion that UDF for FLUENT MDM function is not so difficult compared with its settings. I mean, I think , most difficult settings is "Define-Dynamic Mesh-Zones". Sometimes this function makes me unhappy!.

FJ
  Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Dynamic Mesh UDF Qureshi FLUENT 7 March 23, 2017 07:37
UDF parallel error: chip-exec: function not found????? shankara.2 Fluent UDF and Scheme Programming 1 January 16, 2012 22:14
How to add a UDF to a compiled UDF library kim FLUENT 3 October 26, 2011 21:38
UDF...UDF...UDF...UDF Luc SEMINEL FLUENT 0 November 25, 2002 04:03
UDF, UDF, UDF, UDF Luc SEMINEL Main CFD Forum 0 November 25, 2002 04:01


All times are GMT -4. The time now is 00:13.