TWe have used a two-dimension fully electromagnetic particle in cell(PIC) simulation to study the relativistic A-6 magnetron designed by Palevsky and Bakefi, and analysed the physics picture. Specially, we have researched the relation of the output impedance with the output power and operating modes and given the optimal output impedance corresponding the maximum output power.