Update!
I think I did it successfully by the integration method :D
My answer to the original question about energy came out to be 3.21 x 108 J, whereas the textbook answer is 3.57 x 108 J. I think I'm getting decimal place errors since the numbers come out to be so big, or so I'd like to...