Difference between revisions of "ApCoCoA-1:CharP.NLASolve"
(New page: <command> <title>CharP.GBasisF2</title> <short_description>Computing the unique <tt>F_2-</tt>rational zero of a given polynomial system over <tt>F_2</tt>.</short_description> <synt...) |
|||
Line 3: | Line 3: | ||
<short_description>Computing the unique <tt>F_2-</tt>rational zero of a given polynomial system over <tt>F_2</tt>.</short_description> | <short_description>Computing the unique <tt>F_2-</tt>rational zero of a given polynomial system over <tt>F_2</tt>.</short_description> | ||
<syntax> | <syntax> | ||
− | CharP.NLASolve(F:LIST):LIST | + | CharP.NLASolve(F:LIST, Sparse:BOOL):LIST |
</syntax> | </syntax> | ||
<description> | <description> | ||
Line 9: | Line 9: | ||
<par/> | <par/> | ||
− | This function computes the unique zero in <tt>F_2^n</tt> of a polynomial system over <tt>F_2 </tt>. It uses NLA-Algorithm to find the unique zero. The NLA-Algorithm generates a sequence of linear systems to solve the given system. The NLA-Algorithm can find the unique zero only. If the given polynomial system has more than one zeros in <tt>F_2^n </tt> then this function does not find any zero. In this case a massage for non-uniqueness will be displayed to the screen after reaching the maximum degree bound. | + | This function computes the unique zero in <tt>F_2^n</tt> of a polynomial system over <tt>F_2 </tt>. It uses NLA-Algorithm to find the unique zero. The NLA-Algorithm generates a sequence of linear systems to solve the given system. The NLA-Algorithm can find the unique zero only. If the given polynomial system has more than one zeros in <tt>F_2^n </tt> then this function does not find any zero. In this case a massage for non-uniqueness will be displayed to the screen after reaching the maximum degree bound. You can also choose between sparse and dense implementation of gaussian elimination. In sparse case it uses <ref>slinalg.SEF</ref> and in dense case it uses <ref>linalg.EF</ref> |
<itemize> | <itemize> | ||
<item>@param <em>F:</em> List of polynomials of given system.</item> | <item>@param <em>F:</em> List of polynomials of given system.</item> | ||
− | <item>@param <em>Sparse:</em> Sparsity of given polynomial system. Set Sparse to | + | <item>@param <em>Sparse:</em> Sparsity of given polynomial system. Set Sparse to True if the given polynomial system is sparse. Set Sparse to False if the given polynomial system is dense.</item> |
<item>@return The unique solution of the given system in <tt>F_2^n</tt>. </item> | <item>@return The unique solution of the given system in <tt>F_2^n</tt>. </item> | ||
</itemize> | </itemize> | ||
Line 125: | Line 125: | ||
-- And we achieve the following information on the screen. | -- And we achieve the following information on the screen. | ||
---------------------------------------- | ---------------------------------------- | ||
+ | Finding Variable: x[4] | ||
+ | The size of Matrix is: | ||
+ | No. of Rows=9 | ||
+ | No. of Columns=5 | ||
+ | Appling Gaussian Elimination... | ||
+ | -- CoCoAServer: computing Cpu Time = 0 | ||
+ | ------------------------------- | ||
+ | Gaussian Elimination Completed. | ||
+ | The size of Matrix is: | ||
+ | No. of Rows=9 | ||
+ | No. of Columns=5 | ||
+ | Appling Gaussian Elimination... | ||
+ | -- CoCoAServer: computing Cpu Time = 0 | ||
+ | ------------------------------- | ||
+ | Gaussian Elimination Completed. | ||
+ | The size of Matrix is: | ||
+ | No. of Rows=14 | ||
+ | No. of Columns=21 | ||
+ | Appling Gaussian Elimination... | ||
+ | -- CoCoAServer: computing Cpu Time = 0 | ||
+ | ------------------------------- | ||
+ | Gaussian Elimination Completed. | ||
+ | The size of Matrix is: | ||
+ | No. of Rows=14 | ||
+ | No. of Columns=21 | ||
+ | Appling Gaussian Elimination... | ||
+ | -- CoCoAServer: computing Cpu Time = 0 | ||
+ | ------------------------------- | ||
+ | Gaussian Elimination Completed. | ||
+ | The size of Matrix is: | ||
+ | No. of Rows=15 | ||
+ | No. of Columns=57 | ||
+ | Appling Gaussian Elimination... | ||
+ | -- CoCoAServer: computing Cpu Time = 0 | ||
+ | ------------------------------- | ||
+ | Gaussian Elimination Completed. | ||
+ | The size of Matrix is: | ||
+ | No. of Rows=15 | ||
+ | No. of Columns=57 | ||
+ | Appling Gaussian Elimination... | ||
+ | -- CoCoAServer: computing Cpu Time = 0 | ||
+ | ------------------------------- | ||
+ | Gaussian Elimination Completed. | ||
+ | x[4] = NA | ||
+ | Please Check the uniqueness of solution. | ||
+ | The Given system of polynomials does not | ||
+ | seem to have a unique solution or it has | ||
+ | no solution over the finite field F2. | ||
+ | |||
</example> | </example> |
Revision as of 10:24, 7 December 2010
CharP.GBasisF2
Computing the unique F_2-rational zero of a given polynomial system over F_2.
Syntax
CharP.NLASolve(F:LIST, Sparse:BOOL):LIST
Description
Please note: The function(s) explained on this page is/are using the ApCoCoAServer. You will have to start the ApCoCoAServer in order to use it/them.
This function computes the unique zero in F_2^n of a polynomial system over F_2 . It uses NLA-Algorithm to find the unique zero. The NLA-Algorithm generates a sequence of linear systems to solve the given system. The NLA-Algorithm can find the unique zero only. If the given polynomial system has more than one zeros in F_2^n then this function does not find any zero. In this case a massage for non-uniqueness will be displayed to the screen after reaching the maximum degree bound. You can also choose between sparse and dense implementation of gaussian elimination. In sparse case it uses slinalg.SEF and in dense case it uses linalg.EF
@param F: List of polynomials of given system.
@param Sparse: Sparsity of given polynomial system. Set Sparse to True if the given polynomial system is sparse. Set Sparse to False if the given polynomial system is dense.
@return The unique solution of the given system in F_2^n.
Example
Use Z/(2)[x[1..4]]; F:=[ x[1]x[2] + x[2]x[3] + x[2]x[4] + x[3]x[4] + x[1] + x[3] + 1, x[1]x[2] + x[1]x[3] + x[1]x[4] + x[3]x[4] + x[2] + x[3] + 1, x[1]x[2] + x[1]x[3] + x[2]x[3] + x[3]x[4] + x[1] + x[4] + 1, x[1]x[3] + x[2]x[3] + x[1]x[4] + x[2]x[4] + 1 ]; Sparse:=1; -- Then we compute the solution with CharP.NLASolve(F,Sparse); -- And we achieve the following information on the screen together with the solution at the end. ---------------------------------------- Finding Variable: x[4] The size of Matrix is: No. of Rows=11 No. of Columns=5 Appling Gaussian Elimination... -- CoCoAServer: computing Cpu Time = 0 ------------------------------- Gaussian Elimination Completed. The size of Matrix is: No. of Rows=11 No. of Columns=5 Appling Gaussian Elimination... -- CoCoAServer: computing Cpu Time = 0 ------------------------------- Gaussian Elimination Completed. The size of Matrix is: No. of Rows=15 No. of Columns=21 Appling Gaussian Elimination... -- CoCoAServer: computing Cpu Time = 0 ------------------------------- Gaussian Elimination Completed. The size of Matrix is: No. of Rows=15 No. of Columns=21 Appling Gaussian Elimination... -- CoCoAServer: computing Cpu Time = 0 ------------------------------- Gaussian Elimination Completed. x[4] = 1 Finding Variable: x[3] The size of Matrix is: No. of Rows=7 No. of Columns=5 Appling Gaussian Elimination... -- CoCoAServer: computing Cpu Time = 0 ------------------------------- Gaussian Elimination Completed. The size of Matrix is: No. of Rows=7 No. of Columns=5 Appling Gaussian Elimination... -- CoCoAServer: computing Cpu Time = 0 ------------------------------- Gaussian Elimination Completed. The size of Matrix is: No. of Rows=8 No. of Columns=17 Appling Gaussian Elimination... -- CoCoAServer: computing Cpu Time = 0 ------------------------------- Gaussian Elimination Completed. x[3] = 0 Finding Variable: x[2] The size of Matrix is: No. of Rows=4 No. of Columns=4 Appling Gaussian Elimination... -- CoCoAServer: computing Cpu Time = 0 ------------------------------- Gaussian Elimination Completed. The size of Matrix is: No. of Rows=4 No. of Columns=4 Appling Gaussian Elimination... -- CoCoAServer: computing Cpu Time = 0 ------------------------------- Gaussian Elimination Completed. x[2] = 1 [0, 1, 0, 1]
Example
Use Z/(2)[x[1..4]]; F:=[ x[2]x[3] + x[1]x[4] + x[2]x[4] + x[3]x[4] + x[1] + x[2] + x[3] + x[4], x[2]x[3] + x[2]x[4] + x[3]x[4] + x[2] + x[3] + x[4], x[1]x[2] + x[2]x[3] + x[2]x[4] + x[3]x[4] + x[1] + x[2], x[1]x[2] + x[2]x[3] + x[2]x[4] + x[3]x[4] + x[1] + x[2] ]; Sparse:=0; -- Solution is not unique i.e. [0, 1, 1, 1], [0, 0, 0, 0], and [1, 1, 1, 1] are solutions -- Then we compute the solution with CharP.NLASolve(F,Sparse); -- And we achieve the following information on the screen. ---------------------------------------- Finding Variable: x[4] The size of Matrix is: No. of Rows=9 No. of Columns=5 Appling Gaussian Elimination... -- CoCoAServer: computing Cpu Time = 0 ------------------------------- Gaussian Elimination Completed. The size of Matrix is: No. of Rows=9 No. of Columns=5 Appling Gaussian Elimination... -- CoCoAServer: computing Cpu Time = 0 ------------------------------- Gaussian Elimination Completed. The size of Matrix is: No. of Rows=14 No. of Columns=21 Appling Gaussian Elimination... -- CoCoAServer: computing Cpu Time = 0 ------------------------------- Gaussian Elimination Completed. The size of Matrix is: No. of Rows=14 No. of Columns=21 Appling Gaussian Elimination... -- CoCoAServer: computing Cpu Time = 0 ------------------------------- Gaussian Elimination Completed. The size of Matrix is: No. of Rows=15 No. of Columns=57 Appling Gaussian Elimination... -- CoCoAServer: computing Cpu Time = 0 ------------------------------- Gaussian Elimination Completed. The size of Matrix is: No. of Rows=15 No. of Columns=57 Appling Gaussian Elimination... -- CoCoAServer: computing Cpu Time = 0 ------------------------------- Gaussian Elimination Completed. x[4] = NA Please Check the uniqueness of solution. The Given system of polynomials does not seem to have a unique solution or it has no solution over the finite field F2.
See also
Introduction to Groebner Basis in CoCoA