You can query with prolog
?- genotype(1,[2,1,2]),genotype(2,[1,2,1]).
true.
Not very helpful.
But query with scasp (note the ? op):
?- ? genotype(1,[2,1,2]),genotype(2,[1,2,1]).
#### s(CASP) model
* haplotype holds for [0, 1, 0]
* haplotype holds for [1, 0, 1]
* haplotype holds for [1, 1, 1]
* genotype holds for 1, and [2, 1, 2]
* genotype holds for 2, and [1, 2, 1]
* conflation holds for 1, 1, and 1
* conflation holds for 2, 0, and 1
* conflation_seq holds for [], [], and []
* conflation_seq holds for [1], [1], and [1]
* conflation_seq holds for [1, 2], [1, 0], and [1, 1]
* conflation_seq holds for [1, 2, 1], [1, 0, 1], and [1, 1, 1]
* conflation_seq holds for [2], [0], and [1]
* conflation_seq holds for [2, 1], [0, 1], and [1, 1]
* conflation_seq holds for [2, 1, 2], [0, 1, 0], and [1, 1, 1]
#### s(CASP) justification
Expand All +1 -1 Collapse All
* genotype holds for 1, and [2, 1, 2], because
* haplotype holds for [0, 1, 0], and
* haplotype holds for [1, 1, 1], and
* conflation_seq holds for [2, 1, 2], [0, 1, 0], and [1, 1, 1], because
Also, can conflation_seq/3 be changed out for one of the predicates from library(apply), or does using s(CASP) cause problems?
Not sure, I had to redefine some basic predicates before so just keeping it simple.