Note that there is no distinction between the FreeModule with 
inner_product_matrix=matrix.identity(1)*2 and FreeQuadraticModusince the 
sage object created in both ways is the same object. Not just equal, but 
literally the same object in memory, so any change will automatically 
affect both.

    FreeQuadraticModule(ZZ,1,matrix.identity(1)*2) is 
FreeModule(ZZ,1,inner_product_matrix=matrix.identity(1)*2) 

I think it is good to open a ticket to make == also take the inner product 
matrix into account, and I think no deprecation is needed since it fixes 
something which is mathematically incorrect.

One more subtle question is wether we want:

sage: 
FreeModule(ZZ,1)==FreeModule(ZZ,1,inner_product_matrix=matrix.identity(1))


On Thursday, 21 September 2017 10:13:13 UTC+2, Simon Brandhorst wrote:
>
> Currently, comparison of free_module_generic (and free_quadratic_modules) 
> ignores the inner product matrix
>
> sage: 
> FreeModule(ZZ,1)==FreeModule(ZZ,1,inner_product_matrix=matrix.identity(1)*2)
> True
> sage: 
> FreeQuadraticModule(ZZ,1,matrix.identity(1))==FreeQuadraticModule(ZZ,1,matrix.identity(1)*2)
> True
>
> Especially for FreeQuadraticModules, the inner_product_matrix is essential 
> and two FreeQuadraticModules are certainly different (mathematically) if 
> their inner product is different.
>
> Is that intended behavior? If not, I would like to open a ticket. Do I 
> need a deprecation warning or something for that ? 
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"sage-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to sage-devel+unsubscr...@googlegroups.com.
To post to this group, send email to sage-devel@googlegroups.com.
Visit this group at https://groups.google.com/group/sage-devel.
For more options, visit https://groups.google.com/d/optout.

Reply via email to