Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.prolog > #14681

Fishy 🐟 in Scryer Prolog and SWI-Prolog (Was: Humans are just overwhelmed by computers)

From Mild Shock <janburse@fastmail.fm>
Newsgroups comp.lang.prolog
Subject Fishy 🐟 in Scryer Prolog and SWI-Prolog (Was: Humans are just overwhelmed by computers)
Date 2025-07-16 20:08 +0200
Message-ID <1058pr2$2chtv$1@solani.org> (permalink)
References (2 earlier) <1055ki3$2abt8$1@solani.org> <1055kpn$2ac5o$1@solani.org> <1055l2j$2ac8t$1@solani.org> <10560b0$2ak4u$1@solani.org> <1058lp0$2cep9$1@solani.org>

Show all headers | View raw


Hi,

The same example values also create fishy 🐟
sorting using native sorting in Scryer Prolog:

/* Scryer Prolog 0.9.4-417 */
?- values([z,x,y], A), sort(A, B),
    values([x,y,z], C), sort(C, D), B == D.
    false. /* fishy 🐟 */

Or using native sorting in SWI-Prolog:

/* SWI-Prolog 9.3.25 */
?- values([z,x,y], A), sort(A, B),
    values([x,y,z], C), sort(C, D), B == D.
false. /* fishy 🐟 */

Bye

Mild Shock schrieb:
> 
>  > I checked that your examples are not counter
>  > examples for my compare_with_stack/3.
> 
> What makes you think the values I show, X, Y
> and Z, are possible in a total linear ordering?
> The values also break predsort/3, you can easily
> verify that sort([x,y,z]) =\= sort([y,x,z]):
> 
> value(x, X) :- X = X-0-9-7-6-5-4-3-2-1.
> value(y, Y) :- Y = Y-7-5-8-2-4-1.
> value(z, Z) :- H = H-9-7-6-5-4-3-2-1-0, Z = H-9-7-6-5-4-3-2-1.
> 
> values(L, R) :- maplist(value, L, R).
> 
> ?- values([x,y,z], A), predsort(compare_with_stack, A, B),
>  Β Β  values([y,x,z], C), predsort(compare_with_stack, C, D),
>  Β Β  B == D.
> false.
> 
> But expectation would be sort([x,y,z]) ==
> sort([y,x,z]) since sort/2 should be immune
> to permutation. If this isn’t enough proof that
> there is something fishy in compare_with_stack/3 ,
> 
> well then I don’t know, maybe the earth is indeed flat?

Back to comp.lang.prolog | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

The Ghosts in my Cabinet: Indexing Mild Shock <janburse@fastmail.fm> - 2025-07-10 12:45 +0200
  Observed while watching FAIL/REDO ports (Was: The Ghosts in my Cabinet: Indexing) Mild Shock <janburse@fastmail.fm> - 2025-07-10 12:46 +0200
    Shocking Revelation: No eGovernment can trust Prolog! (Was: Observed while watching FAIL/REDO ports) Mild Shock <janburse@fastmail.fm> - 2025-07-10 13:26 +0200
      Easier certification with 100% Prolog Prolog? (Was: Shocking Revelation: No eGovernment can trust Prolog!) Mild Shock <janburse@fastmail.fm> - 2025-07-10 14:05 +0200
        Doing a Prolog system without any iterator API (Was: Easier certification with 100% Prolog Prolog?) Mild Shock <janburse@fastmail.fm> - 2025-07-10 14:14 +0200
          The headache with JIT indexing: Native -> Prolog (Was: Doing a Prolog system without any iterator API) Mild Shock <janburse@fastmail.fm> - 2025-07-10 14:40 +0200
            Just lets burn another candle for Barty Boy (Was: The headache with JIT indexing: Native -> Prolog) Mild Shock <janburse@fastmail.fm> - 2025-07-10 18:13 +0200
              Physics PhDs might never have heard of Quantifier Eliminations (Re: Just lets burn another candle for Barty Boy) Mild Shock <janburse@fastmail.fm> - 2025-07-10 18:33 +0200
                How long willl I piss on Bart Demoen (Was: Physics PhDs might never have heard of Quantifier Eliminations) Mild Shock <janburse@fastmail.fm> - 2025-07-10 18:39 +0200
                But I shouldn't waste too much time (Was: How long willl I piss on Bart Demoen) Mild Shock <janburse@fastmail.fm> - 2025-07-10 19:13 +0200
  DCG is easily affected (Was: The Ghosts in my Cabinet: Indexing) Mild Shock <janburse@fastmail.fm> - 2025-07-11 09:38 +0200
    The headache an eGovernment might get from Prolog (Was: DCG is easily affected) Mild Shock <janburse@fastmail.fm> - 2025-07-15 15:20 +0200
      Wait till they find out about compare/3 (Was: The headache an eGovernment might get from Prolog) Mild Shock <janburse@fastmail.fm> - 2025-07-15 15:24 +0200
        Corr. (Was: Wait till they find out about compare/3) Mild Shock <janburse@fastmail.fm> - 2025-07-15 15:28 +0200
          eGovernements will need AGI to survive (Was: Corr. (Was: Wait till they find out about compare/3)) Mild Shock <janburse@fastmail.fm> - 2025-07-15 18:41 +0200
            Having 2544 issues is probably a bad sign (Re: eGovernements will need AGI to survive) Mild Shock <janburse@fastmail.fm> - 2025-07-15 18:41 +0200
              The Signal Collapse gives us System Uncertainty (Re: Having 2544 issues is probably a bad sign) Mild Shock <janburse@fastmail.fm> - 2025-07-15 19:02 +0200
                Rename GitHub, to TurdPit, and make Amber Heard their CEO (Was: The Signal Collapse gives us System Uncertainty) Mild Shock <janburse@fastmail.fm> - 2025-07-15 19:52 +0200
            Humans are just overwhelmed by computers (Was: eGovernements will need AGI to survive) Mild Shock <janburse@fastmail.fm> - 2025-07-16 18:59 +0200
              Fishy 🐟 in Scryer Prolog and SWI-Prolog (Was: Humans are just overwhelmed by computers) Mild Shock <janburse@fastmail.fm> - 2025-07-16 20:08 +0200
                So we are essentially all using Trojan Horses 🐎 daily? (Re: Fishy 🐟 in Scryer Prolog and SWI-Prolog) Mild Shock <janburse@fastmail.fm> - 2025-07-17 10:57 +0200
                Strudel Rust gives Scryer Frust πŸ’©: Try C+20 Pipes (Was: Fishy 🐟 in Scryer Prolog and SWI-Prolog( Mild Shock <janburse@fastmail.fm> - 2025-11-25 22:55 +0100
              SWI-Prolog as a Test Bed for Copilots (Was: Humans are just overwhelmed by computers) Mild Shock <janburse@fastmail.fm> - 2025-07-20 14:36 +0200
                Mathematics currently hates Computer Science because of AI (Re: SWI-Prolog as a Test Bed for Copilots) Mild Shock <janburse@fastmail.fm> - 2025-07-20 15:13 +0200

csiph-web