The train station is 2 minutes walk from the apartment. There are 3 different trains to Barcelona, which take 1 hour 20, 1 hour 33 or 1 hour 6 minutes. For the fastest train you pay 20€ or so for a single ticket, double the price of the next fastest. The cheapest and slowest train costs 7€ something for a single ticket. There is quite a regular service and it's very comfortable. Get off at Sants or Passeig de Gracia depending on your destination.