|
[Sponsors] |
November 19, 2014, 06:09 |
Field Function
|
#1 |
New Member
Daniel GRimbs
Join Date: Nov 2014
Posts: 2
Rep Power: 0 |
hey,
I have problems with my Field Function. I would like to simulate movement and move the object in the Z-axis (dependent on time). the equation of motion I have already written, but I have a problem that does not move the object in the negative direction of the coordinate system. I hope someone of you can help me further. Here is the definition of Field Function: [($ Time <0.4)? 10 : (($ time>= 1.3) && ($ Time <1.7))? - 10: 0,0,0] |
|
November 20, 2014, 03:03 |
|
#2 | |
Senior Member
Mark Olesen
Join Date: Mar 2009
Location: https://olesenm.github.io/
Posts: 1,686
Rep Power: 40 |
Quote:
The position Code:
MyPosition = ($Time < 0.4) ? 10 : (($Time >= 1.3 && $Time < 1.7) ? -10 : 0) Code:
[${MyPosition}, 0, 0] Valid for STARCCM (and C/C++/Java etc) Code:
conditon1 ? val1 : (condition2 ? val2 : val3) Code:
conditon1 ? val1 : condition2 ? val2 : val3 |
||
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Foam::error::PrintStack | almir | OpenFOAM Running, Solving & CFD | 91 | December 21, 2022 04:50 |
problems after decomposing for running | alessio.nz | OpenFOAM | 7 | March 5, 2021 04:49 |
Moving mesh | Niklas Wikstrom (Wikstrom) | OpenFOAM Running, Solving & CFD | 122 | June 15, 2014 06:20 |
Rectangular pulse as field function | Jul1731 | STAR-CCM+ | 3 | April 4, 2014 11:54 |
OpenFOAM static build on Cray XT5 | asaijo | OpenFOAM Installation | 9 | April 6, 2011 12:21 |