• Home
  • Raw
  • Download

Lines Matching refs:j

60   int i, j;  in init_matrix()  local
63 for (j = 0; j < rows; j++) in init_matrix()
65 a[i * cols + j] = 1.0 / (1 + abs(i-j)); in init_matrix()
74 int i, j; in print_matrix() local
78 for (j = 0; j < cols; j++) in print_matrix()
80 printf("%g ", a[i * cols + j]); in print_matrix()
102 int i, j; in copy_matrix() local
111 for (j = from_col_first; j < from_col_last; j++) in copy_matrix()
113 assert(j < from_cols); in copy_matrix()
114 assert(j - from_col_first + to_col_first < to_cols); in copy_matrix()
116 + (j - from_col_first + to_col_first)] in copy_matrix()
117 = from[i * from_cols + j]; in copy_matrix()
130 int i, j, k; in multiply_matrices() local
138 for (j = 0; j < cols2; j++) in multiply_matrices()
140 prod[i * cols2 + j] = 0; in multiply_matrices()
143 prod[i * cols2 + j] += a1[i * cols1 + k] * a2[k * cols2 + j]; in multiply_matrices()
160 int i, j, k; in gj() local
166 j = i; in gj()
169 if (a[k * cols + i] > a[j * cols + i]) in gj()
171 j = k; in gj()
174 if (j != i) in gj()
179 a[i * cols + k] = a[j * cols + k]; in gj()
180 a[j * cols + k] = t; in gj()
197 # pragma omp parallel for private(j) in gj()
198 for (j = 0; j < rows; j++) in gj()
200 if (i != j) in gj()
202 const elem_t factor = a[j * cols + i]; in gj()
205 a[j * cols + k] -= a[i * cols + k] * factor; in gj()
212 # pragma omp parallel for private(j, k) in gj()
213 for (j = 0; j < rows; j++) in gj()
215 if (i != j) in gj()
217 const elem_t factor = a[j * cols + i]; in gj()
220 a[j * cols + k] -= a[i * cols + k] * factor; in gj()
231 int i, j; in invert_matrix() local
236 for (j = 0; j < n; j++) in invert_matrix()
237 tmp[i * 2 * n + n + j] = (i == j); in invert_matrix()
249 int i, j; in identity_error() local
253 for (j = 0; j < n; j++) in identity_error()
255 const elem_t d = a[i * n + j] - (i == j); in identity_error()