Selfconsistent thomas fermi method for spherical nuclei