... doable, but it's a heck of a trip for a day escapade. On the one hand, a fast train to Perpignan -which is the first stop in France for the bullet train- is 90' but there are only four trains per day, on the other the cost, it'll be near 100€ for a return trip.
... questionable too. Perpignan is indeed a nice city, despite now being "in France" that region is located in former historical area of "Northern Catalonia" -google for it!- hence sharing lots of traditions and other stuff -for example, flag and local language: Catalan!- with the current nation of Catalonia, where Barcelona is the capital city. Still, I would question whether it's worth to spend a precious day out of your probably already short vacation to go there when you have sooooo many other stuff to see and do much closer to Barcelona, in Catalonia, and also "in" Barcelona itself. Also, if you're interested in traditions (festivals, etc), as said, both areas shared a common culture for centuries thus these are pretty similar in many ways. Just sayin'