function result = F_tau(s,tau) 
    [w, x] = ClenshawCurtis(s, 20, 128); 
    m=128;
    % Due to the exponential decay of the kernel, the integral on interval (s,20) is
    % already a good approximation for the integral on interval (s,inf).
    K=eye(2*m);
     
    for i = 1:2*m
        for j=1:2*m
            if i<=m && j<=m
                K(i,j)=w(i)^(1/2)*K_tau_11(x(i),x(j),tau)*w(j)^(1/2);
            end
            if i<=m && j>m
                K(i,j)=w(i)^(1/2)*K_tau_12(x(i),x(j-m),tau)*w(j-m)^(1/2);
            end
            if i>m && j<=m
                K(i,j)=w(i-m)^(1/2)*K_tau_21(x(i-m),x(j),tau)*w(j)^(1/2);
            end
            if i>m && j>m
                K(i,j)=w(i-m)^(1/2)*K_tau_22(x(i-m),x(j-m),tau)*w(j-m)^(1/2);
            end
        end
    end
    result = det(eye(2*m)-K);
    
end




