Let $W^C_t$, $W_t$ be binary variables and $p$ an integer variable with $1 \leq p \leq 3$
The variables are related through the following equation:
$$W^C_t = \sum_{\theta=1}^{p} W_{t-\theta}$$
I can linearise this equation by introducing indicator variables $Y_1, Y_2, Y_3$ and requiring:
IF $Y_1=1$ THEN $W^C_t = W_{t-1}$
IF $Y_2=1$ THEN $W^C_t = W_{t-1} + W_{t-2} $
IF $Y_3=1$ THEN $W^C_t = W_{t-1} + W_{t-2} + W_{t-3}$
$Y_1 + Y_2 + Y_3 = 1$
This approach may, depending on the problem, to a large amount of constraints.
The question is, is there a better way to model the equation?