Xrf fit

I will add test file. I used to put test file and main code together, a bit lazy way.