106 for(
int i=0;i<size;i++){y2.push_back(0.0);}
119 u[0]=(3.0/(vx[1]-vx[0]))*((vy[1]-vy[0])/(vx[1]-vx[0])-yp1);
121 for (i=1;i<
n-1;i++) {
122 sig=(vx[i]-vx[i-1])/(vx[i+1]-vx[i-1]);
124 double yy2=(sig-1.0)/p;
126 u[i]=(vy[i+1]-vy[i])/(vx[i+1]-vx[i]) - (vy[i]-vy[i-1])/(vx[i]-vx[i-1]);
127 u[i]=(6.0*u[i]/(vx[i+1]-vx[i-1])-sig*u[i-1])/p;
133 un=(3.0/(vx[
n-1]-vx[
n-2]))*(ypn-(vy[
n-1]-vy[
n-2])/(vx[
n-1]-vx[
n-2]));
135 y2[
n-1]=(un-qn*u[
n-2])/(qn*y2[
n-2]+1.0);
137 y2[k]=y2[k]*y2[k+1]+u[k];