An efficient algorithm for permutation iteration using a singly linked list. ~ Thomas Baruchel. https://arxiv.org/abs/2501.10102v1 #CommonLisp #Algorithms
Conversation
Notices
-
Embed this notice
José A. Alonso (jose_a_alonso@mathstodon.xyz)'s status on Tuesday, 21-Jan-2025 03:37:27 JST José A. Alonso
- screwlisp and Arne Babenhauserheide repeated this.
-
Embed this notice
th. baruchel (baruchel@functional.cafe)'s status on Tuesday, 21-Jan-2025 03:37:42 JST th. baruchel
@Jose_A_Alonso Thank you for referencing that paper! If you'd like a quick look at the #Lisp code, feel free to check out the snippet I uploaded here:
https://git.univ-pau.fr/tbaruchel/numerical-routines/-/snippets/5
The core concept of the algorithm is to iterate in-place over all permutations, efficiently reusing all nodes of the native Lisp list.
In conversation permalink