# In the CHSH inequality, how can I know which term is supposed to have the minus sign?

I try to follow the calculation from IBMQ experience regrading of Entanglement and Bell test which they derive the value of question as $$$$C=\langle A B\rangle-\left\langle A B^{\prime}\right\rangle+\left\langle A^{\prime} B\right\rangle+\left\langle A^{\prime} B^{\prime}\right\rangle$$$$ where ; $$\langle A B\rangle= p_{++}+p_{--}-p_{+-}-p_{-+}$$ and $$A , A'$$ is Alice's basis, $$B, B'$$ is Bob's basis of measurement

the choice of the basis they chose is following this $$A = Z, A' = X$$ and $$B = W, B' = V$$ where

then they have $$$$\langle Z W\rangle=\langle Z V\rangle=\langle X W\rangle=\frac{1}{\sqrt{2}},\langle X V\rangle=-\frac{1}{\sqrt{2}}$$$$ so that $$|C| = 2\sqrt{2}$$ which greater than $$2$$

Now, they do this experiment on the real device and obtain the following value

The question is if following their choice of basis then $$\langle AB' \rangle$$ = $$\langle ZV' \rangle$$ but from their calculation, it can be seen that $$\langle AB' \rangle$$ = $$\langle XV' \rangle$$ which seem to agree with above value.

So what is supposed to be right and wrong in this calculation and how can I know theoretically which basis is supposed to have a minus sign from this choice of basis.

Note : the link to reference will redirect to another page https://quantum-computing.ibm.com/support/guides/introduction-to-quantum-circuits?page=5cae705d35dafb4c01214bc5 from that page --> Introduction to Quantum Circuits --> Entanglement and Bell Tests Sorry for the inconvenience.

The fact is that it doesn't matter. So long as one of the four terms has the minus sign on it, you'll get a suitable test. Yes, there seems to be some inconsistency with labelling the different cases, but it's not a big deal - nothing physically changes if you swap which measurement basis you call $$A$$ and which you call $$A'$$ for example; you're still doing the same experiment. Obviously in this case you want to calculate $$\langle ZW\rangle+\langle ZV\rangle+\langle XW\rangle-\langle XV\rangle.$$