On Tue, Aug 23, 2022 at 12:51:24PM +0200, Ralf Hemmecke wrote:
> Can someone expplain why the first line does not succeed?
>
> Ralf
>
> (1) -> p4 := entries partitions(4)
>
> >> Error detected within library code:
> infinite stream
IIUC the official idiom always was:
p4 := entries(complete(partitions(4)))
Justification is that othewise one may trigger infinite loop
by accident. 'complete' is supposed to be used only to
force computation off all entries, so no risc of accident.
More generally, there are patterns of stream opeartions that
are "safe", that is there is no risc of infinite loop.
Unfortunately, safe patterns are limited in what they can
compute. So there is some tension about unsafe operations:
"power to people" folks want them all and available as
default, while others want to have mostly safe operations
with unsafe one viewed as exceptional and essentially
confined to a ghetto.
--
Waldek Hebisch
--
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 [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/fricas-devel/20220823112201.GA28448%40fricas.math.uni.wroc.pl.