44 subroutine calctn(TN,TNuv,MomInv,masses2,N,rmax,id,TNerr,TNerr2)
46 integer,
intent(in) :: N,rmax,id
47 double complex,
intent(in) :: MomInv(BinomTable(2,N)), masses2(0:N-1)
48 double complex,
intent(inout) :: TN(NCoefs(rmax,N))
49 double complex,
intent(inout) :: TNuv(NCoefs(rmax,N))
50 double precision,
intent(out) :: TNerr(0:rmax),TNerr2(0:rmax)
51 double complex,
allocatable :: TNaux(:,:,:),TNuvaux(:,:,:)
52 double complex :: B(0:rmax,0:rmax), Buv(0:rmax,0:rmax)
53 double complex :: C(0:rmax,0:rmax,0:rmax), Cuv(0:rmax,0:rmax,0:rmax)
54 double complex :: D(0:rmax,0:rmax,0:rmax,0:rmax), Duv(0:rmax,0:rmax,0:rmax,0:rmax)
55 double complex :: E(0:rmax/2,0:rmax,0:rmax,0:rmax,0:rmax)
56 double complex :: Euv(0:rmax/2,0:rmax,0:rmax,0:rmax,0:rmax)
57 double complex :: x(BinomTable(2,N)+N)
58 double complex,
allocatable :: fct(:)
59 integer :: r,n0,n1,n2,n3,n4,i,rank,bino,bino_m2,cnt
60 logical :: nocalc,wrica
66 call calca(tn,tnuv,masses2(0),rmax,tnerr)
71 call calcb(b,buv,mominv(1),masses2(0),masses2(1),rmax,id,tnerr)
85 tnuv(cnt) = buv(n0,n1)
93 call calcc(c,cuv,mominv(1),mominv(2),mominv(3), &
94 masses2(0),masses2(1),masses2(2),rmax,id,tnerr,tnerr2)
101 tn(cnt) = c(n0,n1,n2)
108 cnt = ncoefs(r-1,3)+1
112 tnuv(cnt) = cuv(n0,n1,n2)
126 call calcd(d,duv,mominv(1),mominv(2),mominv(3),mominv(4),mominv(5),mominv(6), &
127 masses2(0),masses2(1),masses2(2),masses2(3),rmax,id,tnerr,tnerr2)
135 tn(cnt) = d(n0,n1,n2,n3)
143 cnt = ncoefs(r-1,4)+1
148 tnuv(cnt) = duv(n0,n1,n2,n3)
161 call calce(e,euv,mominv(1),mominv(2),mominv(3),mominv(4),mominv(5), &
162 mominv(6),mominv(7),mominv(8),mominv(9),mominv(10), &
163 masses2(0),masses2(1),masses2(2),masses2(3),masses2(4) &
164 ,rmax,id,tnerr,tnerr2)
171 do n3=r-2*n0-n1-n2,0,-1
173 tn(cnt) = e(n0,n1,n2,n3,n4)
182 cnt = ncoefs(r-1,5)+1
186 do n3=r-2*n0-n1-n2,0,-1
188 tnuv(cnt) = euv(n0,n1,n2,n3,n4)
198 allocate(tnaux(binomtable(rmax,n+rmax-2),0:rmax/2,0:rmax))
199 allocate(tnuvaux(binomtable(rmax,n+rmax-2),0:rmax/2,0:rmax))
200 call calctnint(tnaux,tnuvaux,mominv,masses2,n,rmax,id,tnerr,tnerr2)
205 do i=1,binomtable(r-2*n0,n+r-2*n0-2)
206 tn(cnt) = tnaux(i,n0,r)
213 cnt = ncoefs(r-1,n)+1
215 do i=1,binomtable(r-2*n0,n+r-2*n0-2)
216 tnuv(cnt) = tnuvaux(i,n0,r)
237 recursive subroutine calctnint(TN,TNuv,MomInv,masses2,N,rmax,id,TNerr,TNerr2)
239 integer,
intent(in) :: n,rmax,id
240 double complex,
intent(in) :: mominv(binomtable(2,n)), masses2(0:n-1)
241 double complex,
intent(inout) :: tn(binomtable(rmax,n+rmax-2),0:rmax/2,0:rmax)
242 double complex,
intent(inout) :: tnuv(binomtable(rmax,n+rmax-2),0:rmax/2,0:rmax)
243 double precision,
intent(out) :: tnerr(0:rmax),tnerr2(0:rmax)
244 double complex,
allocatable :: tnaux(:,:,:), tnuvaux(:,:,:)
245 double complex :: e(0:rmax/2,0:rmax,0:rmax,0:rmax,0:rmax)
246 double complex :: euv(0:rmax/2,0:rmax,0:rmax,0:rmax,0:rmax)
247 double precision,
allocatable :: tnerraux(:),tnerr2aux(:)
248 double complex :: x(binomtable(2,n)+n)
249 double complex,
allocatable :: fct(:)
250 integer :: r,n0,n1,n2,n3,n4,i,rank,bino,bino_m2,cnt
251 logical :: nocalc,wrica,noten
256 call calce(e,euv,mominv(1),mominv(2),mominv(3),mominv(4),mominv(5), &
257 mominv(6),mominv(7),mominv(8),mominv(9),mominv(10), &
258 masses2(0),masses2(1),masses2(2),masses2(3),masses2(4),rmax,id,tnerr,tnerr2)
265 do n3=r-2*n0-n1-n2,0,-1
267 tn(cnt,n0,r) = e(n0,n1,n2,n3,n4)
279 do n3=r-2*n0-n1-n2,0,-1
281 tnuv(cnt,n0,r) = euv(n0,n1,n2,n3,n4)
291 if ((use_cache_system).and.(tencache.gt.n))
then
292 if ((ncache.gt.0).and.(ncache.le.ncache_max))
then
293 bino = binomtable(2,n)
295 x(bino+1:bino+n) = masses2
298 if(rmax.ge.2*n-4)
then
299 allocate(fct(ncoefs(rmax,n)+ncoefs(rmax-2*n+4,n)+2*(rmax+1)))
300 call readcache(fct,ncoefs(rmax,n)+ncoefs(rmax-2*n+4,n)+2*(rmax+1),x,bino+n,1,id,n,rank,nocalc,wrica)
302 allocate(fct(ncoefs(rmax,n)+2*(rmax+1)))
303 call readcache(fct,ncoefs(rmax,n)+2*(rmax+1),x,bino+n,1,id,n,rank,nocalc,wrica)
310 do i=1,binomtable(r-2*n0,n+r-2*n0-2)
312 tn(i,n0,r) = fct(cnt)
316 do i=1,binomtable(r-2*n0,n+r-2*n0-2)
318 tnuv(i,n0,r) = fct(cnt)
322 tnerr(r) = real(fct(cnt))
324 tnerr2(r) = real(fct(cnt))
330 if(rank.eq.rmax)
then
332 call calctnred(tn,tnuv,mominv,masses2,n,rank,id,tnerr,tnerr2)
338 do i=1,binomtable(r-2*n0,n+r-2*n0-2)
341 fct(cnt) = tn(i,n0,r)
346 do i=1,binomtable(r-2*n0,n+r-2*n0-2)
349 fct(cnt) = tnuv(i,n0,r)
359 if(rank.ge.2*n-4)
then
360 call writecache(fct,ncoefs(rank,n)+ncoefs(rank-2*n+4,n)+2*(rank+1),id,n,rank)
362 call writecache(fct,ncoefs(rank,n)+2*(rank+1),id,n,rank)
371 allocate(tnaux(binomtable(rank,n+rank-2),0:rank/2,0:rank))
372 allocate(tnuvaux(binomtable(rank,n+rank-2),0:rank/2,0:rank))
373 allocate(tnerraux(0:rank))
374 allocate(tnerr2aux(0:rank))
376 call calctnred(tnaux,tnuvaux,mominv,masses2,n,rank,id,tnerraux,tnerr2aux)
381 if(rank.ge.2*n-4)
then
382 allocate(fct(ncoefs(rank,n)+ncoefs(rank-2*n+4,n)+2*(rank+1)))
384 allocate(fct(ncoefs(rank,n)+2*(rank+1)))
388 do i=1,binomtable(r-2*n0,n+r-2*n0-2)
391 fct(cnt) = tnaux(i,n0,r)
396 do i=1,binomtable(r-2*n0,n+r-2*n0-2)
399 fct(cnt) = tnuvaux(i,n0,r)
404 fct(cnt) = tnerraux(r)
406 fct(cnt) = tnerr2aux(r)
409 if(rank.ge.2*n-4)
then
410 call writecache(fct,ncoefs(rank,n)+ncoefs(rank-2*n+4,n)+2*(rank+1),id,n,rank)
412 call writecache(fct,ncoefs(rank,n)+2*(rank+1),id,n,rank)
417 tn = tnaux(1:binomtable(rmax,n+rmax-2),0:rmax/2,0:rmax)
418 tnuv = tnuvaux(1:binomtable(rmax,n+rmax-2),0:rmax/2,0:rmax)
419 tnerr = tnerraux(0:rmax)
420 tnerr2 = tnerr2aux(0:rmax)
427 call calctnred(tn,tnuv,mominv,masses2,n,rmax,id,tnerr,tnerr2)
441 recursive subroutine calctnred(TN,TNuv,MomInv,masses2,N,rmax,id,TNerr,TNerr2)
443 integer,
intent(in) :: n,rmax,id
444 double complex,
intent(in) :: mominv(binomtable(2,n)), masses2(0:n-1)
445 double precision,
intent(out) :: tnerr(0:rmax),tnerr2(0:rmax)
446 double complex :: q10,q21,q32,q43,q54,q20,q31,q42,q53,q50,q30,q41,q52,q40,q51
447 double complex :: mm02,mm12,mm22,mm32,mm42,mm52
448 double complex :: mx(0:5,0:5), mxinv(0:5,0:5),mx0k(5,5),mx0kinv(5,5),ff(n-1)
449 double complex :: det,newdet,tnaux,mxinvs,mx0kinvs(5)
450 double complex :: zmx0kinv(5,5),z(5,5),zmx0kinvs(5)
451 double precision :: maxz,maxzmx0kinv(5),maxzmx0kinvs
452 double complex,
intent(inout) :: tn(binomtable(rmax,n+rmax-2),0:rmax/2,0:rmax)
453 double complex,
intent(inout) :: tnuv(binomtable(rmax,n+rmax-2),0:rmax/2,0:rmax)
454 double complex,
allocatable :: tnm1_0(:,:,:), tnm1uv_0(:,:,:), tnm1_i(:,:,:,:)
455 double complex,
allocatable :: tnm1_0aux(:,:,:), tnm1uv_0aux(:,:,:), tnm1uv_i(:,:,:,:)
456 double complex :: s(5), elimminf2_coli,chdet,gram(1:5,1:5),gramdet
457 double precision :: tnm1err(0:5,0:rmax),tnm1err2(0:5,0:rmax)
458 integer :: r,n0,n1,n2,n3,n4,n5,n6,k,i,j,m,nid(0:5),r0,bin,kbest,nm1,inds(n-1)
459 integer :: bino,bino_0,bino_i,bino_m1,bino_m2,cnt,iaux,rmax_m1,shift,cind,rbcd
460 integer :: mia1,mia2,mia3
461 logical :: errorwriteflag
462 character(len=*),
parameter :: fmt10 =
"(A18,'(',d25.18,' , ',d25.18,' )')"
465 character(len=*),
parameter :: fmt999 =
"(' gm(',i1,',',i1,') = ',d23.16,' , ',d23.16)"
474 rmax_m1 = max(rmax-1,0)
475 bino_0 = binomtable(rmax_m1,n+rmax_m1-2)
476 bino_i = binomtable(rmax_m1,nm1+rmax_m1-2)
477 allocate(tnm1_0(bino_0,0:rmax_m1/2,0:rmax_m1))
478 allocate(tnm1_0aux(bino_i,0:rmax_m1/2,0:rmax_m1))
479 allocate(tnm1_i(bino_i,0:rmax_m1/2,0:rmax_m1,5))
480 allocate(tnm1uv_0(bino_0,0:rmax_m1/2,0:rmax_m1))
481 allocate(tnm1uv_0aux(bino_i,0:rmax_m1/2,0:rmax_m1))
482 allocate(tnm1uv_i(bino_i,0:rmax_m1/2,0:rmax_m1,5))
488 if (mod(id/bin,2).eq.0)
then
496 nm1,rmax_m1,nid(0),tnerr=tnm1err(0,0:rmax_m1), &
497 tnerr2=tnm1err2(0,0:rmax_m1))
499 call calctnint(tnm1_i(:,:,:,k),tnm1uv_i(:,:,:,k),
submominv(n,k,mominv), &
500 submasses(n,k,masses2),nm1,rmax_m1,nid(k), &
501 tnerr=tnm1err(k,0:rmax_m1),tnerr2=tnm1err2(k,0:rmax_m1))
506 tnm1_0(1,n0,2*n0) = tnm1_0aux(1,n0,2*n0)
508 mia1 = binomtable(r-1,n+r-3)+1
509 mia2 = binomtable(r,n+r-3)
510 mia3 = binomtable(r,n+r-2)
511 tnm1_0(mia1:mia3,n0,r+2*n0) = tnm1_0aux(1:mia2,n0,r+2*n0)
516 do i=binomtable(r-2*n0-1,n+r-2*n0-3),1,-1
517 tnm1_0(i,n0,r) = -tnm1_0(i,n0,r-1)
519 tnm1_0(i,n0,r) = tnm1_0(i,n0,r) &
520 - tnm1_0(addtocind(j,i,r-2*n0-1,n-1),n0,r)
526 tnm1uv_0(1,n0,2*n0) = tnm1uv_0aux(1,n0,2*n0)
528 mia1 = binomtable(r-1,n+r-3)+1
529 mia2 = binomtable(r,n+r-3)
530 mia3 = binomtable(r,n+r-2)
531 tnm1uv_0(mia1:mia3,n0,r+2*n0) = tnm1uv_0aux(1:mia2,n0,r+2*n0)
536 do i=binomtable(r-2*n0-1,n+r-2*n0-3),1,-1
537 tnm1uv_0(i,n0,r) = -tnm1uv_0(i,n0,r-1)
539 tnm1uv_0(i,n0,r) = tnm1uv_0(i,n0,r) &
540 - tnm1uv_0(addtocind(j,i,r-2*n0-1,n-1),n0,r)
548 mm02 = elimminf2_coli(masses2(0))
549 mm12 = elimminf2_coli(masses2(1))
550 mm22 = elimminf2_coli(masses2(2))
551 mm32 = elimminf2_coli(masses2(3))
552 mm42 = elimminf2_coli(masses2(4))
553 mm52 = elimminf2_coli(masses2(5))
554 q10 = elimminf2_coli(mominv(1))
555 q21 = elimminf2_coli(mominv(2))
556 q32 = elimminf2_coli(mominv(3))
557 q43 = elimminf2_coli(mominv(4))
558 q54 = elimminf2_coli(mominv(5))
560 q50 = elimminf2_coli(mominv((n-6)*n+6))
562 q50 = elimminf2_coli(mominv(4*n+1))
564 q20 = elimminf2_coli(mominv(n+1))
565 q31 = elimminf2_coli(mominv(n+2))
566 q42 = elimminf2_coli(mominv(n+3))
567 q53 = elimminf2_coli(mominv(n+4))
569 q40 = elimminf2_coli(mominv((n-5)*n+5))
570 q51 = elimminf2_coli(mominv((n-5)*n+6))
572 q40 = elimminf2_coli(mominv(3*n+1))
573 q51 = elimminf2_coli(mominv(3*n+2))
575 q30 = elimminf2_coli(mominv(2*n+1))
576 q41 = elimminf2_coli(mominv(2*n+2))
577 q52 = elimminf2_coli(mominv(2*n+3))
591 ff(i) = elimminf2_coli(mominv(cnt)) + mm02 &
592 - elimminf2_coli(masses2(i))
597 mx(1,0) = q10 - mm12 + mm02
598 mx(2,0) = q20 - mm22 + mm02
599 mx(3,0) = q30 - mm32 + mm02
600 mx(4,0) = q40 - mm42 + mm02
601 mx(5,0) = q50 - mm52 + mm02
604 mx(2,1) = q10+q20-q21
605 mx(3,1) = q10+q30-q31
606 mx(4,1) = q10+q40-q41
607 mx(5,1) = q10+q50-q51
611 mx(3,2) = q20+q30-q32
612 mx(4,2) = q20+q40-q42
613 mx(5,2) = q20+q50-q52
618 mx(4,3) = q30+q40-q43
619 mx(5,3) = q30+q50-q53
625 mx(5,4) = q40+q50-q54
633 call chinv(6,mx,mxinv)
638 mx0k(i,j) = mx(i,j-1)
646 write(*,*)
'det',5,det
654 newdet = chdet(5,mx0k)
655 if (abs(newdet).gt.abs(det))
then
658 write(*,*)
'det',j-1,newdet
667 write(*,*)
'kbest',kbest
675 mx0k(i,kbest) = mx(i,0)
678 call chinv(5,mx0k,mx0kinv)
680 mx0kinv(kbest,i) = 0d0
683 mxinvs = sum(mxinv(0:5,0))
685 mx0kinvs(i) = sum(mx0kinv(i,1:5))
689 z(1:5,1:5) = mx(1:5,1:5)
691 zmx0kinv = matmul(z,mx0kinv)
694 maxzmx0kinv(i) = maxval(abs(zmx0kinv(1:5,i)))
695 zmx0kinvs(i) = sum(zmx0kinv(i,1:5))
698 maxzmx0kinvs = maxval(abs(zmx0kinvs(1:5)))
700 maxz = maxval(abs(z))
709 do cind=1,binomtable(r-2*n0,n+r-2*n0-2)
711 tnuv(cind,n0,r) = tnm1uv_0(cind,n0-1,r-2) + 2*mm02*tnuv(cind,n0-1,r-2)
713 tnuv(cind,n0,r) = tnuv(cind,n0,r) &
714 + ff(i)*tnuv(addtocind(i,cind,r-2*n0,n-1),n0-1,r-1)
716 tnuv(cind,n0,r) = tnuv(cind,n0,r)/(2*(r+3-n))
724 tn(1,0,0) = -mxinv(0,0)*tnm1_0(1,0,0)
726 tn(1,0,0) = tn(1,0,0) &
727 + mxinv(k,0)*(tnm1_i(1,0,0,k)-tnm1_0(1,0,0))
731 tnerr(0) = max(abs(mxinvs)*tnm1err(0,0), &
732 abs(mxinv(1,0))*tnm1err(1,0) , &
733 abs(mxinv(2,0))*tnm1err(2,0) , &
734 abs(mxinv(3,0))*tnm1err(3,0) , &
735 abs(mxinv(4,0))*tnm1err(4,0) , &
736 abs(mxinv(5,0))*tnm1err(5,0) )
738 tnerr2(0) = max(abs(mxinvs)*tnm1err2(0,0), &
739 abs(mxinv(1,0))*tnm1err2(1,0) , &
740 abs(mxinv(2,0))*tnm1err2(2,0) , &
741 abs(mxinv(3,0))*tnm1err2(3,0) , &
742 abs(mxinv(4,0))*tnm1err2(4,0) , &
743 abs(mxinv(5,0))*tnm1err2(5,0) )
745 if (rmax.eq.0)
return
750 do n0=0,max((r-n+6)/2,0)
751 bino_m1 = binomtable(r-2*n0,n+r-2*n0-2)
753 inds = calccindarr(nm1,r-2*n0,i)
756 s(m) = -tnm1_0(i,n0,r)
760 write(*,*)
'Tnred s(m)',s
763 if (inds(1).eq.0)
then
764 s(1) = s(1) + tnm1_i(dropcind(1,i,r-2*n0,nm1),n0,r,1)
766 if (inds(2).eq.0)
then
767 s(2) = s(2) + tnm1_i(dropcind(2,i,r-2*n0,nm1),n0,r,2)
769 if (inds(3).eq.0)
then
770 s(3) = s(3) + tnm1_i(dropcind(3,i,r-2*n0,nm1),n0,r,3)
772 if (inds(4).eq.0)
then
773 s(4) = s(4) + tnm1_i(dropcind(4,i,r-2*n0,nm1),n0,r,4)
775 if (inds(5).eq.0)
then
776 s(5) = s(5) + tnm1_i(dropcind(5,i,r-2*n0,nm1),n0,r,5)
780 write(*,*)
'Tnred s(m)',s
784 tnaux = mx0kinv(k,1)*s(1)+mx0kinv(k,2)*s(2) &
785 + mx0kinv(k,3)*s(3)+mx0kinv(k,4)*s(4)+mx0kinv(k,5)*s(5)
786 iaux = addtocind(k,i,r,n-1)
787 tn(iaux,n0,r+1) = tn(iaux,n0,r+1) + (inds(k)+1)*tnaux/(r+1)
789 write(*,*)
'Tnred comb',k,mx0kinv(k,1)*s(1),mx0kinv(k,2)*s(2) &
790 , mx0kinv(k,3)*s(3),mx0kinv(k,4)*s(4),mx0kinv(k,5)*s(5), tnaux
792 if(abs(tnaux).ne.0d0)
then
793 write(*,*)
'Tnred cancel', k, max(abs(mx0kinv(k,1)*s(1)),abs(mx0kinv(k,2)*s(2)) &
794 , abs(mx0kinv(k,3)*s(3)),abs(mx0kinv(k,4)*s(4)),abs(mx0kinv(k,5)*s(5))) &
806 if (r.le.rmax-1)
then
808 tnerr(r+1) = max( maxval(abs(mx0kinvs(1:5)))*tnm1err(0,r), &
809 maxval(abs(mx0kinv(1:5,1)))*tnm1err(1,r) , &
810 maxval(abs(mx0kinv(1:5,2)))*tnm1err(2,r) , &
811 maxval(abs(mx0kinv(1:5,3)))*tnm1err(3,r) , &
812 maxval(abs(mx0kinv(1:5,4)))*tnm1err(4,r) , &
813 maxval(abs(mx0kinv(1:5,5)))*tnm1err(5,r) )
815 tnerr2(r+1) = max( abs(maxzmx0kinvs)*tnm1err2(0,r), &
816 abs(maxzmx0kinv(1))*tnm1err2(1,r) , &
817 abs(maxzmx0kinv(2))*tnm1err2(2,r) , &
818 abs(maxzmx0kinv(3))*tnm1err2(3,r) , &
819 abs(maxzmx0kinv(4))*tnm1err2(4,r) , &
820 abs(maxzmx0kinv(5))*tnm1err2(5,r) )/maxz
823 if (mode_coli.lt.1)
then
826 gramdet = chdet(5,gram)
832 write(*,fmt999) i,j,gram(i,j)
835 write(*,*)
'TNred relGramdet=',gramdet/det
838 if (max(abs(tn(1,0,0)),maxval(abs(tn(1:6,0,1))))*abs(gramdet/det).gt. &
841 tnerr(r+1)= max(tnerr(r+1), &
842 max(abs(tn(1,0,0)),maxval(abs(tn(1:6,0,1))))*abs(gramdet/det) )
843 tnerr2(r+1)= max(tnerr2(r+1), &
844 max(abs(tn(1,0,0)),maxval(abs(tn(1:6,0,1))))*abs(gramdet/det) )
846 if (abs(gramdet/det).gt.reqacc_coli)
then
847 call seterrflag_coli(-6)
848 call errout_coli(
'CalcTNred', &
849 'input momenta inconsistent! (not 4-dimensional)', &
851 if (errorwriteflag)
then
852 write(nerrout_coli,fmt10)
' CalcTNred: q10 = ',q10
853 write(nerrout_coli,fmt10)
' CalcTNred: q21 = ',q21
854 write(nerrout_coli,fmt10)
' CalcTNred: q32 = ',q32
855 write(nerrout_coli,fmt10)
' CalcTNred: q43 = ',q43
856 write(nerrout_coli,fmt10)
' CalcTNred: q54 = ',q54
857 write(nerrout_coli,fmt10)
' CalcTNred: q50 = ',q50
858 write(nerrout_coli,fmt10)
' CalcTNred: q20 = ',q10
859 write(nerrout_coli,fmt10)
' CalcTNred: q31 = ',q31
860 write(nerrout_coli,fmt10)
' CalcTNred: q42 = ',q42
861 write(nerrout_coli,fmt10)
' CalcTNred: q53 = ',q53
862 write(nerrout_coli,fmt10)
' CalcTNred: q40 = ',q40
863 write(nerrout_coli,fmt10)
' CalcTNred: q51 = ',q51
864 write(nerrout_coli,fmt10)
' CalcTNred: q30 = ',q30
865 write(nerrout_coli,fmt10)
' CalcTNred: q41 = ',q41
866 write(nerrout_coli,fmt10)
' CalcTNred: q52 = ',q52
867 write(nerrout_coli,fmt10)
' CalcTNred: mm02 = ',mm02
868 write(nerrout_coli,fmt10)
' CalcTNred: mm12 = ',mm12
869 write(nerrout_coli,fmt10)
' CalcTNred: mm22 = ',mm22
870 write(nerrout_coli,fmt10)
' CalcTNred: mm32 = ',mm32
871 write(nerrout_coli,fmt10)
' CalcTNred: mm42 = ',mm42
872 write(nerrout_coli,fmt10)
' CalcTNred: mm52 = ',mm52
873 write(nerrout_coli,fmt10)
' CalcTNred: gram = ',gramdet/det
884 write(*,*)
'Tnred mn err',tnm1err(1:5,r)
885 write(*,*)
'Tnred coef err', (maxval(abs(mx0kinv(1:5,k))),k=1,5)
886 write(*,*)
'Tnred err',tnerr(r+1)
906 double complex :: masses(0:n-1),
submasses(0:n-2)
908 if ((k.gt.n-1).or.(k.lt.0))
then
909 write(nerrout_coli,*)
'SubMasses:'
910 write(nerrout_coli,*)
'inkonsistent argument k', k
911 write(nerrout_coli,*) 0,
'<= k <=', n-1,
'required!'
937 double complex :: momvec(0:3,n-1),
submomvec(0:3,n-2)
939 if ((k.gt.n-1).or.(k.lt.0))
then
940 write(nerrout_coli,*)
'SubMomVec:'
941 write(nerrout_coli,*)
'inkonsistent argument k', k
942 write(nerrout_coli,*) 0,
'<= k <=', n-1,
'required!'
948 submomvec(0:3,i) = momvec(0:3,i+1)-momvec(0:3,1)
978 integer,
intent(in) :: n,k
979 integer :: i,cnt,moms,limit
980 double complex :: mominv(binomtable(2,n)),
submominv(binomtable(2,n-1))
983 if ((k.gt.n-1).or.(k.lt.0))
then
984 write(nerrout_coli,*)
'SubMomInv:'
985 write(nerrout_coli,*)
'inkonsistent argument k', k
986 write(nerrout_coli,*) 0,
'<= k <=', n-1,
'required!'
996 if ((k.ge.i).and.(i.ge.k-moms+1).or.(n+k.ge.i).and.(i.ge.n+k-moms+1))
then
1007 if (mod(n,2).eq.1)
then
1009 if(k.le.(n-1)/2)
then
1016 if ((k.ge.i).and.(i.ge.k-moms+1).or.(n+k.ge.i).and.(i.ge.n+k-moms+1))
then
1017 submominv(cnt) = mominv(n*moms+i-(n-1)/2)
1030 if ((k.ge.i).and.(i.ge.k-moms+1).or.(n+k.ge.i).and.(i.ge.n+k-moms+1))
then