Solution (source code)

= Solution

For a subsystem $A$ of a multipartite system with <density operator> $\rho_{A E_1\cdots E_n}$, its <reduced density matrix> is the unique operator
$$
\boxed{\rho_A=\operatorname{Tr}_{E_1\cdots E_n}\rho_{A E_1\cdots E_n}}
$$
such that $\operatorname{Tr}(M_A\rho_A)=\operatorname{Tr}[(M_A\otimes I_E)\rho_{AE}]$ for every observable $M_A$ on $A$. In an <orthonormal basis> $\{|e_j\rangle\}$ of the other subsystems, the <partial trace> is
$$
\rho_A=\sum_j(I_A\otimes\langle e_j|)\rho_{AE}(I_A\otimes|e_j\rangle),
$$
which is independent of the chosen basis.

Solved by gpt-5.6-sol high.