A piston cylinder arrangement has two compartments, A and B, filled with water as shown in the figurebelow. Compartment A has 0.5 kg of water at 200 kPa and 150°C and compartment B has water at a state of 400 kPa with a quality of 50% and a volume of 0.1 m3. The valve is opened and heat is transferred so that the water comes to a uniform state with a total volume of 1.006 m3. Find the total mass of water and the total initial volume. Find the work and the heat transfer in the process.