Before the collision, the total momentum of the two train cars is
(13.0 kg) (3.40 m/s) + 0 = 44.2 kg•m/s
After the collision, the two cars have velocity v₁ and v₂ so that their total momentum is
(13.0 kg) v₁ + (38.0 kg) v₂
Momentum is conserved, so
(13.0 kg) v₁ + (38.0 kg) v₂ = 44.2 kg•m/s
Before collision, the total kinetic energy of the two cars is
1/2 (13.0 kg) (3.40 m/s)² + 0 = 75.14 J
and after collision,
1/2 (13.0 kg) v₁² + 1/2 (38.0 kg) v₂²
Energy is also conserved, so
1/2 (13.0 kg) v₁² + 1/2 (38.0 kg) v₂² = 75.14 J
or
(13.0 kg) v₁² + (38.0 kg) v₂² = 150.28 J
Solve the momentum equation for either v₁ or v₂ :
(13.0 kg) v₁ + (38.0 kg) v₂ = 44.2 kg•m/s
⇒ v₂ = (44.2 kg•m/s - (13.0 kg) v₁) / (38.0 kg)
Substitute this into the energy equation and solve for the other variable :
(13.0 kg) v₁² + (38.0 kg) [(44.2 kg•m/s - (13.0 kg) v₁) / (38.0 kg)]² = 150.28 J
⇒ (17.4 kg) v₁² - (30.2 kg•m/s) v₁ + 51.4 J ≈ 150.28 J
⇒ (17.4 kg) v₁² - (30.2 kg•m/s) v₁ - 98.9 J ≈ 0
Using the quadratic formula,
⇒ v₁ = 3.40 m/s or v₁ ≈ -1.67 m/s
(We ignore the second solution because that's the initial condition.)
Solve for the remaining velocity:
v₂ = (44.2 kg•m/s - (13.0 kg) (-1.67 m/s)) / (38.0 kg)
⇒ v₂ ≈ 1.73 m/s