I tried to write a UDF to translate the "cup" with a horizontal sinusoidal motion. This is what is looks like: MovingTank.c



Then I put this file in the my working directory under....  dp0/FFF/Fluent. And then use the interpret function in setup. 


These are two issue that I am experiencing:


1) My cup has dimensions 20m wide and 30m height and I want it be filled with water up to 20 meter. How do I do that, I tried setting the value "water Volume Fraction" in the initialization tab to 0.6667 but this doesn't seem to work? 


2) To use the UDF where should I call it, in the boundary conditions and define "Wall Motion"--> "Moving Wall" or somewhere else?


Please help me out.