int main() {
int i = 0;
int n;
double U[n], A[n] , B[n], C[n];
U[0] = 2;
U[1] = M_PI;
A[0] = 1, B[0] = 4, C[0] = 0;
double x[n];
x[n] = 100;
double h = 1 / n;
n = x[n] / h;
double k;
double fu[n];
fu[0] = 4 / sin(2*k);
while (i < n) {
U[n] = 1 / (A[n] + (B[n]*h) / 2) * ((h*h) * fu[n] - U[n-1] * (C[n]*(h*h) - 2*A[n])
- U[n-2]*(A[n] - U[n-2] * (A[n] - (B[n]*h)/ 2)));
i++;
}
std::cout << U[3] ;
return 0;
}