# Trouble with Field Functions

 User Name Remember Me Password
 Register Blogs Members List Search Today's Posts Mark Forums Read

 September 12, 2010, 05:50 Trouble with Field Functions #1 New Member   F Join Date: Aug 2010 Posts: 3 Rep Power: 9 Hi all, I working on a project as part of my undergrad BE degree, i am trying to simulate the movement of air caused by a vibrating piezoelectric cantilever beam. So far I have approached the problem in a similar manner as to that used in the contracting cylinder tutorial in the user guide. I am able to get my beam to deflect in one direction based on a simple y=x^2 curve. Now the next step is to make the beam deflect back and forth (like a Japanese fan) , however i am unable to get this to work with field functions, is there a way you can code loops and while statements in there? I was also attempting to create user coded functions but am unable to get this set up as explained in the user guide especially where it describes Library registrations etc... Could anyone shed any light on this issue or have better ideas of how to solve this problem. Thank you! -Stefanus

 September 13, 2010, 08:29 #2 New Member   Join Date: Mar 2009 Posts: 20 Rep Power: 10 Hi falkin, I asked the question about loops in a field function the adapco support some weeks ago. They said, it is not possible to do loops in field functions. You can do some if then loops (using the "?", e.g. Tutorial Cavitation) but thats it. So I think you have to use the user coding, but I have no experience with that. Regards xamo

 October 6, 2010, 08:15 #3 New Member   Join Date: Jul 2010 Posts: 11 Rep Power: 9 User coding would not be the means of choice. You can do loops in Java macros, which is something different. But I think the easiest way would be to implement an if statement in you fieldfunction. I'm not sure how you achieved the bending of your beam. If you applied a force then it might look like the following E. g. if maximum displacement of the beam is greater than a certain value then the force is pointing in the other direction. You can get the maximum displacement by means of a report cheers Andreas

 Thread Tools Display Modes Linear Mode

 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 OffTrackbacks are On Pingbacks are On Refbacks are On Forum Rules

 Similar Threads Thread Thread Starter Forum Replies Last Post tsagaro FLUENT 7 June 23, 2017 15:45 Niklas Wikstrom (Wikstrom) OpenFOAM Running, Solving & CFD 122 June 15, 2014 06:20 tobe STAR-CCM+ 0 September 8, 2010 02:25 matteo_gautero OpenFOAM Running, Solving & CFD 0 February 28, 2008 07:51

All times are GMT -4. The time now is 23:35.

 Contact Us - CFD Online - Privacy Statement - Top