21 #ifndef SELDON_FILE_MATRIX_SYMCOMPLEXSPARSE_INLINE_CXX
23 #include "Matrix_SymComplexSparse.hxx"
34 template <
class T,
class Prop,
class Storage,
class Allocator>
54 template <
class T,
class Prop,
class Storage,
class Allocator>
58 return real_nz_ + imag_nz_;
69 template <
class T,
class Prop,
class Storage,
class Allocator>
73 return real_nz_ + imag_nz_;
82 template <
class T,
class Prop,
class Storage,
class Allocator>
95 template <
class T,
class Prop,
class Storage,
class Allocator>
111 template <
class T,
class Prop,
class Storage,
class Allocator>
128 template <
class T,
class Prop,
class Storage,
class Allocator>
140 template <
class T,
class Prop,
class Storage,
class Allocator>
144 return (this->m_ + 1);
152 template <
class T,
class Prop,
class Storage,
class Allocator>
156 return (this->m_ + 1);
172 template <
class T,
class Prop,
class Storage,
class Allocator>
192 template <
class T,
class Prop,
class Storage,
class Allocator>
212 template <
class T,
class Prop,
class Storage,
class Allocator>
232 template <
class T,
class Prop,
class Storage,
class Allocator>
244 template <
class T,
class Prop,
class Storage,
class Allocator>
245 inline typename Allocator::value_type*
256 template <
class T,
class Prop,
class Storage,
class Allocator>
257 inline typename Allocator::value_type*
277 template <
class T,
class Prop,
class Storage,
class Allocator>
282 return ValReal(i, j);
294 template <
class T,
class Prop,
class Storage,
class Allocator>
299 return ValImag(i, j);
311 template <
class T,
class Prop,
class Storage,
class Allocator>
317 if (real(val) != value_type(0))
318 GetReal(i, j) += real(val);
320 if (imag(val) != value_type(0))
321 GetImag(i, j) += imag(val);
327 template <
class T,
class Prop,
class Storage,
class Allocator>
332 throw Undefined(
"AddInteractionRow",
"Not implemented");
342 template <
class T,
class Prop,
class Storage,
class Allocator>
344 ::Set(
int i,
int j,
const entry_type& val)
346 GetReal(i, j) = real(val);
347 GetImag(i, j) = imag(val);
357 template <
class T,
class Prop,
class Storage,
class Allocator>
368 #ifdef SELDON_WITH_VIRTUAL
369 template <
class T,
class Prop,
class Storage,
class Allocator>
372 const typename ClassComplexType<T>::Treal& omega,
373 int nb_iter,
int stage_ssor)
const
376 x, r, omega, nb_iter, stage_ssor);
379 template <
class T,
class Prop,
class Storage,
class Allocator>
380 inline void Matrix_SymComplexSparse<T, Prop, Storage, Allocator>
381 ::ApplySor(
const SeldonTranspose& trans, Vector<Tcplx>& x,
const Vector<Tcplx>& r,
382 const typename ClassComplexType<T>::Treal& omega,
383 int nb_iter,
int stage_ssor)
const
386 static_cast<const Matrix<T, Prop, Storage, Allocator>&
>(*
this),
387 x, r, omega, nb_iter, stage_ssor);
390 template <
class T,
class Prop,
class Storage,
class Allocator>
391 inline void Matrix_SymComplexSparse<T, Prop, Storage, Allocator>
392 ::MltAddVector(
const Treal& alpha,
const Vector<Treal>& x,
393 const Treal& beta, Vector<Treal>& y)
const
395 cout <<
"Not defined for real numbers" << endl;
399 template <
class T,
class Prop,
class Storage,
class Allocator>
400 inline void Matrix_SymComplexSparse<T, Prop, Storage, Allocator>
401 ::MltAddVector(
const Tcplx& alpha,
const Vector<Tcplx>& x,
402 const Tcplx& beta, Vector<Tcplx>& y)
const
405 static_cast<const Matrix<T, Prop, Storage, Allocator>&
>(*
this),
409 template <
class T,
class Prop,
class Storage,
class Allocator>
410 inline void Matrix_SymComplexSparse<T, Prop, Storage, Allocator>
411 ::MltAddVector(
const Treal& alpha,
const SeldonTranspose& trans,
412 const Vector<Treal>& x,
413 const Treal& beta, Vector<Treal>& y)
const
415 cout <<
"Not defined for real numbers" << endl;
419 template <
class T,
class Prop,
class Storage,
class Allocator>
420 inline void Matrix_SymComplexSparse<T, Prop, Storage, Allocator>
421 ::MltAddVector(
const Tcplx& alpha,
const SeldonTranspose& trans,
422 const Vector<Tcplx>& x,
423 const Tcplx& beta, Vector<Tcplx>& y)
const
426 static_cast<const Matrix<T, Prop, Storage, Allocator>&
>(*
this),
430 template <
class T,
class Prop,
class Storage,
class Allocator>
431 inline void Matrix_SymComplexSparse<T, Prop, Storage, Allocator>
432 ::MltVector(
const Vector<Treal>& x, Vector<Treal>& y)
const
434 cout <<
"Not defined for real numbers" << endl;
438 template <
class T,
class Prop,
class Storage,
class Allocator>
439 inline void Matrix_SymComplexSparse<T, Prop, Storage, Allocator>
440 ::MltVector(
const Vector<Tcplx>& x, Vector<Tcplx>& y)
const
442 Mlt(
static_cast<const Matrix<T, Prop, Storage, Allocator>&
>(*
this), x, y);
445 template <
class T,
class Prop,
class Storage,
class Allocator>
446 inline void Matrix_SymComplexSparse<T, Prop, Storage, Allocator>
447 ::MltVector(
const SeldonTranspose& trans,
448 const Vector<Treal>& x, Vector<Treal>& y)
const
450 cout <<
"Not defined for real numbers" << endl;
454 template <
class T,
class Prop,
class Storage,
class Allocator>
455 inline void Matrix_SymComplexSparse<T, Prop, Storage, Allocator>
456 ::MltVector(
const SeldonTranspose& trans,
457 const Vector<Tcplx>& x, Vector<Tcplx>& y)
const
460 static_cast<const Matrix<T, Prop, Storage, Allocator>&
>(*
this), x, y);
463 template <
class T,
class Prop,
class Storage,
class Allocator>
464 inline bool Matrix_SymComplexSparse<T, Prop, Storage, Allocator>
465 ::IsSymmetric()
const
485 template <
class T,
class Prop,
class Allocator>
497 template <
class T,
class Prop,
class Allocator>
518 template <
class T,
class Prop,
class Allocator>
inline
549 template <
class T,
class Prop,
class Allocator>
550 template <
class Storage0,
class Allocator0,
551 class Storage1,
class Allocator1,
552 class Storage2,
class Allocator2>
587 template <
class T,
class Prop,
class Allocator>
599 template <
class T,
class Prop,
class Allocator>
619 template <
class T,
class Prop,
class Allocator>
621 ::Matrix(
int i,
int j,
long real_nz,
long imag_nz):
649 template <
class T,
class Prop,
class Allocator>
650 template <
class Storage0,
class Allocator0,
651 class Storage1,
class Allocator1,
652 class Storage2,
class Allocator2>
674 #define SELDON_FILE_MATRIX_SYMCOMPLEXSPARSE_INLINE_CXX