c kspectrum (http://www.meso-star.com/en_Products.html) - This file is part of kspectrum c Copyright (C) 2008-2015 - Méso-Star - Vincent Eymet c c This file must be used under the terms of the CeCILL license. c This source file is licensed as described in the file COPYING, which c you should have received as part of this distribution. The terms c are also available at c http://www.cecill.info/licences/Licence_CeCILL_V2.1-en.txt c subroutine convert_epsm2ch(eps,epsch) implicit none integer strlen,out,i,lin,fz double precision eps,ceps character*1 zch,cch character*20 epsch 11 format(I1) 12 format(I2) 13 format(I3) write(zch,11) 0 epsch='' out=0 i=0 fz=0 ceps=eps do while ((out.eq.0).and.(i.lt.20)) call last_int(int(ceps),lin) write(cch,11) lin epsch=epsch(1:strlen(epsch))//cch(1:strlen(cch)) i=i+1 if (i.eq.1) then epsch=epsch(1:strlen(epsch))//'.' endif if (i.eq.1) then if (lin.eq.1) then fz=1 endif endif call is_integer(ceps,out) ceps=ceps*1.0D+1 enddo if (fz.eq.1) then epsch=epsch(1:strlen(epsch))//zch(1:strlen(zch)) endif c Debug c write(*,*) 'eps=',eps c write(*,*) 'epsch=',epsch(1:strlen(epsch)) c Debug return end