To Problem 2.22 in Options, Futures, and Other Derivatives (8th edition) below:
When a futures contract is traded on the floor of the exchange, it may be the case that the open interest increases by one, stays the same, or decreases by one." Explain this statement.
the Solution is:
If both sides of the transaction are entering into a new contract, the open interest increases by one. If both sides of the transaction are closing out existing positions, the open interest decreases by one. If one party is entering into a new contract and the other party is closing out an existing position, the open interest stays the same.
I can understand the "increases by one" case but have difficulty in understanding the latter two cases, probably I did not fully understand the "closing out" process. By my understanding, "closing out" means "executing a reversing transaction that is exactly the same as his original trade" and "the positions is usually closed out by entering into a new arrangement with another party" (source). Therefore, "closing out the existing position" does not necessarily imply that the original contract is gone (hence "decreases the open interest by one").
To be more specific, let $A$ and $B$ denote the two parties that traded the new futures contract $x$. Suppose $A$'s existing position is the long position of contract $y$, and $B$'s existing position is the short position of contract $z$. Here both $y$ and $z$ were settled prior to the time that $x$ was settled, which is denoted by $t$. By assumption, $x, y, z$ have the same maturity time $T > t$. In addition, at $t$, $A$ shorts $x$ and $B$ longs $x$. Under this setting, the number of long positions did not decrease by one, but increases by one (in addition to $y$, there is a new outstanding $x$).
Where did I my understanding go wrong?