On 27/03/17 04:49, Waldek Hebisch wrote:
some passage look completely
   wrong, like:

+The use of the Vector domain for this does seem to be stretching
+the FriCAS type system a bit. For instance elements of subgroup are
+coded as a vector of a vector (Vector Vector NNI) which would not be
+valid if the type system were fully checked but presumably gets away
+with it because vectors are defined over Type.

   Vector(NNI) stores nonnegative integers and provides 1 based
   indexing.  We do not need most operations provided by Vector,
   in particular we do not need vector addition or multiplication
   by scalars but that is OK: we use what Vector provides and
   nothing more.  In other words, we could probably just use arrays
   here (but IIRC there was some useful function that only accepted
   vectors and did not work on arrays).  And using arrays or
   vectors to store permutations is a standard trick allowing
   resonably fast operations on permutations.

So what have I said that is wrong here?

I know that some languages, like java, have vector types which are really a type of array. However I suspect that someone trying to understand an algebra program might expect that when they find a instance of a Vector domain then it would represent an element of a vector space. That is it has valid vector addition and scalar multiplication, they might even think that the type system would enforce that.

Put yourself in the mind of a potential user or contributor to permgrps.spad. You come across a structure (Vector) being used in an unusual way would it not help you to see some explanation that might warn you of that?

Martin B

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

Reply via email to