1

By function-call/procedure-call pairs, I mean pairs of functions that do the same thing, except one returns it's result whereas the other alters it's argument(s) to be the result. For example the pair List/Apply.

  • List(list, func) Returns the list resulting from applying the function func to every value of list.
  • Apply(list, func) Applies the function func to every value of a mutable list list, changing list.

I've become annoyed of writing my own functions to find that GAP already had a built in version I should be using, so it'd help to know these pairs. Like, does Filtered have a procedural counterpart I don't know about? Or do I need to write my own? If a function does have a counterpart will it necessarily be listed in the documentation for that function? The only other such pair that I can think of right now is Concatenation/Append. What are other such pairs of functions/procedures in GAP?

Mike Pierce
  • 1,390
  • 1
  • 12
  • 35
  • 1
    Although this may be of little help, as @ahulpke explained in https://math.stackexchange.com/questions/3704518/, "The general language convention is that verbs do something to an object, while nouns create a new object with the desired characteristics." So, a counterpart to `Filtered` would likely be called `Filter` - but there is no such function (and `Filter` has another meaning in GAP). We do try to mention counterparts in corresponding ManSections - if you find them missing, then please suggest improvements of GAP manuals. – Olexandr Konovalov Jun 30 '20 at 15:20

1 Answers1

1

Although this may be of little help, as Alexander Hulpke explained in https://math.stackexchange.com/questions/3704518, "The general language convention is that verbs do something to an object, while nouns create a new object with the desired characteristics." GAP naming conventions are described in the GAP Reference Manual here.

So, a counterpart to Filtered would likely be called Filter - but there is no such function (and Filter has another meaning in GAP). We do try to mention counterparts in corresponding manual sections - if you find them missing, then please suggest improvements to the GAP documentation, preferably at the GAP repository on GitHub.