47 template<
unsigned int Precision>
53 template<
unsigned int Precision>
60 template<
unsigned int Precision>
70 template<
unsigned int Precision>
77 template<
unsigned int Precision>
87 template<
unsigned int Precision>
94 template<
unsigned int Precision>
100 template<
unsigned int Precision>
107 template<
unsigned int Precision>
117 template<
unsigned int Precision>
124 template<
unsigned int Precision>
134 template<
unsigned int Precision>
193 template<
unsigned int Precision>
223 tauq.setbounds(0, n-1);
224 taup.setbounds(0, n-1);
228 tauq.setbounds(0,
m-1);
229 taup.setbounds(0,
m-1);
237 for(
i=0;
i<=n-1;
i++)
244 reflections::generatereflection<Precision>(t,
m-
i, ltau);
252 reflections::applyreflectionfromtheleft<Precision>(a, ltau, t,
i,
m-1,
i+1, n-1, work);
261 reflections::generatereflection<Precision>(t, n-1-
i, ltau);
269 reflections::applyreflectionfromtheright<Precision>(a, ltau, t,
i+1,
m-1,
i+1, n-1, work);
283 for(
i=0;
i<=
m-1;
i++)
290 reflections::generatereflection<Precision>(t, n-
i, ltau);
298 reflections::applyreflectionfromtheright<Precision>(a, ltau, t,
i+1,
m-1,
i, n-1, work);
307 reflections::generatereflection<Precision>(t,
m-1-
i, ltau);
315 reflections::applyreflectionfromtheleft<Precision>(a, ltau, t,
i+1,
m-1,
i+1, n-1, work);
347 template<
unsigned int Precision>
361 if(
m==0 || n==0 || qcolumns==0 )
369 q.setbounds(0,
m-1, 0, qcolumns-1);
370 for(
i=0;
i<=
m-1;
i++)
372 for(
j=0;
j<=qcolumns-1;
j++)
388 rmatrixbdmultiplybyq<Precision>(qp,
m, n, tauq, q,
m, qcolumns,
false,
false);
421 template<
unsigned int Precision>
441 if(
m<=0 || n<=0 || zrows<=0 || zcolumns<=0 )
491 reflections::applyreflectionfromtheright<Precision>(z, tauq(
i),
v, 0, zrows-1,
i,
m-1, work);
495 reflections::applyreflectionfromtheleft<Precision>(z, tauq(
i),
v,
i,
m-1, 0, zcolumns-1, work);
499 while(
i!=i2+istep );
539 reflections::applyreflectionfromtheright<Precision>(z, tauq(
i),
v, 0, zrows-1,
i+1,
m-1, work);
543 reflections::applyreflectionfromtheleft<Precision>(z, tauq(
i),
v,
i+1,
m-1, 0, zcolumns-1, work);
547 while(
i!=i2+istep );
574 template<
unsigned int Precision>
588 if(
m==0 || n==0 || ptrows==0 )
596 pt.setbounds(0, ptrows-1, 0, n-1);
597 for(
i=0;
i<=ptrows-1;
i++)
599 for(
j=0;
j<=n-1;
j++)
615 rmatrixbdmultiplybyp<Precision>(qp,
m, n, taup, pt, ptrows, n,
true,
true);
648 template<
unsigned int Precision>
668 if(
m<=0 || n<=0 || zrows<=0 || zcolumns<=0 )
722 reflections::applyreflectionfromtheright<Precision>(z, taup(
i),
v, 0, zrows-1,
i+1, n-1, work);
726 reflections::applyreflectionfromtheleft<Precision>(z, taup(
i),
v,
i+1, n-1, 0, zcolumns-1, work);
730 while(
i!=i2+istep );
769 reflections::applyreflectionfromtheright<Precision>(z, taup(
i),
v, 0, zrows-1,
i, n-1, work);
773 reflections::applyreflectionfromtheleft<Precision>(z, taup(
i),
v,
i, n-1, 0, zcolumns-1, work);
777 while(
i!=i2+istep );
804 template<
unsigned int Precision>
824 for(
i=0;
i<=n-2;
i++)
835 for(
i=0;
i<=
m-2;
i++)
849 template<
unsigned int Precision>
873 taup.setbounds(1, minmn);
874 tauq.setbounds(1, minmn);
889 reflections::generatereflection<Precision>(t, mmip1, ltau);
897 reflections::applyreflectionfromtheleft<Precision>(a, ltau, t,
i,
m,
i+1, n, work);
908 reflections::generatereflection<Precision>(t, nmi, ltau);
916 reflections::applyreflectionfromtheright<Precision>(a, ltau, t,
i+1,
m,
i+1, n, work);
938 reflections::generatereflection<Precision>(t, nmip1, ltau);
946 reflections::applyreflectionfromtheright<Precision>(a, ltau, t,
i+1,
m,
i, n, work);
957 reflections::generatereflection<Precision>(t, mmi, ltau);
965 reflections::applyreflectionfromtheleft<Precision>(a, ltau, t,
i+1,
m,
i+1, n, work);
980 template<
unsigned int Precision>
997 if(
m==0 || n==0 || qcolumns==0 )
1005 q.setbounds(1,
m, 1, qcolumns);
1014 for(
j=1;
j<=qcolumns;
j++)
1033 reflections::applyreflectionfromtheleft<Precision>(q, tauq(
i),
v,
i,
m, 1, qcolumns, work);
1042 ap::vmove(
v.getvector(1, vm), qp.getcolumn(
i, ip1,
m));
1044 reflections::applyreflectionfromtheleft<Precision>(q, tauq(
i),
v,
i+1,
m, 1, qcolumns, work);
1054 template<
unsigned int Precision>
1076 if(
m<=0 || n<=0 || zrows<=0 || zcolumns<=0 )
1127 reflections::applyreflectionfromtheright<Precision>(z, tauq(
i),
v, 1, zrows,
i,
m, work);
1131 reflections::applyreflectionfromtheleft<Precision>(z, tauq(
i),
v,
i,
m, 1, zcolumns, work);
1135 while(
i!=i2+istep );
1173 ap::vmove(
v.getvector(1, vm), qp.getcolumn(
i, ip1,
m));
1177 reflections::applyreflectionfromtheright<Precision>(z, tauq(
i),
v, 1, zrows,
i+1,
m, work);
1181 reflections::applyreflectionfromtheleft<Precision>(z, tauq(
i),
v,
i+1,
m, 1, zcolumns, work);
1185 while(
i!=i2+istep );
1195 template<
unsigned int Precision>
1212 if(
m==0 || n==0 || ptrows==0 )
1220 pt.setbounds(1, ptrows, 1, n);
1227 for(
i=1;
i<=ptrows;
i++)
1247 ap::vmove(
v.getvector(1, vm), qp.getrow(
i, ip1, n));
1249 reflections::applyreflectionfromtheright<Precision>(pt, taup(
i),
v, 1, ptrows,
i+1, n, work);
1259 reflections::applyreflectionfromtheright<Precision>(pt, taup(
i),
v, 1, ptrows,
i, n, work);
1269 template<
unsigned int Precision>
1291 if(
m<=0 || n<=0 || zrows<=0 || zcolumns<=0 )
1343 ap::vmove(
v.getvector(1, vm), qp.getrow(
i, ip1, n));
1347 reflections::applyreflectionfromtheright<Precision>(z, taup(
i),
v, 1, zrows,
i+1, n, work);
1351 reflections::applyreflectionfromtheleft<Precision>(z, taup(
i),
v,
i+1, n, 1, zcolumns, work);
1355 while(
i!=i2+istep );
1395 reflections::applyreflectionfromtheright<Precision>(z, taup(
i),
v, 1, zrows,
i, n, work);
1399 reflections::applyreflectionfromtheleft<Precision>(z, taup(
i),
v,
i, n, 1, zcolumns, work);
1403 while(
i!=i2+istep );
1412 template<
unsigned int Precision>
1432 for(
i=1;
i<=n-1;
i++)
1443 for(
i=1;
i<=
m-1;
i++)
static void make_assertion(bool bClause)
raw_vector< T > getvector(int iStart, int iEnd)
void setbounds(int iLow, int iHigh)
const Variable & v
< [in] a sqrfree bivariate poly
int maxint(int m1, int m2)
void vmove(raw_vector< T > vdst, const_raw_vector< T > vsrc)
int minint(int m1, int m2)
void unpackptfrombidiagonal(const ap::template_2d_array< amp::ampf< Precision > > &qp, int m, int n, const ap::template_1d_array< amp::ampf< Precision > > &taup, int ptrows, ap::template_2d_array< amp::ampf< Precision > > &pt)
void multiplybyqfrombidiagonal(const ap::template_2d_array< amp::ampf< Precision > > &qp, int m, int n, const ap::template_1d_array< amp::ampf< Precision > > &tauq, ap::template_2d_array< amp::ampf< Precision > > &z, int zrows, int zcolumns, bool fromtheright, bool dotranspose)
void rmatrixbdunpackpt(const ap::template_2d_array< amp::ampf< Precision > > &qp, int m, int n, const ap::template_1d_array< amp::ampf< Precision > > &taup, int ptrows, ap::template_2d_array< amp::ampf< Precision > > &pt)
void unpackqfrombidiagonal(const ap::template_2d_array< amp::ampf< Precision > > &qp, int m, int n, const ap::template_1d_array< amp::ampf< Precision > > &tauq, int qcolumns, ap::template_2d_array< amp::ampf< Precision > > &q)
void rmatrixbdunpackq(const ap::template_2d_array< amp::ampf< Precision > > &qp, int m, int n, const ap::template_1d_array< amp::ampf< Precision > > &tauq, int qcolumns, ap::template_2d_array< amp::ampf< Precision > > &q)
void rmatrixbdmultiplybyq(const ap::template_2d_array< amp::ampf< Precision > > &qp, int m, int n, const ap::template_1d_array< amp::ampf< Precision > > &tauq, ap::template_2d_array< amp::ampf< Precision > > &z, int zrows, int zcolumns, bool fromtheright, bool dotranspose)
void unpackdiagonalsfrombidiagonal(const ap::template_2d_array< amp::ampf< Precision > > &b, int m, int n, bool &isupper, ap::template_1d_array< amp::ampf< Precision > > &d, ap::template_1d_array< amp::ampf< Precision > > &e)
void rmatrixbdunpackdiagonals(const ap::template_2d_array< amp::ampf< Precision > > &b, int m, int n, bool &isupper, ap::template_1d_array< amp::ampf< Precision > > &d, ap::template_1d_array< amp::ampf< Precision > > &e)
void tobidiagonal(ap::template_2d_array< amp::ampf< Precision > > &a, int m, int n, ap::template_1d_array< amp::ampf< Precision > > &tauq, ap::template_1d_array< amp::ampf< Precision > > &taup)
void rmatrixbd(ap::template_2d_array< amp::ampf< Precision > > &a, int m, int n, ap::template_1d_array< amp::ampf< Precision > > &tauq, ap::template_1d_array< amp::ampf< Precision > > &taup)
void rmatrixbdmultiplybyp(const ap::template_2d_array< amp::ampf< Precision > > &qp, int m, int n, const ap::template_1d_array< amp::ampf< Precision > > &taup, ap::template_2d_array< amp::ampf< Precision > > &z, int zrows, int zcolumns, bool fromtheright, bool dotranspose)
void multiplybypfrombidiagonal(const ap::template_2d_array< amp::ampf< Precision > > &qp, int m, int n, const ap::template_1d_array< amp::ampf< Precision > > &taup, ap::template_2d_array< amp::ampf< Precision > > &z, int zrows, int zcolumns, bool fromtheright, bool dotranspose)