include iostream include math using namespace std int main double arra

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
#include <iostream>
#include <math.h>
using namespace std;
int main() {
double array[11][6], a;
cout << "Enter 'a':" << endl;
cin >> a;
cout << "f(x, y) = 1 / (1 + y^(a * x)); 0 <= x <= 10, 0 <= y <= 5" << endl;
for (int x = 0; x <= 10; ++x) {
for (int y = 0; y <= 5; ++y) {
array[x][y] = 1 / (1 + pow (y, (a * x)));
}
}
for (int x = 0; x <= 10; ++x) {
for (int y = 0; y <= 5; ++y) {
cout << "array[" << x << "][" << y << "] - " << array[x][y] << endl;
}
}
return 0;
}