subroutine SetFit(n, X) c*********************************************************************** c SetFit set up the fitting parameter array X() and number of c fitting parameters n, according to the fitting index array c Fidx() and potential parameters f0, mgb, alpha. c Note that if fidx(?)=0 then the parameter x(?) do not changed. c*********************************************************************** integer Fidx, n, i double precision f0, mgb, alpha, c1, c2, Mbare, rcbm double precision X(3) c bag.h Version 1.4 contains the CCDM parameters. first 3 independent common /bag/ rcbm,f0,mgb,alpha,c1,c2,Mbare(3),Fidx(3) do 10000 i = 1, 3 if ((Fidx(i) .ne. 0) .and. (Fidx(i) .ne. 1)) then write(8, *) 'bad fidx value' stop 'setfit' endif 10000 continue n = 0 if (Fidx(1) .eq. 1) then n = n + 1 X(n) = f0 endif if (Fidx(2) .eq. 1) then n = n + 1 X(n) = Mbare(1) endif if (Fidx(3) .eq. 1) then n = n + 1 X(n) = Mbare(2) endif c return end