%% Copyright (C) 2017, 2019, 2020, 2021, 2022 %% Dennis J. Darland %% This file is part of darland's philosophy. %% darland's philosophy is free software: you can redistribute it and/or modify %% it under the terms of the GNU General Public License as published by %% the Free Software Foundation, either version 3 of the License, or %% (at your option) any later version. %% darland's philosophy is distributed in the hope that it will be useful, %% but WITHOUT ANY WARRANTY; without even the implied warranty of %% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the %% GNU General Public License for more details. %% You should have received a copy of the GNU General Public License %% along with darland's philosophy. If not, see . %% Common Prolog & Life predicates to simulate Dennis J. Darlands philosophy. %% Started Writing 1/4/2017 %% This is a total rewrite of what I started about 10 years ago. %% %% %% I have made the conceptual feeling relatons support arbitrary arity. %% %% qqqq(actual_entity, X) :- qqqq(actual_occasion, X). qqqq(eternal_object, X) :- qqqq(defining_characteristic, X). qqqq(defining_characteristic, X) :- qqqq(personal_order, X). qqqq(defining_characteristic, X) :- qqqq(social_order, X). qqqq(god, primordial_nature, EO) :- find_all(X, eternal_object(X), EO). qqqq(god, superjective_nature, AO) :- find_all(X, actual_occasion(X), AO). qqqq(god, consequent_nature, Novelty) :- Novelty = random(10000). qqqq(society, Dc, N) :- qqqq(social_order, Dc), qqqq(nexus, Dc, N). qqqq(person, Dc, N) :- qqqq(personal_order, Dc), qqqq(nexus, Dc, N). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% Define sense (close to Frege's Sinn) (useless) %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% qqqq(sense_of_relation, Idea) :- qqqq(ssss, Subject, Time, Idea, Relation). qqqq(sense_of_object, Idea) :- qqqq(ssss, Subject, Time, Idea, Object). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% qqqq is the only relation having ontological status. %% qqqq is the exemplification of a universal in the following arguments. %% I define some other WildLIFE predicates (relations), %% however, these theoretically could all be eliminated. %% as in the predicate pred(Arg1, Arg2, ...) %% by %% qqqq(Pred, Arg1, Arg2, ...) :- %% Pred = pred, %% ... %% I also use qqqq4 for positive [base] facts. %% I also use qqqq5 for negative [base] facts. %% This is to avoid conflict with qqqq. %% A script qqqq_pre_all.sh translates %% fact and query files %% using a Unicon program qqqq_pre.icn %% converting the qqqq predicates %% to the predicates in the rules files. %% This is done only for efficiency. %% some possible arguments (eternal objects) %% are rrrr, ssss, and rrss. %% rrss is defined in terms of rrrr and ssss. %% rrrr and ssss are undefined here %% - but not necessarily ontologically primitive %% - rrrr, ssss, and tttt are a %% persons conceptual prehensions (ideas) of %% defining characteristics (eternal objects) %% of words and objects. %% rrrr is relation between word and idea. %% ssss is relation between idea and one object. %% tttt is relation between idea and one or more objects. %% rrss is relative product of rrrr and ssss. %% rrtt is relative product of rrrr and tttt. %% also there are ssss2 and tttt2 %% ssss2 checks uniqueness - %% if the database is correct it should nnot be needed. %% uniqueness is essential to essentially singular ideas %% So it is required even for %% understanding or belief if ssss is used qqqq(corefer, [Head1 | Tail1], [Head2 | Tail2]) :- qqqq(corefer, Head1, Head2), qqqq(corefer, Tail1, Tail2). qqqq(corefer, Head1, Head2) :- \+ qqqq(differ_refer, Head1, Head2). qqqq(differ_refer, Head1, Head2) :- qqqq(refer, [Head1, X]), \+ qqqq(refer, [Head2, X]). qqqq(differ_refer, Head2, Head1) :- qqqq(refer, [Head1, X]), \+ qqqq(refer, [Head2, X]). qqqq(ssss2, Subject, Time, Idea, Object) :- qqqq(ssss, Subject, Time, Idea, Object), \+ qqqq(non_unique, Subject, Time, Idea, Object). qqqq(non_unique, Subject, Time, Idea, Object1) :- qqqq(ssss, Subject, Time, Idea, Object2), \+ qqqq(corefer, Object1, Object2). %% tttt2 also requires uniqueness %% this uniqueness is for contingently singular ideas qqqq(tttt2, Subject, Time, Idea, Object) :- qqqq(tttt, Subject, Time, Idea, Object), \+ qqqq(non_unique_t, Subject, Time, Idea, Object). qqqq(non_unique_t, Subject, Time, Idea, Object1) :- qqqq(tttt, Subject, Time, Idea, Object2), \+ qqqq(corefer, Object1, Object2). %% definition of rrss in terms of rrrr and ssss. %% Note: qqqq is a dynamic predicate in WildLIFE %% - so it can be extended. qqqq(rrss, Subject, Time, Word, Object) :- qqqq(rrrr, Subject, Time, Word, Idea), qqqq(ssss2, Subject, Time, Idea, Object). %% definition of rrss in terms of rrrr and ssss. %% Note: qqqq is a dynamic predicate in WildLIFE %% - so it can be extended. qqqq(rrtt, Subject, Time, Word, Object) :- qqqq(rrrr, Subject, Time, Word, Idea), qqqq(tttt, Subject, Time, Idea, Object). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% There are 7 relations of understanding. %% Those of understanding are defined in terms %% of rrrr and ssss %% The 7 cases are: %% 1 words %% 2 ideas %% 3 objects %% 4 words_ideas %% 5 words_objects %% 6 ideas_objects %% 7 words_ideas_objects %% Modified to add Number to ideas %% - singular %% - or plural %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% understands_words is defined. %% It applies to an intelligent Subject at some Time. %% There is a list of words. %% The arity_idea must match the number of words %% following the relation word. %% (Or an arity_relation of -999 matches %% any number of words.) %% The type ideas corresponding to the relata must be %% one less than the type %% idea of the relation idea. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% 1 %% I am going to comment on one sample carefully %% and thoroughly I hope. %% I hope any reader can learn enough %% to apply principles in other cases. %% predicate1(Arg1, Arg2, Arg3) :- predicate2(Arg1, Arg2), %% predicate3(Arg1, Arg3).' %% means if predicate3(Arg1, Arg2) %% and predicate3(Arg1, Arg3) %% then predicate1(Arg1, Arg2, Arg3). %% ":-" means "if" %% "," separates Arguments in predicates %% it means "and" between clauses. %% %% Two rules can be used for "or" %% if we add %% predicate1(Arg1, Arg2, Arg3) :- predicate4(Arg1, Arg2), %% predicate5(Arg1, Arg3). %% then we have: %% if (predicate3(Arg1, Arg2) and predicate3(Arg1, Arg3)) %% or (predicate4(Arg1, Arg2) and predicate5(Arg1, Arg3)) %% then predicate1(Arg1, Arg2, Arg3). %% "\+" is negation by "failure" %% (if it cannot see it is true is says false) %% I also use qqqq4 to state positive facts %% in the database. %% and qqqq5 to state negative facts in the database. %% match_word below is recursive. Each call %% removes a Word. %% It also subtracts one from the Arity of the %% Relation_Idea. %% The list is finite in WildLIFE, so eventually %% there will be an empty list and the Arity can be %% checked. (or be -999) %% It also checks if the Ideas are one less in type %% than the Relation Idea. %% rrrr sees if the Subject has that relation %% between the Word and the Idea. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %%%%%%%%%%%%%%FIRST TEST ROUTINES %%%%%%%%%%%%%%%%%%% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% 1 qqqq(test_sa_words, Subject, Time, Subjective_aim) :- qqqq(should_sa_words, Subject, Time, Subjective_aim, List), qqqq(conceptual_feeling_words, Subject, Subjective_aim, Time, List), qqqq(write, "**1A** ", Subjective_aim, " [and should] words ", List). qqqq(test_sa_words,Subject, Time, Subjective_aim) :- qqqq(should_sa_words, Subject, Time, Subjective_aim, List), \+ qqqq(conceptual_feeling_words, Subject, Subjective_aim, Time, List), qqqq(write, "**1B** ", Subjective_aim, " not [BUT should] words ", List). qqqq(test_not_sa_words, Subject, Time, Subjective_aim) :- qqqq(should_not_sa_words, Subject, Time, Subjective_aim, List), \+ qqqq(conceptual_feeling_words, Subject, Subjective_aim, Time, List), qqqq(write, "**1C** ", Subjective_aim, " not [and should not] words ", List). qqqq(test_not_sa_words, Subject, Time, Subjective_aim) :- qqqq(should_not_sa_words, Subject, Time, Subjective_aim, List), qqqq(conceptual_feeling_words, Subject, Subjective_aim, Time, List), qqqq(write, "**1D** ", Subjective_aim, " [BUT should not] words ", List). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% 2 qqqq(ideas_list, Subject, [Ideas_head]) :- qqqq(idea_of, Subject, Ideas_head). qqqq(ideas_list, Subject, [Ideas_head | Ideas_tail]) :- qqqq(idea_of, Subject, Ideas_head), qqqq(ideas_list, Subject, Ideas_tail). qqqq(test_sa_ideas, Subject, Time, Subjective_aim) :- qqqq(should_sa_ideas, Subject, Time, Subjective_aim, List), qqqq(conceptual_feeling_in_ideas,Subject, Subjective_aim, Time, List), qqqq(ideas_list, Subject, List), qqqq(write, "**2A** ", Subjective_aim, " [and should] ideas ", List). qqqq(test_sa_ideas, Subject, Time, Subjective_aim) :- qqqq(write, "2B", Subject, Time, Subjective_aim),nl, qqqq(should_sa_ideas, Subject, Time, Subjective_aim, List), qqqq(write,"2BB", List),nl, \+ qqqq(conceptual_feeling_in_ideas, Subject, Subjective_aim, Time, List), qqqq(write, "2BBB", List),nl, qqqq(ideas_list, Subject, List), qqqq(write, "**2B** ", Subjective_aim, " not [BUT should] ideas ", List). qqqq(test_not_sa_ideas, Subject, Time, Subjective_aim) :- qqqq(should_not_sa_ideas, Subject, Time, Subjective_aim, List), \+ qqqq(conceptual_feeling_in_ideas, Subject, Subjective_aim, Time, List), qqqq(ideas_list, Subject, List), qqqq(write, "**2C** ", Subjective_aim, " not [and should not] ideas ", List). qqqq(test_not_sa_ideas, Subject, Time, Subjective_aim) :- qqqq(should_not_sa_ideas, Subject, Time, Subjective_aim, List), qqqq(conceptual_feeling_in_ideas, Subject, Subjective_aim, Time, List), qqqq(ideas_list, Subject, List), qqqq(write, "**2D** ", Subjective_aim, " [BUT should not] ideas ", List). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% 3 qqqq(test_sa_objects, Subject, Time, Subjective_aim) :- qqqq(should_sa_objects, Subject, Time, Subjective_aim, List), qqqq(conceptual_feeling_objects, Subject, Subjective_aim, Time, List), qqqq(write, "**3A** ", Subjective_aim, " [and should] objects ", List). qqqq(test_sa_objects, Subject, Time, Subjective_aim) :- qqqq(should_sa_objects, Subject, Time, Subjective_aim, List), \+ qqqq(conceptual_feeling_objects, Subject, Subjective_aim, Time, List), qqqq(write, "**3B** ", Subjective_aim, " not [BUT should] objects ",List). qqqq(test_not_sa_objects, Subject, Time, Subjective_aim) :- qqqq(should_not_sa_objects, Subject, Time, Subjective_aim, List), \+ qqqq(conceptual_feeling_objects, Subject, Subjective_aim, Time, List), qqqq(write, "**3C** ", Subjective_aim, " not [and should not] objects ", List). qqqq(test_not_sa_objects, Subject, Time, Subjective_aim) :- qqqq(should_not_sa_objects, Subject, Time, Subjective_aim, List), qqqq(conceptual_feeling_objects, Subject, Subjective_aim, Time, List), qqqq(write, "**3D** ", Subjective_aim, " [BUT should not] objects ", List). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% 4 qqqq(test_sa_words_ideas, Subject, Time, Subjective_aim) :- qqqq(should_sa_words_ideas, Subject, Time, Subjective_aim, List), qqqq(conceptual_feeling_words_ideas, Subject, Subjective_aim, Time, List), qqqq(write, "**4A** ", Subjective_aim, " [and should] words_ideas ", List). qqqq(test_sa_words_ideas, Subject, Time, Subjective_aim) :- qqqq(should_sa_words_ideas, Subject, Time, Subjective_aim, List), \+ qqqq(conceptual_feeling_words_ideas, Subject, Subjective_aim, Time, List), qqqq(write, "**4B** ", Subjective_aim, " not [BUT should] words_ideas ",List). qqqq(test_not_sa_words_ideas, Subject, Time, Subjective_aim) :- qqqq(should_not_sa_words_ideas, Subject, Time, Subjective_aim, List), \+ qqqq(conceptual_feeling_words_ideas, Subject, Subjective_aim, Time, List), qqqq(write, "**4C** ", Subjective_aim, " not [and should not] words_ideas ", List). qqqq(test_not_sa_words_ideas, Subject, Time, Subjective_aim) :- qqqq(should_not_sa_words_ideas, Subject, Time, Subjective_aim, List), qqqq(conceptual_feeling_words_ideas, Subject, Subjective_aim, Time, List), qqqq(write, "**4D**", Subjective_aim, " words_ideas [BUT should not] ", List). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% 5 qqqq(test_sa_words_objects, Subject, Time, Subjective_aim) :- qqqq(should_sa_words_objects, Subject, Time, Subjective_aim, List), qqqq(conceptual_feeling_words_objects, Subject, Subjective_aim, Time, List), qqqq(write, "**5A** ", Subjective_aim, " [and should] words_objects ", List). qqqq(test_sa_words_objects, Subject, Time, Subjective_aim) :- qqqq(should_sa_words_objects, Subject, Time, Subjective_aim, List), \+ qqqq(conceptual_feeling_words_objects,Subject, Subjective_aim, Time, List), qqqq(write, "**5B** ", Subjective_aim, " not [BUT should] words_objects ",List). qqqq(test_not_sa_words_objects, Subject, Time, Subjective_aim) :- qqqq(should_not_sa_words_objects, Subject, Time, Subjective_aim, List), \+ qqqq(conceptual_feeling_words_objects, Subject, Subjective_aim, Time, List), qqqq(write, "**5C** ", Subjective_aim, " not [and should not] words_objects ", List). qqqq(test_not_sa_words_objects, Subject, Time, Subjective_aim) :- qqqq(should_not_sa_words_objects, Subject, Time, Subjective_aim, List), qqqq(conceptual_feeling_words_objects, Subject, Subjective_aim, Time, List), qqqq(write, "**5D** ", Subjective_aim, " [BUT should not] words_objects ", List). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% 6 qqqq(test_sa_ideas_objects, Subject, Time, Subjective_aim) :- qqqq(should_sa_ideas_objects, Subject, Time, Subjective_aim, List), qqqq(conceptual_feeling_ideas_objects, Subject, Subjective_aim, Time, List), qqqq(write, "**6A** ", Subjective_aim, " [and should] ideas_objects ", List). qqqq(test_sa_ideas_objects, Subject, Time, Subjective_aim) :- qqqq(should_sa_ideas_objects, Subject, Time, Subjective_aim, List), \+ qqqq(conceptual_feeling_ideas_objects, Subject, Subjective_aim, Time, List), qqqq(write, "**6B** ", Subjective_aim, " not [BUT should] ideas_objects ", List). qqqq(test_not_sa_ideas_objects, Subject, Time, Subjective_aim) :- qqqq(should_not_sa_ideas_objects, Subject, Time, Subjective_aim, List), \+ qqqq(conceptual_feeling_ideas_objects, Subject, Subjective_aim, Time, List), qqqq(write, "**6C** ", Subjective_aim, " not [and should not] ideas_objects ", List). qqqq(test_not_sa_ideas_objects, Subject, Time, Subjective_aim) :- qqqq(should_not_sa_ideas_objects, Subject, Time, Subjective_aim, List), qqqq(conceptual_feeling_ideas_objects, Subject, Subjective_aim, Time, List), qqqq(write, "**6D** ", Subjective_aim, " [BUT should not] ideas_objects ", List). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% 7 qqqq(test_sa_words_ideas_objects, Subject, Time, Subjective_aim) :- qqqq(should_sa_words_ideas_objects, Subject, Time, Subjective_aim, List), qqqq(conceptual_feeling_words_ideas_objects, Subject, Subjective_aim, Time, List), qqqq(write, "**7A** ", Subjective_aim, " [and should] words_ideas_objects ", List). qqqq(test_sa_words_ideas_objects, Subject, Time, Subjective_aim) :- qqqq(should_sa_words_ideas_objects, Subject, Time, Subjective_aim, List), \+ qqqq(conceptual_feeling_words_ideas_objects, Subject, Subjective_aim, Time, List), qqqq(write, "**7B** ", Subjective_aim, " not [BUT should] words_ideas_objects ",List). qqqq(test_not_sa_words_ideas_objects, Subject, Time, Subjective_aim) :- qqqq(should_not_sa_words_ideas_objects, Subject, Time, Subjective_aim, List), \+ qqqq(conceptual_feeling_words_ideas_objects, Subject, Subjective_aim, Time, List), qqqq(write, "**7C** ", Subjective_aim, " not and should not words_ideas_objects ", List). qqqq(test_not_sa_words_ideas_objects, Subject, Time, Subjective_aim) :- qqqq(should_not_sa_words_ideas_objects, Subject, Time, Subjective_aim, List), qqqq(conceptual_feeling_words_ideas_objects, Subject, Subjective_aim, Time, List), qqqq(write, "**7D** ", Subjective_aim, " [BUT should not] words_ideas_objects", List). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% NEXT understanding RULES %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% 1 qqqq(conceptual_feeling_words, Subject, Subjective_aim, Time, [[Relation_Word] | List]) :- Subjective_aim :== understands, qqqq(rrrr, Subject, Time, Relation_Word, Relation_Idea), qqqq(person, Subject), qqqq(arity_idea, Relation_Idea, Arity), qqqq(type_idea, Relation_Idea, Type), % List of Words. % Objects should be Type one less than Type of Relation qqqq(match_word, Subject, Subjective_aim, Time, List, Arity, Type - 1). %% The following are auxilary predicates. %% - they have no ontological significance. qqqq(match_word, Subject, Subjective_aim, Time, [], 0, Type). %% -999 indicates arbitrary arity. qqqq(match_word, Subject, Subjective_aim, Time, [], -999, Type). qqqq(match_word, Subject, Subjective_aim, Time, [[Word] | List], Arity, Type) :- % List of Word Object Pairs. qqqq(rrrr, Subject, Time, Word, Idea), qqqq(type_idea, Idea, Type), qqqq(match_word, Subject, Subjective_aim, Time, List, % if Arity is not Arbitrary sub 1 qqqq(cond, Arity =\= -999, Arity - 1, -999), Type). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% The following are other forms of understanding. %% I could copy, paste & edit the comments. %% But I will rely on the readers intelligence. %% It is better to be sure the above is correct. %% And to reduce the amount of editing if there %% are changes. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% 2 qqqq(conceptual_feeling_in_ideas, Subject, Subjective_aim, Time, [[Relation_Idea] | List]) :- Subjective_aim :== understands, qqqq(number_idea, Relation_Idea, singular), qqqq(arity_idea, Relation_Idea, Arity), qqqq(type_idea, Relation_Idea, Type), % List of Ideas. % Objects should be Type one less than Type of Relation qqqq(match_idea, Subject, Subjective_aim, Time, List, Arity, Type - 1). qqqq(conceptual_feeling_in_ideas, Subject, Subjective_aim, Time, [[Relation_Idea] | List]) :- qqqq(number_idea, Relation_Idea, plural), qqqq(arity_idea, Relation_Idea, Arity), qqqq(type_idea, Relation_Idea, Type), % List of Ideas. % Objects should be Type one less than Type of Relation qqqq(match_idea, Subject, Subjective_aim, Time, List, Arity, Type - 1). %% The following are auxilary predicates - they have no ontological %% Significance. qqqq(match_idea, Subject, Subjective_aim, Time, [], 0, Type). %% -999 indicates arbitrary arity. qqqq(match_idea, Subject, Subjective_aim, Time, [], -999, Type). qqqq(match_idea, Subject, Subjective_aim, Time, [[Idea] | List], Arity, Type) :- % List of Word Object Pairs. qqqq(number_idea, Idea, singular), qqqq(type_idea, Idea, Type), qqqq(match_idea, Subject, Subjective_aim, Time, List, % if Arity is not Arbitrary sub 1 qqqq(cond, Arity =\= -999, Arity - 1, -999), Type). qqqq(match_idea, Subject, Subjective_aim, Time, [[Idea] | List], Arity, Type) :- % List of Word Object Pairs. qqqq(number_idea, Idea, plural), qqqq(type_idea, Idea, Type), qqqq(match_idea, Subject, Subjective_aim, Time, List, % if Arity is not Arbitrary sub 1 qqqq(cond, Arity =\= -999, Arity - 1, -999), Type). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% 3 qqqq(conceptual_feeling_objects, Subject, Subjective_aim, Time, [[Relation] | List]) :- Subjective_aim :== understands, qqqq(number_idea, Relation_Idea, singular), qqqq(ssss2, Subject, Time, Relation_Idea, Relation), qqqq(arity_idea, Relation_Idea, Arity), qqqq(type_idea, Relation_Idea, Type), % List of Ideas. % Objects should be Type one less than % Type of Relation qqqq(match_object, Subject, Subjective_aim, Time, List, Arity, Type - 1). qqqq(conceptual_feeling_objects, Subject, Subjective_aim, Time, [[Relation] | List]) :- Subjective_aim :== understands, qqqq(number_idea, Relation_Idea, plural), qqqq(tttt, Subject, Time, Relation_Idea, Relation), qqqq(arity_idea, Relation_Idea, Arity), qqqq(type_idea, Relation_Idea, Type), % List of Ideas. % Objects should be Type one less than % Type of Relation qqqq(match_object, Subject, Subjective_aim, Time, List, Arity, Type - 1). %% The following are auxilary predicates %%- they have no ontological Significance. qqqq(match_object, Subject, Subjective_aim, Time, [], 0, Type). %% -999 indicates arbitrary arity. qqqq(match_object, Subject, Subjective_aim, Time, [], -999, Type). qqqq(match_object, Subject, Subjective_aim, Time, [[Object] | List], Arity, Type) :- % List of Word Object Pairs. qqqq(number_idea, Idea, singular), qqqq(ssss2, Subject, Time, Idea, Object), qqqq(type_idea, Idea, Type), qqqq(match_object, Subject, Subjective_aim, Time, List, % if Arity is not Arbitrary sub 1 qqqq(cond, Arity =\= -999, Arity - 1, -999), Type). qqqq(match_object, Subject, Subjective_aim, Time, [[Object] | List], Arity, Type) :- % List of Word Object Pairs. qqqq(number_idea, Idea, plural), qqqq(tttt, Subject, Time, Idea, Object), qqqq(type_idea, Idea, Type), qqqq(match_object, Subject, Subjective_aim, Time, List, % if Arity is not Arbitrary sub 1 qqqq(cond, Arity =\= -999, Arity - 1, -999), Type). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% 4 qqqq(conceptual_feeling_words_ideas, Subject, Subjective_aim, Time, [[Relation_Word, Relation_Idea] | PairList]) :- Subjective_aim :== understands, qqqq(rrrr, Subject, Time, Relation_Word, Relation_Idea), qqqq(arity_idea, Relation_Idea, Arity), qqqq(type_idea, Relation_Idea, Type), % List of Word Object Pairs. % Objects should be Type one less than Type of Relation qqqq(match_pair_word_idea, Subject, Subjective_aim, Time, PairList, Arity, Type - 1). %% The following are auxilary predicates %% - they have no ontological Significance. qqqq(match_pair_word_idea, Subject, Subjective_aim, Time, [], 0, Type). %% -999 indicates arbitrary arity. qqqq(match_pair_word_idea, Subject, Subjective_aim, Time, [], -999, Type). qqqq(match_pair_word_idea, Subject, Subjective_aim, Time, [[Word, Idea] | PairList], Arity, Type) :- % List of Word Object Pairs. qqqq(rrrr, Subject, Time, Word, Idea), qqqq(type_idea, Idea, Type), qqqq(match_pair_word_idea, Subject, Subjective_aim, Time, PairList, % if Arity is not % Arbitrary sub 1 qqqq(cond, Arity =\= -999, Arity - 1, -999), Type). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% 5 qqqq(conceptual_feeling_words_objects, Subject, Subjective_aim, Time, [[Relation_Word, Relation] | PairList]) :- Subjective_aim :== understands, qqqq(rrrr, Subject, Time, Relation_Word, Relation_Idea), qqqq(number_idea, Relation_Idea, singular), qqqq(ssss2, Subject, Time, Relation_Idea, Relation), qqqq(arity_idea, Relation_Idea, Arity), qqqq(type_idea, Relation_Idea, Type), % List of Word Object Pairs. % Objects should be Type one less than % Type of Relation qqqq(match_pair_word_object, Subject, Subjective_aim, Time, PairList, Arity, Type - 1). qqqq(conceptual_feeling_words_objects, Subject, Subjective_aim, Time, [[Relation_Word, Relation] | PairList]) :- Subjective_aim :== understands, qqqq(rrrr, Subject, Time, Relation_Word, Relation_Idea), qqqq(number_idea, Relation_Idea, plural), qqqq(tttt, Subject, Time, Relation_Idea, Relation), qqqq(arity_idea, Relation_Idea, Arity), qqqq(type_idea, Relation_Idea, Type), % List of Word Object Pairs. % Objects should be Type one less than Type of Relation qqqq(match_pair_word_object, Subject, Subjective_aim, Time, PairList, Arity, Type - 1). %% The following are auxilary predicates %% - they have no ontological Significance. qqqq(match_pair_word_object, Subject, Subjective_aim, Time, [], 0, Type). %% -999 indicates arbitrary arity. qqqq(match_pair_word_object, Subject, Subjective_aim, Time, [], -999, Type). qqqq(match_pair_word_object, Subject, Subjective_aim, Time, [[Word, Object] | PairList], Arity, Type) :- % List of Word Object Pairs. qqqq(rrrr, Subject, Time, Word, Idea), qqqq(number_idea, Idea, singular), qqqq(ssss2, Subject, Time, Idea, Object), qqqq(type_idea, Idea, Type), qqqq(match_pair_word_object, Subject, Subjective_aim, Time, PairList, % if Arity is % not Arbitrary sub 1 qqqq(cond, Arity =\= -999, Arity - 1, -999), Type). qqqq(match_pair_word_object, Subject, Subjective_aim, Time, [[Word, Object] | PairList], Arity, Type) :- % List of Word Object Pairs. qqqq(rrrr, Subject, Time, Word, Idea), qqqq(number_idea, Idea, plural), qqqq(tttt, Subject, Time, Idea, Object), qqqq(type_idea, Idea, Type), qqqq(match_pair_word_object, Subject, Subjective_aim, Time, PairList, % if Arity is % not Arbitrary sub 1 qqqq(cond, Arity =\= -999, Arity - 1, -999), Type). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% 6 qqqq(conceptual_feeling_ideas_objects, Subject, Subjective_aim, Time, [[Relation_Idea, Relation] | PairList]) :- Subjective_aim :== understands, % List of Word Object Pairs. qqqq(number_idea, Relation_Idea, singular), qqqq(ssss2, Subject, Time, Relation_Idea, Relation), qqqq(arity_idea, Relation_Idea, Arity), qqqq(type_idea, Relation_Idea, Type), qqqq(match_pair_idea_object_relation, Subject, Subjective_aim, Time, PairList, Arity, Type - 1). qqqq(conceptual_feeling_ideas_objects, Subject, Subjective_aim, Time, [[Relation_Idea, Relation] | PairList]) :- Subjective_aim :== understands, % List of Word Object Pairs. qqqq(number_idea, Relation_Idea, plural), qqqq(tttt, Subject, Time, Relation_Idea, Relation), qqqq(arity_idea, Relation_Idea, Arity), qqqq(type_idea, Relation_Idea, Type), qqqq(match_pair_idea_object_relation, Subject, Subjective_aim, Time, PairList, Arity, Type - 1). qqqq(match_pair_idea_object_relation, Subject, Subjective_aim, Time, [], -999, Type). qqqq(match_pair_idea_object_relation, Subject, Subjective_aim, Time, [], 0, Type). qqqq(match_pair_idea_object_relation, Subject, Subjective_aim, Time, [[Idea, Object] | PairList], Arity, Type) :- % List of Word Object Pairs. qqqq(number_idea, Idea, singular), qqqq(ssss2, Subject, Time, Idea, Object), qqqq(type_idea, Idea, Type), qqqq(match_pair_idea_object_relation, Subject, Subjective_aim, Time, PairList, % if Arity is % not Arbitrary % sub 1 qqqq(cond, Arity =\= -999, Arity - 1, -999), Type). qqqq(match_pair_idea_object_relation, Subject, Subjective_aim, Time, [[Idea, Object] | PairList], Arity, Type) :- % List of Word Object Pairs. qqqq(number_idea, Idea, plural), qqqq(tttt, Subject, Time, Idea, Object), qqqq(type_idea, Idea, Type), qqqq(match_pair_idea_object_relation, Subject, Subjective_aim, Time, PairList, % if Arity is % not Arbitrary % sub 1 qqqq(cond, Arity =\= -999, Arity - 1, -999), Type). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% 7 qqqq(conceptual_feeling_words_ideas_objects, Subject, Subjective_aim, Time, [[Relation_Word, Relation_Idea, Relation] | TripleList]) :- Subjective_aim :== understands, % List of Word Idea_Object Triples. qqqq(rrrr, Subject, Time, Relation_Word, Relation_Idea), qqqq(number_idea, Relation_Idea, singular), qqqq(ssss2, Subject, Time, Relation_Idea, Relation), qqqq(arity_idea, Relation_Idea, Arity), qqqq(type_idea, Relation_Idea, Type), qqqq(match_triple_word_idea_object_relation, Subject, Subjective_aim, Time, TripleList,Arity, Type - 1). qqqq(conceptual_feeling_words_ideas_objects, Subject, Subjective_aim, Time, [[Relation_Word, Relation_Idea, Relation] | TripleList]) :- Subjective_aim :== understands, % List of Word Idea_Object Triples. qqqq(rrrr, Subject, Time, Relation_Word, Relation_Idea), qqqq(number_idea, Relation_Idea, plural), qqqq(tttt, Subject, Time, Relation_Idea, Relation), qqqq(arity_idea, Relation_Idea, Arity), qqqq(type_idea, Relation_Idea, Type), qqqq(match_triple_word_idea_object_relation, Subject, Subjective_aim, Time, TripleList, Arity, Type - 1). qqqq(match_triple_word_idea_object_relation, Subject, Subjective_aim, Time, [], 0, Type). %% -999 indicates arbitrary arity. qqqq(match_triple_word_idea_object_relation, Subject, Subjective_aim, Time, [], -999, Type). qqqq(match_triple_word_idea_object_relation, Subject, Subjective_aim, Time, [[Word, Idea, Object] | TripleList], Arity, Type) :- % List of Word Idea Object Triple. qqqq(rrrr, Subject, Time, Word, Idea), qqqq(number_idea, Idea, singular), qqqq(ssss2, Subject, Time, Idea, Object), qqqq(type_idea, Idea, Type), qqqq(match_triple_word_idea_object_relation, Subject, Subjective_aim, Time, TripleList, cond(Arity =\= -999 , Arity - 1, -999), Type). qqqq(match_triple_word_idea_object_relation, Subject, Subjective_aim, Time, [[Word, Idea, Object] | TripleList], Arity, Type) :- % List of Word Idea Object Triple. qqqq(rrrr, Subject, Time, Word, Idea), qqqq(number_idea, Idea, plural), qqqq(tttt, Subject, Time, Idea, Object), qqqq(type_idea, Idea, Type), qqqq(match_triple_word_idea_object_relation, Subject, Subjective_aim, Time, TripleList, cond(Arity =\= -999, Arity - 1, -999), Type). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% The FOLLOWING are NOT USED currently understand_same_objects_by_ideas( Subject_1, Time_1, [[Idea_1, Object_1] | Pair_List1], Subject_2, Time_2, [[Idea_2, Object_2] | Pair_List2]) :- % List of Word Object Pairs. ssss2( Subject_1, Time_1, Idea_1, Object_1), ssss2( Subject_2, Time_2, Idea_2, Object_2), Object_1 = Object2, match_same_pair_idea_object_relation(Subject_1, Time_1, Pair_List1, Subject_2, Time_2, Pair_List2). match_same_pair_idea_object_relation(Subject_1, Time_1, [], Subject_2, Time_2, []). match_same_pair_idea_object_relation(Subject_1, Time_1, [[Idea_1 , Object_1] | Pair_List1], Subject_2, Time_2, [[Idea_2 , Object_2] | Pair_List2]) :- % List of Word Object Pairs. ssss2( Subject_1, Time_1, Idea_1, Object_1), ssss2( Subject_2, Time_2, Idea_2, Object_2), Object_1 = Object2, match_same_pair_idea_object_relation(Subject_1, Time_1, Pair_List1, Subject_2, Time_2, Pair_List2). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% understand_same_objects_by_words( Subject_1, Time_1, Pair_List1, Subject_2, Time_2, Pair_List2) :- % List of Word Object Pairs. match_same_pair_word_object_relation(Subject_1, Time_1, Pair_List1, Subject_2, Time_2, Pair_List2). match_same_pair_word_object_relation(Subject_1, Time_1, [], Subject_2, Time_2, []). match_same_pair_word_object_relation(Subject_1, Time_1, [[Word_1 , Object_1] | Pair_List1], Subject_2, Time_2, [[Word_2 , Object_2] | Pair_List2]) :- % List of Word Object Pairs. rrss( Subject_1, Time_1, Word_1, Object_1), rrss( Subject_2, Time_2, Word_2, Object_2), Word_1 = Word_2, Object_1 = Object_2, match_same_pair_word_object_relation(Subject_1, Time_1, Pair_List1, Subject_2, Time_2, Pair_List2). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% The following is very preliminary. %% I need to go over it all again. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% Rules on Philosophical Terminology %% DEBUG VERSION %% pl_external_synonym_simple_expanded(Number, Philosopher_1, Philosopher_2, External_Term_1, External_Term_2, Quote_1, Author_1, Author_Article_1, Author_Book_1, Article_Title_1, Book_Title_1, Pages_1, Quotation_1, Article_Year_1, Book_Year_1, Note1, Notes_Article_1, Notes_Book_1, Quote_2, Author_2, Author_Article_2, Author_Book_2, Article_Title_2, Book_Title_2, Pages_2, Quotation_2, Article_Year_2, Book_Year_2, Note2, Notes_Article_2, Notes_Book_2, Quote_3, Author_3, Author_Article_3, Author_Book_3, Article_Title_3, Book_Title_3, Pages_3, Quotation_3, Article_Year_3, Book_Year_3, Note3, Notes_Article_3, Notes_Book_3, Quote_4, Author_4, Author_Article_4, Author_Book_4, Article_Title_4, Book_Title_4, Pages_4, Quotation_4, Article_Year_4, Book_Year_4, Note4, Notes_Article_4, Notes_Book_4) :- write(['A0001']), nl, term(External_Term_1), write(['A0002']), nl, term(External_Term_2), write(['A0003', Number, External_Term_1, External_Term_2]), nl, pl_external_synonym(Number, Philosopher_1, Philosopher_2, External_Term_1, External_Term_2, Quote_1, Quote_2, Quote_3, Quote_4), quote_note(Quote_1, Author_1, Author_Article_1, Author_Book_1, Article_Title_1, Book_Title_1, Pages_1, Quotation_1, Article_Year_1, Book_Year_1, Note1, Notes_Article_1, Notes_Book_1), write(['A0004', Number, Philosopher_1, Philosopher_2, External_Term_1, External_Term_2, Quote_1, Quote_2, Quote_3, Quote_4 ]), nl, quote_note(Quote_2, Author_2, Author_Article_2, Author_Book_2, Article_Title_2, Book_Title_2, Pages_2, Quotation_2, Article_Year_2, Book_Year_2, Note2, Notes_Article_2, Notes_Book_2), write(['A0005', Quote_2, Author_2, Author_Article_2, Author_Book_2, Article_Title_2, Book_Title_2, Pages_2, Quotation_2, Article_Year_2, Book_Year_2, Note2, Notes_Article_2, Notes_Book_2] ), nl, quote_note(Quote_3, Author_3, Author_Article_3, Author_Book_3, Article_Title_3, Book_Title_3, Pages_3, Quotation_3, Article_Year_3, Book_Year_3, Note3, Notes_Article_3, Notes_Book_3), write(['A0006', Quote_3, Author_3, Author_Article_3, Author_Book_3, Article_Title_3, Book_Title_3, Pages_3, Quotation_3, Article_Year_3, Book_Year_3, Note3, Notes_Article_3, Notes_Book_3]), nl, quote_note(Quote_4, Author_4, Author_Article_4, Author_Book_4, Article_Title_4, Book_Title_4, Pages_4, Quotation_4, Article_Year_4, Book_Year_4, Note4, Notes_Article_4, Notes_Book_4), write(['A0007', Quote_4, Author_4, Author_Article_4, Author_Book_4, Article_Title_4, Book_Title_4, Pages_4, Quotation_4, Article_Year_4, Book_Year_4, Note4, Notes_Article_4, Notes_Book_4] ), nl. %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% pl_external_synonym expanded with full names and supporting quotations %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% pl_external_synonym_simple_expanded(Number, Philosopher_1, Philosopher_2, External_Term_1, External_Term_2, Quote_1, Author_1, Author_Article_1, Author_Book_1, Article_Title_1, Book_Title_1, Pages_1, Quotation_1, Article_Year_1, Book_Year_1, Note1, Notes_Article_1, Notes_Book_1, Quote_2, Author_2, Author_Article_2, Author_Book_2, Article_Title_2, Book_Title_2, Pages_2, Quotation_2, Article_Year_2, Book_Year_2, Note2, Notes_Article_2, Notes_Book_2, Quote_3, Author_3, Author_Article_3, Author_Book_3, Article_Title_3, Book_Title_3, Pages_3, Quotation_3, Article_Year_3, Book_Year_3, Note3, Notes_Article_3, Notes_Book_3, Quote_4, Author_4, Author_Article_4, Author_Book_4, Article_Title_4, Book_Title_4, Pages_4, Quotation_4, Article_Year_4, Book_Year_4, Note4, Notes_Article_4, Notes_Book_4) :- term(External_Term_1), term(External_Term_2), pl_external_synonym(Number, Philosopher_1, Philosopher_2, External_Term_1, External_Term_2, Quote_1, Quote_2, Quote_3, Quote_4), quote_note(Quote_1, Author_1, Author_Article_1, Author_Book_1, Article_Title_1, Book_Title_1, Pages_1, Quotation_1, Article_Year_1, Book_Year_1, Note1, Notes_Article_1, Notes_Book_1), quote_note(Quote_2, Author_2, Author_Article_2, Author_Book_2, Article_Title_2, Book_Title_2, Pages_2, Quotation_2, Article_Year_2, Book_Year_2, Note2, Notes_Article_2, Notes_Book_2), quote_note(Quote_3, Author_3, Author_Article_3, Author_Book_3, Article_Title_3, Book_Title_3, Pages_3, Quotation_3, Article_Year_3, Book_Year_3, Note3, Notes_Article_3, Notes_Book_3), quote_note(Quote_4, Author_4, Author_Article_4, Author_Book_4, Article_Title_4, Book_Title_4, Pages_4, Quotation_4, Article_Year_4, Book_Year_4, Note4, Notes_Article_4, Notes_Book_4). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% pl_external_synonym componded - two philosophers using term same as another %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% pl_external_synonym_compound_expanded(Number1A, Number1B, Philosopher_1, Philosopher_2A, Philosopher_2B, External_Term_1, External_Term_2A, External_Term_2B, Quote_1A, Author_1A, Author_Article_1A, Author_Book_1A, Article_Title_1A, Book_Title_1A, Pages_1A, Quotation_1A, Article_Year_1A, Book_Year_1A, Note1A, Notes_Article_1A, Notes_Book_1A, Quote_2A, Author_2A, Author_Article_2A, Author_Book_2A, Article_Title_2A, Book_Title_2A, Pages_2A, Quotation_2A, Article_Year_2A, Book_Year_2A, Note2A, Notes_Article_2A, Notes_Book_2A, Quote_3A, Author_3A, Author_Article_3A, Author_Book_3A, Article_Title_3A, Book_Title_3A, Pages_3A, Quotation_3A, Article_Year_3A, Book_Year_3A, Note3A, Notes_Article_3A, Notes_Book_3A, Quote_4A, Author_4A, Author_Article_4A, Author_Book_4A, Article_Title_4A, Book_Title_4A, Pages_4A, Quotation_4A, Article_Year_4A, Book_Year_4A, Note4A, Notes_Article_4A, Notes_Book_4A, Quote_1B, Author_1B, Author_Article_1B, Author_Book_1B, Article_Title_1B, Book_Title_1B, Pages_1B, Quotation_1B, Article_Year_1B, Book_Year_1B, Note1B, Notes_Article_1B, Notes_Book_1B, Quote_2B, Author_2B, Author_Article_2B, Author_Book_2B, Article_Title_2B, Book_Title_2B, Pages_2B, Quotation_2B, Article_Year_2B, Book_Year_2B, Note2B, Notes_Article_2B, Notes_Book_2B, Quote_3B, Author_3B, Author_Article_3B, Author_Book_3B, Article_Title_3B, Book_Title_3B, Pages_3B, Quotation_3B, Article_Year_3B, Book_Year_3B, Note3B, Notes_Article_3B, Notes_Book_3B, Quote_4B, Author_4B, Author_Article_4B, Author_Book_4B, Article_Title_4B, Book_Title_4B, Pages_4B, Quotation_4B, Article_Year_4B, Book_Year_4B, Note4B, Notes_Article_4B, Notes_Book_4B) :- term(External_Term_1), term(External_Term_2), pl_external_synonym(NumberA, Philosopher_1, Philosopher_2A, External_Term_1, External_Term_2A, Quote_1A, Quote_2A, Quote_3A, Quote_4A), pl_external_synonym(NumberB, Philosopher_1, Philosopher_2B, External_Term_1, External_Term_2B, Quote_1B, Quote_2B, Quote_3B, Quote_4B), quote_note(Quote_1A, Author_1A, Author_Article_1A, Author_Book_1A, Article_Title_1A, Book_Title_1A, Pages_1A, Quotation_1A, Article_Year_1A, Book_Year_1A, Note1A, Notes_Article_1A, Notes_Book_1A), quote_note(Quote_2A, Author_2A, Author_Article_2A, Author_Book_2A, Article_Title_2A, Book_Title_2A, Pages_2A, Quotation_2A, Article_Year_2A, Book_Year_2A, Note2A, Notes_Article_2A, Notes_Book_2A), quote_note(Quote_3A, Author_3A, Author_Article_3A, Author_Book_3A, Article_Title_3A, Book_Title_3A, Pages_3A, Quotation_3A, Article_Year_3A, Book_Year_3A, Note3A, Notes_Article_3A, Notes_Book_3A), quote_note(Quote_4A, Author_4A, Author_Article_4A, Author_Book_4A, Article_Title_4A, Book_Title_4A, Pages_4A, Quotation_4A, Article_Year_4A, Book_Year_4A, Note4A, Notes_Article_4A, Notes_Book_4A), quote_note(Quote_1B, Author_1B, Author_Article_1B, Author_Book_1B, Article_Title_1B, Book_Title_1B, Pages_1B, Quotation_1B, Article_Year_1B, Book_Year_1B, Note1B, Notes_Article_1B, Notes_Book_1B), quote_note(Quote_2B, Author_2B, Author_Article_2B, Author_Book_2B, Article_Title_2B, Book_Title_2B, Pages_2B, Quotation_2B, Article_Year_2B, Book_Year_2B, Note2B, Notes_Article_2B, Notes_Book_2B), quote_note(Quote_3B, Author_3B, Author_Article_3B, Author_Book_3B, Article_Title_3B, Book_Title_3B, Pages_3B, Quotation_3B, Article_Year_3B, Book_Year_3B, Note3B, Notes_Article_3B, Notes_Book_3B), quote_note(Quote_4B, Author_4B, Author_Article_4B, Author_Book_4B, Article_Title_4B, Book_Title_4B, Pages_4B, Quotation_4B, Article_Year_4B, Book_Year_4B, Note4B, Notes_Article_4B, Notes_Book_4B), different(Philosopher_2A, Philosopher_2B). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% Philosopher 2 using 2 different terms as philosopher 1 uses 1 term %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% pl_ambiguity_1(Number_1, Number_2, Philosopher_1, Philosopher_2, External_Term_1, External_Term_2A, External_Term_2B) :- pl_external_synonym(Number_1, Philosopher_Abbreviation_1, Philosopher_Abbreviation_2, External_Term_1, External_Term_2A, Quote_1A, Quote_2A, Quote_3A, Quote_4A), pl_external_synonym(Number_2, Philosopher_Abbreviation_1, Philosopher_Abbreviation_2, External_Term_1, External_Term_2B, Quote_1B, Quote_2B, Quote_3B, Quote_4B), different(External_Term_2A, External_Term_2B), philosopher(Philosopher_Abbreviation_1, Philosopher_1), philosopher(Philosopher_Abbreviation_2, Philosopher_2). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% Philosopher 1 using 2 different terms as philosopher 2 uses 1 term %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% pl_ambiguity_2(Number_1, Number_2, Philosopher_1, Philosopher_2, External_Term_1A, External_Term_1B, External_Term_2) :- pl_external_synonym(Number_1, Philosopher_Abbreviation_1, Philosopher_Abbreviation_2, External_Term_1A, External_Term_2, Quote_1A, Quote_2A, Quote_3A, Quote_4A), pl_external_synonym(Number_2, Philosopher_Abbreviation_1, Philosopher_Abbreviation_2, External_Term_1B, External_Term_2, Quote_1B, Quote_2B, Quote_3B, Quote_4B), different(External_Term_1A, External_Term_1B), philosopher(Philosopher_Abbreviation_1, Philosopher_1), philosopher(Philosopher_Abbreviation_2, Philosopher_2). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% Expand quotation info when there is both book and article info %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% quote_note(Id_Number, Author, Author_Article, Author_Book, Article_Title, Book_Title, Pages, Quotation, Article_Year, Book_Year, Note1, Notes_Article, Notes_Book) :- philosophical_quotation(Id_Number, Author_Abbreviation, Article_Abbreviation, Book_Abbreviation, Pages, Quotation, Note1), article(Article_Abbreviation, Book_Abbreviation, Author_Article_Abbreviation, Article_Title, Article_Year, Notes_Article), book(Book_Abbreviation, Author_Book_Abbreviation, Book_Title, Book_Year, Notes_Book), philosopher(Author_Article_Abbreviation, Author_Article), philosopher(Author_Book_Abbreviation, Author_Book), actual_author(Author_Abbreviation, Author_Article_Abbreviation, Author_Book_Abbreviation), philosopher(Author_Abbreviation, Author). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% Expand quotation info when there is only book info %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% quote_note(Id_Number, Author, none, Author_Book, none, Book_Title, Pages, Quotation, none, Book_Year, Note1, none, Notes_Book) :- philosophical_quotation(Id_Number, Author_Abbreviation, none, Book_Abbreviation, Pages, Quotation, Note1), book(Book_Abbreviation, Author_Book_Abbreviation, Book_Title, Book_Year, Notes_Book), philosopher(Author_Book_Abbreviation, Author_Book), actual_author(Author_Abbreviation, none, Author_Book_Abbreviation), philosopher(Author_Abbreviation, Author). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% Expand quotation info when there is only article info %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% quote_note(Id_Number, Author, Author_Article, none, Article_Title, none, Pages, Quotation, Article_Year, none, Note1, Notes_Article, none) :- philosophical_quotation(Id_Number, Author_Abbreviation, Article_Abbreviation, none, Pages, Quotation, Note1), article(Article_Abbreviation, none, Author_Article_Abbreviation, Article_Title, Article_Year, Notes_Article), philosopher(Author_Article_Abbreviation, Author_Article), actual_author(Author_Abbreviation, Author_Article_Abbreviation, none), philosopher(Author_Abbreviation, Author). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% Expand quotation info when there is no info %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% quote_note(none, none, none, none, none, none, none, none, none, none, none, none, none). %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% %% If there is article author info use it - otherwise use book info %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% actual_author(Author_Abbreviation, Author_Article_Abbreviation, Author_Book_Abbreviation) :- different(Author_Article_Abbreviation, none), Author_Abbreviation = Author_Article_Abbreviation, !. actual_author(Author_Abbreviation, Author_Article_Abbreviation, Author_Book_Abbreviation) :- Author_Abbreviation = Author_Book_Abbreviation.