How to solve a knapsack problem where variable weight limit?

I have a knapsack problem where the sack size can increase, decrease or stay same in every time unit. The change pattern is known beforehand.

Can anyone help me about how to solve this?