As an attachment, an illustration of the problem. This models a cylinder with an inlet and outlet and piston movement.
- Case 1: When the piston goes down, we have mass flow at intlet and a closed outlet.
- Case 2: When the piston goes up, we have a closed inlet and a pressure at outlet.
I have write the UDF for the movement of the piston.
I want to write a UDF for the inlet and outlet depending on the movement of the piston, i.e. when the acceleration is negativ (Case 1) -> mass flow of x kg/s ; when the acceleration is positiv (Case 2) -> pressure of X Pa
Do i have to use UDM Macros ? In order to change the type of the boundary (mass flow inlet to wall), may I have to use a Scheme file and the TUI-Command or use a journal file?
Value of a UDF depending on another UDF
- 128 Views
- Last Post 16 November 2018
- Topic Is Solved
Yes to change the kind of boundary you need to use scheme. So mixture of UDF and Scheme is required here. Or just use Dynamic Mesh Events to change a boundary type after certain time lasted.
Thank you for your reply. I can´t use Events because I want to do it for a random velocity profil, but good to know that it exists.
In the UDF for the movement of the piston, I have defined the velocity. Can I just define a variable (e.g. acceleration = -sin(..*time)) which has no effect for this UDF, but which is mandatory for the inlet/outlet boundaries UDF? In order to use this variable (acceleration) for the UDF of inlet/outlet, may I have to use UDM?
Yes you can use the UDM's as placeholder for that.
- All Categories
- Community Rules, Guidelines, and Tips
- News & Announcements
- Student Products
- Pre and Post Processing
- Physics Simulation
- Tutorials, Articles and Textbooks
- Installation and Licensing
- Student Competition Teams
- eMasters Degree from UPM
- Site Feedback