Hi;
I am trying to plot a function in a interval and with some conditions ( a simple example, x taking only values higher than 10…). How can I define this? I have looked at TF1 documentantion but I didn´t find something that can help me
Thank you
Hi;
I am trying to plot a function in a interval and with some conditions ( a simple example, x taking only values higher than 10…). How can I define this? I have looked at TF1 documentantion but I didn´t find something that can help me
Thank you
MMM what I mean is if it is possible to do something in this way:
TF1 tf = new TF1(“f”,"xsin(x)","{x>0}",-100,10);
where “{x>0}” means a condition ( like for example in other cases x>0 && y>3 and z<5)
Regards
No, that wouldn’t work. What you can use instead is that when using e.g. (x>0) in a float context the boolean value will be implicitly converted to a float (false to 0, true to 1). For example a Heaviside Step function would be
You example could be written as