I heard one possible definition of entropy $S$ is the number of possible configurations of microscopic variables that satisfy macroscopic variables such as volume and pressure.
Suppose I have a box with 1 cubic metre of space filled with nitrogen gas at STP.
The temperature of the box is 273.15 K and the pressure is 1 bar.
Suppose I put a barrier into the box that blocks off exactly half of the box from the other half. Half of the gas molecules are blocked off from the other half.
Given that, doesn't that mean that the number of possible microstates are reduced and the entropy is decreased? How much is the entropy reduced by? One thing is that give or take a few neutrons the nitrogen gas atoms are physically indistinguishable and so I am unsure if the entropy is decreased at all.
Note: I don't think this violates the second law of thermodynamics because the system wasn't closed and was disturbed by having a barrier put in.