5
$\begingroup$

I'm studying the parameter shift rule and got stuck when improving an example with Pauli operators in https://arxiv.org/abs/1803.00745.

This paper shows up $\partial_\mu f=\frac{1}{2}(f(\mu+\frac{\pi}{2})-f(\mu-\frac{\pi}{2})) $ when measuring in z-basis. But how this formula change with x-basis?

$\endgroup$

2 Answers 2

2
$\begingroup$

In quantum computing, we almost always measure in the z-basis (by convention). Of course, we can also use other conventions, but we seem to stick to the z-basis.

To answer your question, the formula does not change and is irrelevant for the measurement basis used. The whole idea of the parameter shift rule is to avoid the problem of the finite-difference approximation of measuring 2 points very close to each other and produce a meaningless gradient value. With the parameter shift, you shift the measurement of the finite difference (using conditions on the ansatz) pi/2 away from the current point.

So, just go ahead and use the formula!

$\endgroup$
0
$\begingroup$

I would also recommend this explanation from PennyLane, which contains several examples, including a Pauli Gate example.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.