pro runsample ; Calcualte g9 & h9 using nmax=9 and 'mdigh_1968.asc' pgh_mbrsc,'MDI.1968.fits',9,g9,h9,ghmf='mdigh_1968.asc',/ifl pgh_wbrsc,'WSO.1968.asci',9,g9,h9,ghwf='wsogh_1968.asc',/ifl,/cali ; Asign phd,thd,lad,cth,sth,cmp based on jph=72, ith=30 pzgrid,72,30,phd,thd,lad,cth,sth,cmp,scs ; Calculate Br,Bt,Bp at a point located at r=2.0,lad(10),phd(20) ppb_hc,g9,h9,2.0,cth(10),sth(10),phd(20)*!DTOR,Br,Bt,Bp ; Calculate gca,hca and produce 'ghfcsss_1968.asc' based on g9,h9,nmax=9 pghfcsss_gaha,g9,h9,gca,hca,'ghfcsss_1968.asc',nmax=9 ; Calculate br,bt,bp at r=5,thd(10),phd(20) using g9,h9,gca,hca ppb_csss,g9,h9,gca,hca,5.,thd(10)*!DTOR,phd(20)*!DTOR,nmax=9,br,bt,bp ; Calculate bbr,bbt,bbp on a spherical surface of r=5 psb_csss,g9,h9,gca,hca,5,phd,thd,9,0.2,2.5,15.0,bbr,bbt,bbp end