libflame
revision_anchor
|
Functions | |
void | bli_sinvertv (conj_t conj, int n, float *x, int incx) |
void | bli_dinvertv (conj_t conj, int n, double *x, int incx) |
void | bli_cinvertv (conj_t conj, int n, scomplex *x, int incx) |
void | bli_zinvertv (conj_t conj, int n, dcomplex *x, int incx) |
void bli_cinvertv | ( | conj_t | conj, |
int | n, | ||
scomplex * | x, | ||
int | incx | ||
) |
References bli_is_conj(), scomplex::imag, and scomplex::real.
Referenced by FLA_Invert().
{ float one = 1.0F; float temp; float conjsign; scomplex* chi; int i; if ( bli_is_conj( conj ) ) conjsign = one; else conjsign = -one; for ( i = 0; i < n; ++i ) { chi = x + i*incx; temp = one / ( chi->real * chi->real + chi->imag * chi->imag ); chi->real = chi->real * temp; chi->imag = chi->imag * conjsign * temp; } }
void bli_dinvertv | ( | conj_t | conj, |
int | n, | ||
double * | x, | ||
int | incx | ||
) |
Referenced by FLA_Invert().
{ double one = 1.0; double* chi; int i; for ( i = 0; i < n; ++i ) { chi = x + i*incx; *chi = one / *chi; } }
void bli_sinvertv | ( | conj_t | conj, |
int | n, | ||
float * | x, | ||
int | incx | ||
) |
Referenced by FLA_Invert().
{ float one = 1.0F; float* chi; int i; for ( i = 0; i < n; ++i ) { chi = x + i*incx; *chi = one / *chi; } }
void bli_zinvertv | ( | conj_t | conj, |
int | n, | ||
dcomplex * | x, | ||
int | incx | ||
) |
References bli_is_conj(), dcomplex::imag, and dcomplex::real.
Referenced by FLA_Invert().
{ double one = 1.0; double temp; double conjsign; dcomplex* chi; int i; if ( bli_is_conj( conj ) ) conjsign = one; else conjsign = -one; for ( i = 0; i < n; ++i ) { chi = x + i*incx; temp = one / ( chi->real * chi->real + chi->imag * chi->imag ); chi->real = chi->real * temp; chi->imag = chi->imag * conjsign * temp; } }