It's been a while since someone has done one so here is a little quiz...
Can you make a single equation function for the attached graph without using if statements? Note that all segments of this graph are straight lines; there are no curves at the corners, just sharp corners.
From high school Algebra I remember the notation for writing a function that is defined differently along different parts of it's domain. It's called a compound or piecewise function. Your graph is trivial with linear equations if this is allowed. As far as I'm concerned this is a different "if" notation, just like Pete's suggested ternary operator.
That is basically what I said.Generate a function for each segment of the profile.
v(t)=v(0)*f(t,t(0),t(0),t(1))+
v(1)*f(t,t(0),t(1),t(2))+
v(2)*f(t,t(1),t(2),t(3))+ ....
That is basically what I said.
In C there is the ? : construct. It is a one line if then else.
One can also write a switch or case of statement on one line.
Peter Nachtwey said:No IF is necessary. My ? function could be any function that returns a 1 or 0 based on the sign of the result of t-t0 or t>=0. Just rewrite my initial solution replacing the ?() with a f() and a f(t>=0) with a f(t-0) the result is the same.
If by compound you mean that
f(x) = g1(x) + g2(x) + g3(x)+...
then it is compound.
I imagine that you have a clever recursively defined function that includes both t and past factors and absolute values