thanks for your response, in my case I used the formulas figured in wertz text book and they are the same as those figured in the paper that you indicated, and also I got the same results as yours.
now, if it's possible, could you show me how can I compare this model with the online model ?
thanks for your help and your time
I got the formulas for P(n,m) and dP(n,m) by looking at the direct Fortran translation of the IGRF done by Charles Rino (#28874, listed as inspiration for this file) and figuring out what that program was doing. The formulas in the paper here (http://hanspeterschaub.info/Papers/UnderGradStudents/MagneticField.pdf) are different, and I am not sure why.