Курсовая работа: Система обработки научных данных
cout<<" Enter the total no of data";
cin>>n;
for(int i=0;i<n;i++)
{ cout<<"X"<<i+1<<" ";
cin>>a[i];
cout<<"Y"<<i+1<<" ";
cin>>b[i];
}
clrscr();
for(i=0;i<n;i++)
{
z1 +=a[i];
z2 +=b[i];
}
mx = z1/n;
my = z2/n;
for( i=0;i<n;i++)
{
z3 += ((a[i]-mx)*(b[i]-my));
z4 += pow((a[i]-mx),2);
z5 += pow((b[i]-my),2);
}
cxy = z3/n;
vx = z4/n;
vy = z5/n;
byx = cxy/vx;
bxy = cxy/vy;
cout<<setw(5)<<"X"<<setw(5)<<" Y"<<endl;
for(i=0;i<n;i++)