# LinearDependence(S, R)ΒΆ

- S: IntegralDomain
- R: LinearlyExplicitOver S

Test for linear dependence.

- linearDependence: Vector R -> Union(Vector S, failed)
`linearDependence([v1, ..., vn])`

returns`[c1, ..., cn]`

if`c1*v1 + ... + cn*vn = 0`

and not all the`ci`

`'s`

are 0, “failed” if the`vi`

`'s`

are linearly independent over`S`

.

- linearlyDependent?: Vector R -> Boolean
`linearlyDependent?([v1, ..., vn])`

returns`true`

if the`vi`

`'s`

are linearly dependent over`S`

,`false`

otherwise.

- particularSolution: (Matrix R, Vector R) -> Union(Vector Fraction S, failed) if S hasn’t Field
`particularSolution([v1, ..., vn], u)`

returns`[c1, ..., cn]`

such that`c1*v1 + ... + cn*vn = u`

, “failed” if no such`ci`

`'s`

exist in the quotient field of`S`

.

- particularSolution: (Matrix R, Vector R) -> Union(Vector S, failed) if S has Field
`particularSolution([v1, ..., vn], u)`

returns`[c1, ..., cn]`

such that`c1*v1 + ... + cn*vn = u`

, “failed” if no such`ci`

`'s`

exist in`S`

.

- particularSolution: (Vector R, R) -> Union(Vector Fraction S, failed) if S hasn’t Field
`particularSolution([v1, ..., vn], u)`

returns`[c1, ..., cn]`

such that`c1*v1 + ... + cn*vn = u`

, “failed” if no such`ci`

`'s`

exist in the quotient field of`S`

.

- particularSolution: (Vector R, R) -> Union(Vector S, failed) if S has Field
`particularSolution([v1, ..., vn], u)`

returns`[c1, ..., cn]`

such that`c1*v1 + ... + cn*vn = u`

, “failed” if no such`ci`

`'s`

exist in`S`

.

- solveLinear: (Matrix R, Vector R) -> Record(particular: Union(Vector Fraction S, failed), basis: List Vector Fraction S) if S hasn’t Field
`solveLinear([v1, ..., vn], u)`

returns solution of the system`c1*v1 + ... + cn*vn = u`

and and a basis of the associated homogeneous system`c1*v1 + ... + cn*vn = 0`

- solveLinear: (Matrix R, Vector R) -> Record(particular: Union(Vector S, failed), basis: List Vector S) if S has Field
`solveLinear([v1, ..., vn], u)`

returns solution of the system`c1*v1 + ... + cn*vn = u`

and and a basis of the associated homogeneous system`c1*v1 + ... + cn*vn = 0`