Things do not normally proceed in that manner. Usually, Department 2 demand rises, leading first to the run down of inventories, as Department 2 capitalists wait to see if the upturn is real. Then they place orders for additional material, utilising existing capacity and workers; then they take on additional workers, working shifts etc. Then they invest in additional production capacity, more machines, factories etc.
A look at what happens with materials is an illustration. The development of new mines etc. only occurs some time after demand for iron ore etc. has risen. In the meantime, existing mines are worked more intensively. That is why at the start of new periods of growth, prices for materials rise sharply as the bringing on stream of new productive capacity seriously lags consumer demand.
During a period of boom, its quite possible accumulation in Department 1 could get ahead of Department 2, especially given long development time for new mines etc. The kind of investment currently being seen in things such as shale gas, as well as the opening up of vast new mines in Central Asia, Africa and Latin America are part of that process. That does then lead to overproduction in Department 1, or at least to stagnant or falling primary product prices, followed by long periods of under investment. The sharp fall in oil prices that began in 2014, and the fall in the prices of a range of other primary products, including food, around the same time, are an illustration of that point.
There seems no reason, why, if Department 1 capitalists have produced additional means of production, Department 2 capitalists will oblige them by buying them, unless they also experience rising demand for their products, which in itself is unlikely, other things being equal, if Department 1 capitalists have reduced their consumption of consumer goods in order to invest more in production. Its far more likely that Department 2 capitalists will take advantage of the relative over production in Department 1, to force down prices of inputs, increase their profits and realise them in a shift towards 2(b) production.
If demand for necessities in Department 2 is rising so that 2(a) prices and profits rise, then there is a reason why Department 2 capitalists shift resources to 2(a) from 2(b), but its hard to see why they would also accumulate, but without that impetus. I'll come back to this later.
There is a simple answer, which Marx gives in his analysis of rent, in Capital III. Ricardo, made the argument set out above, to suggest that additional land can only be brought into use (so additional capital advanced, and production expanded), if prices were rising, caused by rising demand, thereby increasing the rate of profit. But, Marx points out that, every year, the population is expanding, and with the increase in population comes a natural rise in the demand for all commodities. The producers of all commodities, therefore, do not need to see some specific rise in demand that causes higher prices, which then leads them to invest in additional supply. Each capitalist expects demand for their commodities to rise every year, therefore, and as each capitalist seeks to capture their share of this increased demand, and thereby increase their profits, each builds in a natural increase in their production, and the size of their capital.
This is the basis of expanded reproduction. It does not require higher prices of commodities, or higher rates of profit to bring it about, only a steadily rising level of demand, as a result of population growth, or a natural expansion in the standard of living of the existing population. That is what Marx is describing here, as opposed the mechanism by which the business cycle operates. Having said that, it should be fairly clear that these periods of expansion in demand are not uniform. That is the nature of the long wave cycle, and of the shorter run business cycle. During certain periods, demand may rise sharply, causing sharp rises in prices and profits, which in turn leads to noticeably increased levels of investment in those forms of production, and production of the inputs required.