function [ab,Mcap,kount]=sr_gengeg(nofdig,N)
%SR_GENGEG Recurrence coefficients for a generalized Gegenbauer 
%weight function.
%   [AB,MCAP,KOUNT]=SR_GENGEG(NOFDIG,N) uses a 2-component
%   discretization procedure to compute in DIG-digit arithmetic  
%   the first N recurrence coefficients for the weight function 
%   w(x)=|x|^A*(1-x^2)^B on [-1,1], A>-1, B>-1, and places them 
%   to NOFDIG digits into the Nx2 array AB. The variables DIG,
%   A, B are assumed to have been assigned, and declared global,
%   in the calling program. THe output variab;es MCAP, KOUNT are
%   inherited from the routine smcdis.m.

global mc mp iq idelta irout dig a b 
mc=2; mp=0; iq=1; idelta=2; irout=1; Mmax=500;
eps0=.5*10^(-nofdig);
[ab,Mcap,kount]=smcdis(dig,N,eps0,@quad_sgengeg,Mmax); Mcap
ab=vpa(ab,nofdig);
