or
or
By clicking below, you agree to our terms of service.
New to HackMD? Sign up
Syntax | Example | Reference | |
---|---|---|---|
# Header | Header | 基本排版 | |
- Unordered List |
|
||
1. Ordered List |
|
||
- [ ] Todo List |
|
||
> Blockquote | Blockquote |
||
**Bold font** | Bold font | ||
*Italics font* | Italics font | ||
~~Strikethrough~~ | |||
19^th^ | 19th | ||
H~2~O | H2O | ||
++Inserted text++ | Inserted text | ||
==Marked text== | Marked text | ||
[link text](https:// "title") | Link | ||
 | Image | ||
`Code` | Code |
在筆記中貼入程式碼 | |
```javascript var i = 0; ``` |
|
||
:smile: | ![]() |
Emoji list | |
{%youtube youtube_id %} | Externals | ||
$L^aT_eX$ | LaTeX | ||
:::info This is a alert area. ::: |
This is a alert area. |
On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?
Please give us some advice and help us improve HackMD.
Syncing
xxxxxxxxxx
Type renaming in Oscar
We intend to rename a bunch of types in AbstractAlgebra, Nemo, Hecke, Oscar and possibly other of our packages. The motivation for this is to have consistent, predictable type name as much as possible.
Also, while initially it was a good idea to keep the flint-names (fmpz and friends) it is now more of a problem than a feature, the names internal to flint do not have to be the ones visible and used in Oscar.
The plan for Nemo.jl thus is to change
mutable struct fmpz
tomutable struct ZZElem
and then addconst fmpz = ZZElem
inside Nemo.jl resp. right after the struct is , not much Nemo code needs to change. Then a few doctests or examples in the manual may need to be updated. No other changes should be needed in Nemo (e.g. no files need to be renamed)The list here is far from complete, so please add more.
The Plan is to
do it simultaneously across all reposstagger the change where possible, using the new@alias
macro, starting with AA then proceeding to the others; only a few things (NCRing -> Ring -> CommRing
) can't be done like that and require simultaneous breaking changes; these should be done separately and at onceconst old=new
statements to protect the old codeNemo types
Tommy: I think we want to get away from names like
nmod/fmpz_mod
, since we want to convey a bit more mathematical meaning in the type names (similar to the proposed change fromfmpz
toZZElemz
).These are some of flint types that must be renamed (FqNmodFiniteFieldElem is simply too long)
Tommy:
_Rep*
-suffix a place holder or the really part of the name? If so, why? Answer: It doesn't matter, I just had to fill in the table. If we continue with the ZZ/zz idea, it could befq => FqElem_PolyRep
,fq_nmod => fqElem_PolyRep
,fq_zech => fqElem_ZechRep
.I love it! Let's do this.
zz/ZZ
andfp/Fp
idea, although it clashes a bit with the camel case convention for types. On the other hand, I agree thatFqNmodFiniteFieldMPolynomial
might be a bit too long.FinField
AbstractAlgebra types
Abstract types
If the wise algebra wizards come to the conclusion that a univariate polynomial ring over a non-commutative ring make sense, we also need
Poly
CommPoly
CommPoly <: CommRingElem
, Is isCommPoly
orCommPolynomial
? How do we decide when the suffixElem
is needed?Poly
Poly
Poly <: RingElem
MPoly
CommMPoly
CommMPoly <: CommRingElem
Michael: Generally, I am in favor of long names. After all OSCAR is a large project, and we have numerous objects, types, functions etc (and tab completion is your friend). Yet, from the tables above I can see that there are reasons for combinations of short names like FqPolyRepMatrix.
I suggest at the very least to keep the generic names long, like Polynomial (with a coefficient domain to be specified by an argument), CommutativeRing (leaving Ring for the not necessarily commutative case). I would also go with AbelianGroup (but I can live with AbGroup if someone has a strong opinion; I would hate things like AbGrp though).
Let me also (softly) suggest to consider Integer for fmpz and Rational for fmpq [this probably will not work well because these names are already taken by Julia for it's abstract types]. Since these will be used much more often by most users than any other types, it would be good to give them good names. This is not meant as a contradiction to Tommy's table. We could keep, e.g., zzElem (or any other systematic name) as a synonym for Integer. The names ZZ and QQ are good, of course.<
Generic (concrete!) types
If you can't get a general idea of what the type represents from the name, then it probably needs renaming. If we follow this, we are going to be typing
Comm
everywhere. If we drop the notion of polynomials over non-commutative coefficient rings (and don't call them polynomials), then we can avoid thisCommPoly
,CommSeries
,CommMPoly
,CommMSeries
business. I am in general applying the shorteningsPolynomialRing => PolyRing
andAlgebraElem => AlgElem
.EDIT: I have now crossed these out, for the variation where we don't type
Comm
everywhere.CommPolynomial{T} /CommPolyRing{T}Polynomial{T}(??) /PolyRing{T}(??)new name is also unfortunate, leaves a bad tastewhat are these things called?CommMPolynomial{T} /CommMPolyRing{T}CommPolynomial{T} / UniversalCommPolyRing{T}UnivPoly
definitely must be renamedWrap
CommRelativePowerSeries{T} /CommRelativePowerSeriesRing{T}CommAbsolutePowerSeries{T} /CommAbsolutePowerSeriesRing{T}CommAbsoluteMPowerSeries{T} /CommAbsoluteMPowerSeriesRing{T}Matrix
is already taken by Julia. There is alsoMatrixSpaceView
. (No there isn't?)Suggestion: use "graded" instead of "Decorated" and just don't mention that we can also handle filtrations?
Decision: for now we just stay with the name
_dec
Quo -> Quotient??? and how does this related to
quo(...)
should it becomequotient(..).
Localized <-> Loc ???
some more type names in Oscar:
some things that should be consistently named but are not:
FPGroup
vs.PcGroup
(in GAP, it'sFpGroup
andPcGroup
)FPModule
vs.ModuleFP
FPGroup
andFPGroupElem
FinPres
instead ofFP
?elem_type
,parent_type
,abs_series_type
,dense_poly_type
, ..mpoly_type
but basically no methods; add those?matrix_space_type
or so? then we could rewritematrix_space
with a single methodRules for naming types
The following should eventually appear in the OSCAR dev manual (and perhaps other places)
Ring
/Group
/Ideal
/Module
/…Elem
addedMatrixSpace
elements end withMatrix
Abs
stands forAbsolute
, and so must not be used for e.g.Abstract
Quo
Subquo
Loc
Dec
Abs
Abstract
Rel
Poly
MPoly
Matrix
orMat
??Group
Ring
Ideal
Module
T
and the sparse onSparseT
Other renaming
Besides types, also some function may be renamed (?)
Some suggestions:
gens
->generators
gen
->generator
ngens
->number_of_generators
ornumber_generators
???(some of) the shorter names may remain for programmer's convenience?
PolynomialRing
->polynomial_ring
GradedPolynomialRing
->(graded_)polynomial_ring
change
is_normal
tois_normalizing
plusis_normal_subgroup
FakeFmpqMat
-> …other tasks
see XXX
links to them in more places, mentioning them in docstrings for types, …For Thursday:
is_normal
tois_normalizing
plusis_normal_subgroup
? (do we have an open issue for that?)Matrix
instead ofMatrixSpaceElem
, so why not@req
https://github.com/thofma/Hecke.jl/issues/919Actual renaming
These are renamings we decided upon.
fmpq_abs_series QQAbsPowerSeriesRingElem
fmpq_rel_series QQRelPowerSeriesRingElem
FmpqAbsSeriesRing QQAbsPowerSeriesRing
FmpqRelSeriesRing QQRelPowerSeriesRing
fmpz_abs_series ZZAbsPowerSeriesRingElem
fmpz_rel_series ZZRelPowerSeriesRingElem
FmpzAbsSeriesRing ZZAbsPowerSeriesRing
FmpzRelSeriesRing ZZRelPowerSeriesRing
fmpz_laurent_series ZZLaurentSeriesRingElem
FmpzLaurentSeriesRing ZZLaurentSeriesRing
fmpz_mod_abs_series ZZModAbsPowerSeriesRingElem
fmpz_mod_rel_series ZZModRelPowerSeriesRingElem
FmpzModAbsSeriesRing ZZModAbsPowerSeriesRing
FmpzModRelSeriesRing ZZModRelPowerSeriesRing
fq_default_abs_series FqAbsPowerSeriesRingElem
fq_default_rel_series FqRelPowerSeriesRingElem
FqDefaultAbsSeriesRing FqAbsPowerSeriesRing
FqDefaultRelSeriesRing FqRelPowerSeriesRing
fq_abs_series FqPolyRepAbsPowerSeriesRingElem
fq_rel_series FqPolyRepRelPowerSeriesRingElem
FqAbsSeriesRing FqPolyRepAbsPowerSeriesRing
FqRelSeriesRing FqPolyRepRelPowerSeriesRing
fq_nmod_abs_series fqPolyRepAbsPowerSeriesRingElem
fq_nmod_rel_series fqPolyRepRelPowerSeriesRingElem
FqNmodAbsSeriesRing fqPolyRepAbsPowerSeriesRing
FqNmodRelSeriesRing fqPolyRepRelPowerSeriesRing
gfp_abs_series fpAbsPowerSeriesRingElem
gfp_rel_series fpRelPowerSeriesRingElem
GFPAbsSeriesRing fpAbsPowerSeriesRing
GFPRelSeriesRing fpRelPowerSeriesRing
gfp_fmpz_abs_series FpAbsPowerSeriesRingElem
gfp_fmpz_rel_series FpRelPowerSeriesRingElem
GFPFmpzAbsSeriesRing FpAbsPowerSeriesRing
GFPFmpzRelSeriesRing FpRelPowerSeriesRing
nmod_abs_series zzModAbsPowerSeriesRingElem
nmod_rel_series zzModRelPowerSeriesRingElem
NmodAbsSeriesRing zzModAbsPowerSeriesRing
NmodRelSeriesRing zzModRelPowerSeriesRing
We also wanted to do this, but then discovered that RealField, RealElem, ComplexField, ComplexElem exist… these seem to be almost identical but have a "single parent" approach…
TODOs:
*Series
types in NemoMatSpace
/MatrixSpace
/matrix_space
snake_case
?