Main Page   Modules   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

SmithFormAdaptive Class Reference

#include <smith-form-adaptive.h>

List of all members.

Static Public Methods

template<class Matrix> void compute_local_long (std::vector< integer > &s, const Matrix &A, long p, long e)
template<class Matrix> void compute_local_big (std::vector< integer > &s, const Matrix &A, long p, long e)
template<class Matrix> void compute_local (std::vector< integer > &s, const Matrix &A, long p, long e)
template<class Matrix> void smithFormSmooth (std::vector< integer > &s, const Matrix &A, long r, const std::vector< long > &sev)
template<class Matrix> void smithFormRough (std::vector< integer > &s, const Matrix &A, integer m)
template<class Matrix> void smithFormVal (std::vector< integer > &s, const Matrix &A, long r, const std::vector< long > &sev)
template<class Matrix> void smithForm (std::vector< integer > &s, const Matrix &A)
 Smith form of a dense matrix by adaptive algorithm.

template<class IRing> void smithForm (std::vector< integer > &s, const DenseMatrix< IRing > &A)

Static Public Attributes

const long prime [] = {2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97}
const int NPrime = 25


Member Function Documentation

void compute_local std::vector< integer > &    s,
const Matrix &    A,
long    p,
long    e
[static]
 

void compute_local_big std::vector< integer > &    s,
const Matrix &    A,
long    p,
long    e
[static]
 

Meet trouble to call ffpack routine Modular<double> F (p); Modular<double>::Element elt; int n = A. rowdim(); int m = A. coldim(); Modular<double>::Element* A_local = new Modular<double>::Element [n * m]; typename Matrix::ConstRawIndexedIterator rawi_p; typename Matrix::ConstRawIterator raw_p; Modular<double>::Element* A_local_p; for (A_local_p = A_local; A_local_p != A_local + (n*m); ++ A_local_p) F. init (*A_local_p, 0); integer tmp; for (rawi_p = A. rawIndexedBegin(), raw_p = A. rawBegin(), A_local_p = A_local; rawi_p != A. rawIndexedEnd(); ++ rawi_p, ++ raw_p, ++ A_local_p) { F. init (*A_local_p, *raw_p); A. field(). convert (tmp, *raw_p); F. init (elt, tmp); F. assign (*(A_local + (int(rawi_p. rowIndex()) * m + int(rawi_p. colIndex()))), elt); }

std::cout << "Initialize matrix done
"; for (int i = 0; i < n * m; ++ i) std::cout << *(A_local + i) << '\t'; std::cout << "\nbegin to call ffpack:
";

unsigned int rank = FFPACK::Rank (F, n, m, A_local, m); std::cout << "Call of ffpack is done
"; delete[] A_local;

void compute_local_long std::vector< integer > &    s,
const Matrix &    A,
long    p,
long    e
[static]
 

void smithForm std::vector< integer > &    s,
const DenseMatrix< IRing > &    A
[static]
 

Specialization for dense case

void smithForm std::vector< integer > &    s,
const Matrix &    A
[static]
 

Smith form of a dense matrix by adaptive algorithm.

Compute the largest invariant factor, then, based on that, compute the rough and smooth part, separately. Should work with SparseMatrix and DenseMatrix

void smithFormRough std::vector< integer > &    s,
const Matrix &    A,
integer    m
[static]
 

void smithFormSmooth std::vector< integer > &    s,
const Matrix &    A,
long    r,
const std::vector< long > &    sev
[static]
 

void smithFormVal std::vector< integer > &    s,
const Matrix &    A,
long    r,
const std::vector< long > &    sev
[static]
 


Member Data Documentation

const int NPrime = 25 [static]
 

const long prime = {2, 3, 5, 7, 11, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59, 61, 67, 71, 73, 79, 83, 89, 97} [static]
 


Generated on Mon Jun 20 09:16:58 2005 for linbox by doxygen1.2.18