proof of Markov chain Monte Carlo [closed]

This is the first step of proof of MCMC in my notes I have a question, how come $\pi(x)\pi(x_p\mid x)=\pi(x_p)\pi(x\mid x_p)$? Is it true for any markov chains which are ergodic and aperiodic? The text says "we start by constructing a markov chain, making it $\pi(x)\pi(x_p\mid x) = \pi(x_p)\pi(x\mid x_p)$... But how can we prove for any any markov chains which are ergodic and aperiodic, we have $\pi(x)\pi(x_p\mid x)=\pi(x_p)\pi(x\mid x_p)$?

closed as off-topic by Xi'an, Michael Chernick, gung♦Feb 5 '18 at 18:33

This question appears to be off-topic. The users who voted to close gave this specific reason:

• "Self-study questions (including textbook exercises, old exam papers, and homework) that seek to understand the concepts are welcome, but those that demand a solution need to indicate clearly at what step help or advice are needed. For help writing a good self-study question, please visit the meta pages." – Xi'an, Michael Chernick, gung
If this question can be reworded to fit the rules in the help center, please edit the question.

• You're familiar with the relationship between conditional and joint density $f(x,y) = f(y|x) f(x)$? – Glen_b Jul 22 '16 at 2:27
• @Glen_b yes, but in my case, it is a little bit different I guess. For example ,"Bowl A contains 2 red chips; bowl B contains two white chips; and bowl C contains 1 red chip and 1 white chip. A bowl is selected at random, and one chip is taken at random from that bowl.", $P(C|W)P(W)=P(W|C)P(C)=P(C\cap W)$,so $P(C\cap W)$ has a meaning beacuse $P(C|W)P(W)$ and $P(W|C)P(C)$ are the same thing , but in a the markov chain, $\pi(x\cap x_p)$ are different between $\pi(x)\pi(x_p|x)$ and $\pi(x_p)\pi(x|x_p)$ as the two starting positions are different – whoisit Jul 22 '16 at 3:02

how come $π(x)π(x_p∣x)=π(x_p)π(x∣x_p)$?
The Markov transition kernel associated with this algorithm is $$\pi(y|x) = \rho(x,y) q(y|x) + (1-r(x)) \delta_x(y) \;,$$ where $q$ denotes the density of the proposal distribution, $r(x)=\int \rho(x,y) q(y|x) \text{d}y$ and $\delta_x$ denotes the Dirac mass in $x$. It is straightforward to verify that \begin{align*} \rho(x,y) q(y|x)\pi(x)&=\rho(y,x) q(x|y)\pi(y) \\ (1-r(x)) \delta_x(y) \pi(x)&=(1-r(y)) \delta_y(x)\pi(y) \;, \end{align*} which together establish detailed balance for the Metropolis-Hastings chain.
From this equality, establishing stationarity of $\pi$ is straightforward, as seen by integrating both sides in $x$.