Why won't this Casimir effect perpetual motion machine work? So the Casimir effect is caused by an imbalance in radiation pressure(caused by virtual particles) on two sides of a metal plate. This is typically shown with two close plates getting pushed towards each other. The net force these two plates experience towards each other increases as they get closer. This is because as they get closer there are less virtual particles hitting the inner sides of the plates and around the same amount of virtual particles hitting the outer sides of the plates.
I decided to take this idea a bit further by adding a third plate in between the other two plates. The forces on the middle plate caused by virtual particles should cancel out. The outer plates however experience a greater imbalance in radiation pressure as less virtual particles are hitting the inner side of the plate. Thus the addition of the third plate brings the outer plates closer together. This is illustrated in the GIF below.

Lets say the third(middle) plate was rectangular and on a pivot(in a zero-friction environment) so that as it rotated the third plate went from being between the two plates to not being between them periodically. This would mean the outer two plates would constantly be changing in distance from each other. Such a motion could be exploited to create really really small amounts of energy via piezoelectric materials or the plates pushing/pulling pistons. I don't see how the harvesting of this energy from the outer plates could possibly slow down the rotation of the third plate because the Casimir effect doesn't work that way. This means you could do this forever to create infinite energy really slowly. Where is the flaw in my logic?
Also correct me if I used the wrong terminology.
 A: The third plate will be attracted into the gap between the two outer plates so you get work, $E_\text{in}$, as the third plate moves into the gap. Then you have to do work, $E_\text{out}$, to pull the third plate out of the gap again. If the two outer plates stay fixed then the two amounts of work are equal:
$$ E_\text{out} = E_\text{in} $$
and energy is neither created nor destroyed. So far so good.
Now put the third plate in the gap, and get energy $E_\text{in}$, then let the outer plates move inwards under the Casimir force getting more work $E_\text{gap}$. The trouble is that you have increased the attraction of the third plate into the gap, so it now takes a higher energy $E'_\text{out} \gt E_\text{out}$ to pull the plate out again. You'll find that:
$$ E'_\text{out} = E_\text{in} + E_\text{gap} $$
and the net energy you got out is still zero.
Putting the plate into the gap is analogous to putting the plate into a region of lower pressure. When you bring the two outer plates together you are in effect lowering the pressure further. So your idea is like putting the plate into a low pressure area but having to pull it out of a lower still pressure area.
