From the ideal gas law, we know that the pressure is directly proportional to the number of moles and inversely proportional to the molar mass:
\[
P \propto \frac{n}{M}
\]
Let the molar mass of gas \( A \) be \( M_A \) and that of gas \( B \) be \( M_B \). The pressure exerted by gas \( A \) is 2 atm, and the total pressure after introducing gas \( B \) is 3 atm.
From the ideal gas law:
\[
P_{\text{total}} \propto \frac{n_A + n_B}{M_A + M_B}
\]
After solving for the relationship between the molar masses, we get:
\[
M_A = 4 M_B
\]
Thus, the correct answer is Option 4: \( 4M_A = M_B \).