Libby was at the Santa Rosa Mental Hospital with Hurley. It's pretty well established that leaving the island can drive some people crazy so that might explain why she was there. Third, she told Desmond that the sailboat belonged to her late husband and I believe she mentioned something about planning to cruise around the world-- indicating that she had a husband who was wealthy enough and adventurous enough to cruise around the world. The theory fits known facts in a lot of ways. I know that I'm not the first person to believe that Libby had been on the island before the crash of Oceanic 815... It's possible that she was on the flight for the same reason that Jack in 2008 was using his free pass to fly so often -- she wanted to get back to the island.