aboutsummaryrefslogtreecommitdiff
path: root/src/ModularArithmetic
Commit message (Collapse)AuthorAge
* Fix side-condition from previous commitGravatar Jason Gross2016-07-19
|
* Add another lemma to distr_lengthGravatar Jason Gross2016-07-19
|
* Use update_nth in add_to_nth (#26)Gravatar Jason Gross2016-07-19
| | | | | | It leads to a slightly more transparent and clearer definition. If I got everything right, nothing should depend on the judgmental definition of [add_to_nth] anymore.
* ext_base: now defined in terms of ext_limb_widthsGravatar Jason Gross2016-07-18
|
* Add a lemma about base_from_limb_widths and appGravatar Jason Gross2016-07-18
|
* Move more proofs earlierGravatar Jason Gross2016-07-18
|
* Make Pow2BaseProofs independent of the def of add_to_nthGravatar Jason Gross2016-07-18
|
* Express carry_simple in terms of carry_genGravatar Jason Gross2016-07-18
| | | | | | Also make much of the remaining code outside of Pow2BaseProofs independent of the precise definition of carry_simple. (We use [Local Opaque] to enforce this modularity.
* Move some definitions to Pow2Base (#24)Gravatar Jason Gross2016-07-18
| | | | | | | | | * Move some definitions to Pow2Base These definitions don't depend on PseudoMersenneBaseParams, only on limb_widths, and we'll want them for BarrettReduction / P256. * Fix for Coq 8.4
* ported IterAssocOp to use monoid rather than a billion context variables ↵Gravatar jadep2016-07-18
| | | | that add up to a monoid
* rewrote Testbit and factored out some necessary lemmas about 'uniform' bases ↵Gravatar jadep2016-07-18
| | | | (bases that are repeats of the same power of 2) into Pow2Base
* more changes to Specific for 8.4 compatibilityGravatar jadep2016-07-15
|
* removing experimental file accidentally included in last commitGravatar jadep2016-07-12
|
* pushing through a tweak to the arguments of [sub], and defining a field over ↵Gravatar jadep2016-07-12
| | | | ModularBaseSystemInterface using some placeholder operations.
* Make [base] and [log_cap] notationsGravatar Jason Gross2016-07-11
| | | | | | | | Also use [ZUtil.Z.pow2_mod]. This lets us remove the dependency of ModularBaseSystem on ModularArithmetic.PseudoMersenneBaseParamProofs. This is a small part of reorganizing and factoring ModularBaseSystem for use with Barrett reduction.
* Merge of fixedlength and masterGravatar jadep2016-07-11
|\
* | ported Specific files to use ModularBaseSystemInterfaceGravatar jadep2016-07-11
| |
* | proved correctness of [add] operation in ModularBaseSystemInterfaceGravatar jadep2016-07-08
| |
* | defined some group operations, stated group lemma for tuple-based [add] (in ↵Gravatar jadep2016-07-08
| | | | | | | | terms of isomorphism to ModularArithmetic.F), proved lemma about tuple-based [mul] based on the goals generated by the group constructor
* | added a few length proofs to ModularBaseSystemProofs to help with tuple ↵Gravatar jadep2016-07-08
| | | | | | | | conversion
* | unstuck carry_mul_opt_cps using from_list_defaultGravatar jadep2016-07-08
| |
| * Changed [auto]s to [eauto]s in ModularBaseSystemProofs for 8.5 compatibility.Gravatar jadep2016-07-07
| |
| * Merged changes, including new ZUtil conventions.Gravatar jadep2016-07-06
| |\
| * | Factored out some proofs that rely only on base being powers of two, and ↵Gravatar jadep2016-07-06
| | | | | | | | | | | | defined conversion between two such bases. This will allow conversion between the pseudomersenne base representation and the wire format. Also relocated some lemmas to Util.
* | | stuck trying to figure out dependently typed continuation passing styleGravatar Andres Erbsen2016-07-06
| | |
* | | add new interface to ModularBaseSystemGravatar Andres Erbsen2016-07-03
| | |
* | | remove PseudoMersenneRepGravatar Andres Erbsen2016-07-03
| | |
| | * Implement and prove Barrett reduction on Z (#18)Gravatar Jason Gross2016-07-03
| | | | | | | | | | | | | | | | | | | | | | | | Implement and prove Barrett reduction on Z This will serve as the high-level algorithm for modular reduction. We follow Wikipedia very closely, except where we can do better (I believe @jadephilipoom is updating Wikipedia).
| | * Make ZUtil more uniformGravatar Jason Gross2016-07-02
| |/ |/| | | | | | | | | | | | | The standard library uses Z.*, and Z* and Z_* are compatibility notations. We follow suit. Also, eliminate a few lemmas that are duplicates of ones in the standard library.
| * added and proved shift/or decode operation 'decode_bitwise'Gravatar jadep2016-06-30
| |
| * encode operation in ModularBaseSystem now uses bitwise operators, taking ↵Gravatar jadep2016-06-29
| | | | | | | | advantage of the fact that base elements are required to be powers of 2
| * BaseSystem encode function is no longer naive; it does a mod/div loop rather ↵Gravatar jadep2016-06-28
|/ | | | than sticking the value of the Z input in the first digit. The condition that c is positive has been added to PseudoMersenneBaseParams--it is necessary for this encode and for canonicalization, for which it was previously a section variable.
* Aggregate all level specifications not in Spec/*Gravatar Jason Gross2016-06-22
| | | | | This prevents notation conflicts (see comment in Notations.v for more explanation).
* remove trailing whitespace from src/Gravatar Andres Erbsen2016-06-20
|
* Merge branch 'field-experiment'Gravatar Andres Erbsen2016-06-20
|\ | | | | | | includes broken files to be removed in next commit
| * [F q] is [Algebra.field]Gravatar Andres Erbsen2016-06-20
| |
| * port CompleteEdwardsCurve.ExtendedCoordinates, make [field_algebra] try ↵Gravatar Andres Erbsen2016-06-18
| | | | | | | | fewer nonzero ports. remove FField and FNsatz
* | Canonicalization is now automated in GF25519 and added to GF1305.Gravatar jadep2016-06-17
| |
* | Specific version of freeze for GF25519 (automation still needs a little work)Gravatar jadep2016-06-17
| |
| * move nsatz out of algebra, improve algebra, port CompleteEdwardsCurveTheoremsGravatar Andres Erbsen2016-06-17
| |
| * Z is integral domainGravatar Andres Erbsen2016-06-16
| |
* | PseudoMersenneBaseRep.mul now carries by default (made possible by strictly ↵Gravatar jadep2016-06-15
| | | | | | | | base-length digit vectors)
* | changed representation definition to require digits vector to be the exact ↵Gravatar jadep2016-06-15
| | | | | | | | length of the base vector
* | Added canonicalization to ModularBaseSystemOpt.Gravatar jadep2016-06-15
| |
* | MergeGravatar jadep2016-06-14
|\ \
* | | Finished admits for canonicalization proofs.Gravatar jadep2016-06-14
| | |
* | | reversed modulus_digits and proved a few admitsGravatar jadep2016-06-13
| | |
* | | progress on second stage (conditional constant-time subtraction) of ↵Gravatar jadep2016-06-13
| | | | | | | | | | | | canonicalization proofs
| * | More Coq 8.4pl2 fixesGravatar Jason Gross2016-06-11
| | |
* | | starting rewrite using different definition of mapGravatar jadep2016-06-11
| |/ |/|