Floor Coefficient function

More
6 years 2 months ago #740 by ddrake
Hi,

I was wondering if anyone knows of an existing CoefficientFunction that could be used to get the floor (integer part) of another CoefficientFunction. I could use it to generate an arbitrary periodic initial condition.

Thanks,
Dow
More
6 years 2 months ago #741 by christopher
I guess the easiest way is you implement it yourself, how to create a CoefficientFunction is explained here , how to export it to Python here . Basically you just have to replace the code in the Evaluate function with a call to a C floor function.

Best
Christopher
The following user(s) said Thank You: ddrake
More
6 years 2 months ago #742 by joachim
Replied by joachim on topic Floor Coefficient function
floor() and ceil() are available for CoefficientFunctions.
Actually, I exported them to define periodic functions,
Joachim
The following user(s) said Thank You: ddrake
Time to create page: 0.090 seconds