#include #include #include #include #include #include "include.h" #include "run.h" /* This file calculates the overlap of the wavefunction for the longitudinal potential and glueball eigenstates. */ int MAIN(){ int i,vv,n; static struct sectors xy[2],lx,gx; clock_t t1; element beta; integer nval=5; doublereal *val,*vec=NULL,*lval=NULL,*lvec=NULL; partype part[NPMAX]; #define NOUT 100 /* Output file name length */ char out[NOUT]="decay.out",*pout; FILE *fp; #if HINDEX==1 /* have not implemented */ #elif HINDEX==2 int ht[HINDEX]={0,0},np=6,kt=26,cyclic=1,o=1,multi=8,multi2=9,nfig=8; element kmax=4.0,ll=0.0; int npg=6,gkt=36,cyclicg=1,go=1,gmulti=3; #if 0 /* test couplings */ element couplings[NPARAMS]={0.03, 1.0, 0.7,0.03,-0.005, 3.0,0.13,1.0,-2.0}; #elif 1 /* couplings used in first 3+1 paper hep-th/9810236 */ element rescale=8.099820052, couplings[NPARAMS]={0.0517766953,1,0.7584261311, -0.07623059914,-0.1458991891,8.889796764,0.1608104465, 1.657995607,-3.268403913}; #endif #endif #ifdef BABBAGE /* Routine to initialize Fortran on Babbage */ if(hf_fint((char*)NULL)) exit(1); #endif #if 1 /* Ask for output file name*/ printf("Output file name: "); fgets(out,NOUT,stdin); if((pout=strchr(out,'\n'))!=NULL)*pout='\0'; printf("%s\n",out); #endif if((fp = fopen(out,"w")) == NULL){ fprintf(stderr,__FILE__": Can't open file %s in structure.c, exiting\n",out); goto cleanup; } loop: printf("Input number of eigenvalues (0=exit): "); scanf("%li",&nval); if(nval==0)goto cleanup; /****** Input parameters for the basis *************/ #if 1 /* input parameters for basis (instead of defaults.) */ printf("Input ht[%i], p truncation, kt=2*K, " "cyclic, o, multiplet:\n",HINDEX); for(i=0;igkt?kt:gkt,couplings); if(x.type==TYPE_SOURCE){ maketenslist(ll,x.kt,kmax,beta); } else { fprintf(stderr,__FILE__": This is supposed to be the heavy potential\n"); goto cleanup; } printf(" in %f CPU seconds\n", (float)(clock()-t1)/(float) CLOCKS_PER_SEC); printf("Starting calculation of potential.\n"); t1=clock(); spectrum(xy,xy+1,&val,&vec,nval,couplings,nfig); printf("%f CPU seconds to calculate Hamiltonian and run Lanczos\n\n", (float)(clock()-t1)/(float) CLOCKS_PER_SEC); /* Copy the resuling eigenvalues and eigenvectors into lval and lvec */ for(vv=0; vvlocate; npi=x.np[i]; for(ist=0; istlength; ist++, temp+=npi) for(opi=0; opi<2; opi++) if(x.inner[i][ist]!=0){ for(j=0, k=0; j