Absent other energy sources, like linear electric motors or kick wheels, the roller coaster gets all its energy from the chain that drags it up the initial hill. By the second hill, some energy has been lost to friction and there isn't enough to get over a hill that's higher than the first one.