#include <minpoly.h>
Definition at line 68 of file minpoly.h.
◆ LinearDependencyMatrix()
LinearDependencyMatrix::LinearDependencyMatrix |
( |
unsigned |
n, |
|
|
unsigned long |
p |
|
) |
| |
Definition at line 19 of file minpoly.cc.
20{
23
24 matrix =
new unsigned long *[
n];
25 for(
int i = 0;
i <
n;
i++)
26 {
27 matrix[
i] =
new unsigned long[2 *
n + 1];
28 }
30 tmprow =
new unsigned long[2 *
n + 1];
32}
◆ ~LinearDependencyMatrix()
LinearDependencyMatrix::~LinearDependencyMatrix |
( |
| ) |
|
Definition at line 34 of file minpoly.cc.
35{
38
39 for(
int i = 0;
i <
n;
i++)
40 {
42 }
44}
◆ findLinearDependency()
bool LinearDependencyMatrix::findLinearDependency |
( |
unsigned long * |
newRow, |
|
|
unsigned long * |
dep |
|
) |
| |
Definition at line 96 of file minpoly.cc.
98{
99
100 for(
int i = 0;
i <
n;
i++)
101 {
104 }
107
109
110
111
113 if(newpivot == -1)
114 {
115 for(
int i = 0;
i <=
n;
i++)
116 {
118 }
119
120 return true;
121 }
122 else
123 {
125
126 for(
int i = 0;
i < 2 *
n + 1;
i++)
127 {
129 }
130
133
134 return false;
135 }
136}
void normalizeTmp(unsigned i)
int firstNonzeroEntry(unsigned long *row)
◆ firstNonzeroEntry()
int LinearDependencyMatrix::firstNonzeroEntry |
( |
unsigned long * |
row | ) |
|
Definition at line 51 of file minpoly.cc.
52{
53 for(
int i = 0;
i <
n;
i++)
56
57 return -1;
58}
◆ normalizeTmp()
void LinearDependencyMatrix::normalizeTmp |
( |
unsigned |
i | ) |
|
Definition at line 88 of file minpoly.cc.
89{
92 for(
int j =
i + 1;
j < 2 *
n + 1;
j++)
94}
unsigned long modularInverse(long long x, long long p)
static unsigned long multMod(unsigned long a, unsigned long b, unsigned long p)
◆ reduceTmpRow()
void LinearDependencyMatrix::reduceTmpRow |
( |
| ) |
|
Definition at line 60 of file minpoly.cc.
61{
63 {
66
68 {
69
70 for(
int j = piv;
j <
n +
rows + 1;
j++)
71 {
73 {
78 {
80 }
81 }
82 }
83 }
84 }
85}
◆ resetMatrix()
void LinearDependencyMatrix::resetMatrix |
( |
| ) |
|
◆ NewVectorMatrix
◆ matrix
unsigned long** LinearDependencyMatrix::matrix |
|
private |
unsigned long LinearDependencyMatrix::n |
|
private |
unsigned LinearDependencyMatrix::p |
|
private |
◆ pivots
unsigned* LinearDependencyMatrix::pivots |
|
private |
◆ rows
unsigned LinearDependencyMatrix::rows |
|
private |
◆ tmprow
unsigned long* LinearDependencyMatrix::tmprow |
|
private |
The documentation for this class was generated from the following files: