# How to construct a quantum circuit that given $|\psi_0\rangle,|\psi_1\rangle$ outputs $\frac{1}{c}(|\psi_0\rangle+|\psi_1\rangle)$?

Suppose I have two arbitrary quantum states $$\lvert \psi_1 \rangle$$ and $$\lvert \psi_2 \rangle$$. Further suppose that we know $$U_1$$ such that $$\lvert \psi_1 \rangle = U_1 \lvert 0 \rangle$$, but we don't know $$\lvert \psi_2 \rangle$$ (only can use it as an initial state). Using ancilla qubits and measurements, is there a way to construct quantum circuits such that one of the wires of the output state is $$\frac{1}{c}(\lvert \psi_1 \rangle + \lvert \psi_2 \rangle)$$?

• possible duplicate of quantumcomputing.stackexchange.com/q/11554/55
– glS
May 23, 2022 at 20:56
• To make it clear, I made my question clearer. The set-up is little bit different from what you posted. May 23, 2022 at 21:45
• You say $|\psi_2\rangle$ is arbitrary, but the output state implies it's orthogonal to $|\psi_1\rangle$. May 23, 2022 at 22:12
• @GotCarter Sorry for the confusion. I think that normalization factor shouldn't be $1/\sqrt{2}$, but just something $1/c$ that normalizes the state properly. Just edited. May 24, 2022 at 0:22
• This might be helpful quantumcomputing.stackexchange.com/questions/14185/… May 24, 2022 at 19:46