I'm trying to model the scheduling of maintenance in some machines, and was wondering how I could ensure that, if maintenance is planned to start in period $t$, then it has to be carried out until period $t+k-1$, where $k$ is the duration of maintenance. This maintenance is not a one time thing, multiple maintenance actions are possible.
If $m_t$ is a binary variable saying that maintenance is scheduled in period t, then what I want is similar to:
$$m_t = 1 \implies \sum_{i=-k+1}^{i=k-1} m_{t+i} = k, \forall t>k$$
But this does not model what I want, since the 1's have to be consecutive, but beyond that, I do not wish to use logical constraints and would rather avoid their direct linearizations, if possible. Is there a way to efficiently model this sort of thing? It does not need to be linear.