:- style_check(-singleton). % added djd
%% :- module('Programs', []).

:- module(programs).  %% converted djd

:- discontiguous 'programs.DeclaredInOpenModule.P3.0'/3. %% added djd
:- discontiguous '~programs.DeclaredInOpenModule.P3.0'/3. %% added djd
:- discontiguous 'programs.CompileObjectCode.P1'/1. %% added djd
:- discontiguous '~programs.CompileObjectCode.P1'/1. %% added djd
:- discontiguous 'programs.CModulePart.P2.0'/2. %% added djd
:- discontiguous '~programs.CModulePart.P2.0'/2. %% added djd
:- discontiguous 'programs.ComposeAll.P3'/3. %% added djd
:- discontiguous '~programs.ComposeAll.P3'/3. %% added djd
:- discontiguous 'programs.ConditionSatisfied.P2'/2. %% added djd
:- discontiguous '~programs.ConditionSatisfied.P2'/2. %% added djd
:- discontiguous 'programs.ConstraintsToBindings.P4'/4. %% added djd
:- discontiguous '~programs.ConstraintsToBindings.P4'/4. %% added djd
:- discontiguous 'programs.ConstraintsToBindingsAll.P4'/4. %% added djd
:- discontiguous '~programs.ConstraintsToBindingsAll.P4'/4. %% added djd
:- discontiguous 'programs.DeclaredInClosedModule.P3.0'/3. %% added djd
:- discontiguous '~programs.DeclaredInClosedModule.P3.0'/3. %% added djd
:- discontiguous 'programs.DelayInModule.P5.0'/5. %% added djd
:- discontiguous '~programs.DelayInModule.P5.0'/5. %% added djd
:- discontiguous 'programs.DefinitionInProgram.P4.0'/4. %% added djd
:- discontiguous '~programs.DefinitionInProgram.P4.0'/4. %% added djd
:- discontiguous 'programs.DelayInKind.P5'/5. %% added djd
:- discontiguous '~programs.DelayInKind.P5'/5. %% added djd
:- discontiguous 'programs.DelayInPart.P4'/4. %% added djd
:- discontiguous '~programs.DelayInPart.P4'/4. %% added djd
:- discontiguous 'programs.DeleteImportFromPart.P6'/6. %% added djd
:- discontiguous '~programs.DeleteImportFromPart.P6'/6. %% added djd
:- discontiguous 'programs.DeleteDelayFromPart.P6'/6. %% added djd
:- discontiguous '~programs.DeleteDelayFromPart.P6'/6. %% added djd
:- discontiguous 'programs.DeleteProgramImport.P5.0'/5. %% added djd
:- discontiguous '~programs.DeleteProgramImport.P5.0'/5. %% added djd
:- discontiguous 'programs.DeleteStatement.P4.0'/4. %% added djd
:- discontiguous '~programs.DeleteStatement.P4.0'/4. %% added djd
:- discontiguous 'programs.GroundCondition.P2'/2. %% added djd
:- discontiguous '~programs.GroundCondition.P2'/2. %% added djd
:- discontiguous 'programs.FormulaInProgram.P4.0'/4. %% added djd
:- discontiguous '~programs.FormulaInProgram.P4.0'/4. %% added djd
:- discontiguous 'programs.ImportInModule.P4.0'/4. %% added djd
:- discontiguous '~programs.ImportInModule.P4.0'/4. %% added djd
:- discontiguous 'programs.HasIntensionalSet.P1'/1. %% added djd
:- discontiguous '~programs.HasIntensionalSet.P1'/1. %% added djd
:- discontiguous 'programs.ImportInPart.P5'/5. %% added djd
:- discontiguous '~programs.ImportInPart.P5'/5. %% added djd
:- discontiguous 'programs.InsertProgramImport.P5.0'/5. %% added djd
:- discontiguous '~programs.InsertProgramImport.P5.0'/5. %% added djd
:- discontiguous 'programs.InstanceOfHead1.P4'/4. %% added djd
:- discontiguous '~programs.InstanceOfHead1.P4'/4. %% added djd
:- discontiguous 'programs.InstanceOfHead2.P4'/4. %% added djd
:- discontiguous '~programs.InstanceOfHead2.P4'/4. %% added djd
:- discontiguous 'programs.ModulePartLanguage.P4'/4. %% added djd
:- discontiguous '~programs.ModulePartLanguage.P4'/4. %% added djd
:- discontiguous 'programs.ModuleInProgram.P2.0'/2. %% added djd
:- discontiguous '~programs.ModuleInProgram.P2.0'/2. %% added djd
:- discontiguous 'programs.NonVarCondition.P2'/2. %% added djd
:- discontiguous '~programs.NonVarCondition.P2'/2. %% added djd
:- discontiguous 'programs.PredOrPropInLanguage.P3'/3. %% added djd
:- discontiguous '~programs.PredOrPropInLanguage.P3'/3. %% added djd
:- discontiguous 'programs.OpenStatementPredicate.P2.1'/2. %% added djd
:- discontiguous '~programs.OpenStatementPredicate.P2.1'/2. %% added djd
:- discontiguous 'programs.OpenStatementPredicate.P2.0'/2. %% added djd
:- discontiguous '~programs.OpenStatementPredicate.P2.0'/2. %% added djd
:- discontiguous 'programs.PartAccessibility.P2'/2. %% added djd
:- discontiguous '~programs.PartAccessibility.P2'/2. %% added djd
:- discontiguous 'programs.RightHandType.P4'/4. %% added djd
:- discontiguous '~programs.RightHandType.P4'/4. %% added djd
:- discontiguous 'programs.StatementMatchAtom.P4.0'/4. %% added djd
:- discontiguous '~programs.StatementMatchAtom.P4.0'/4. %% added djd
:- discontiguous 'programs.TermInProgram.P5.0'/5. %% added djd
:- discontiguous '~programs.TermInProgram.P5.0'/5. %% added djd
:- discontiguous 'programs.SymbolInFormula.P2'/2. %% added djd
:- discontiguous '~programs.SymbolInFormula.P2'/2. %% added djd
:- discontiguous 'programs.SymbolInTerm.P2'/2. %% added djd
:- discontiguous '~programs.SymbolInTerm.P2'/2. %% added djd
:- discontiguous 'programs.TopLevelName.P2.0'/2. %% added djd
:- discontiguous '~programs.TopLevelName.P2.0'/2. %% added djd
:- discontiguous 'programs.TypeSymbolInType.P2'/2. %% added djd
:- discontiguous '~programs.TypeSymbolInType.P2'/2. %% added djd
:- discontiguous 'programs.TypeInProgram.P2.0'/2. %% added djd
:- discontiguous '~programs.TypeInProgram.P2.0'/2. %% added djd
:- discontiguous 'programs.TypeSymbolInDeclaration.P2'/2. %% added djd
:- discontiguous '~programs.TypeSymbolInDeclaration.P2'/2. %% added djd
:- discontiguous 'programs.ValidDeclaration.P4'/4. %% added djd
:- discontiguous '~programs.ValidDeclaration.P4'/4. %% added djd

:- op(500, yfx, and).
:- op(400, yfx, or).

'programs.MainModuleInProgram.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Programs':'programs.MainModuleInProgram.P2.0'(A,B)).
'~programs.MainModuleInProgram.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Programs':'~programs.MainModuleInProgram.P2.0'(A,B)).
'programs.MainModuleInProgram.P2.0'(A, B) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, C),
        'SharedPrograms':'Sharedprograms.SMainModuleInProgram.P2'(C, B).
'~programs.MainModuleInProgram.P2.0'(A, B) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, C),
        'SharedPrograms':'~Sharedprograms.SMainModuleInProgram.P2'(C, B).
'programs.FormulaInModule.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(ground([A,B,C,D,E]), 'Programs':'programs.FormulaInModule.P6.0'(A,B,C,D,E,F)).
'~programs.FormulaInModule.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(ground([A,B,C,D,E]), 'Programs':'~programs.FormulaInModule.P6.0'(A,B,C,D,E,F)).
'programs.FormulaInModule.P6.0'(A, B, C, D, E, F) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, G),
        'programs.CModulePart.P2'(C, H),
        'programs.ModulePartLanguage.P4'(H, B, G, I),
        'SharedPrograms':'Sharedprograms.FormulaInLanguage.P4'(E, I, D, F).
'~programs.FormulaInModule.P6.0'(A, B, C, D, E, F) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, G),
        '~programs.CModulePart.P2'(C, H),
        '~programs.ModulePartLanguage.P4'(H, B, G, I),
        'SharedPrograms':'~Sharedprograms.FormulaInLanguage.P4'(E, I, D, F).
'programs.DeclaredInOpenModule.P3'(A, B, C) :-
        user:goedel_freeze(ground([A,C]), 'Programs':'programs.DeclaredInOpenModule.P3.0'(A,B,C)).
'~programs.DeclaredInOpenModule.P3'(A, B, C) :-
        user:goedel_freeze(ground([A,C]), 'Programs':'~programs.DeclaredInOpenModule.P3.0'(A,B,C)).
'programs.DeclaredInOpenModule.P3.0'('ProgDefs.CachedProgram.F1'(A), B, C) :-
        'ProgramCache':'ProgramCache.GetCachedProgram.P2'(A, D),
        'programs.DeclaredInOpenModule.P3'(D, B, C).
'~programs.DeclaredInOpenModule.P3.0'('ProgDefs.CachedProgram.F1'(A), B, C) :-
        'ProgramCache':'~ProgramCache.GetCachedProgram.P2'(A, D),
        '~programs.DeclaredInOpenModule.P3'(D, B, C).
'programs.DeclaredInOpenModule.P3.0'('ProgDefs.Program.F4'(_,A,B,_), C, D) :-
        'Syntax':'Syntax.Atom.P1'(D),
        'Syntax':'Syntax.EmptyVarTyping.P1'(E),
        'SharedPrograms':'Sharedprograms.FormulaInLanguage.P4'(D, B, E, _),
        'programs.TopLevelName.P2'(D, 'MetaDefs.Name.F4'(C,_,_,_)),
        'SharedPrograms':'Sharedprograms.OpenModuleAux.P2'(A, C).
'~programs.DeclaredInOpenModule.P3.0'('ProgDefs.Program.F4'(_,A,B,_), C, D) :-
        'Syntax':'~Syntax.Atom.P1'(D),
        'Syntax':'~Syntax.EmptyVarTyping.P1'(E),
        'SharedPrograms':'~Sharedprograms.FormulaInLanguage.P4'(D, B, E, _),
        '~programs.TopLevelName.P2'(D, 'MetaDefs.Name.F4'(C,_,_,_)),
        'SharedPrograms':'~Sharedprograms.OpenModuleAux.P2'(A, C).
'programs.Compute.P7'(A, B, C, D, E, F, G) :-
        user:goedel_freeze(ground([A,B,C,E]), 'Programs':'programs.Compute.P7.0'(A,B,C,D,E,F,G)).
'~programs.Compute.P7'(A, B, C, D, E, F, G) :-
        user:goedel_freeze(ground([A,B,C,E]), 'Programs':'~programs.Compute.P7.0'(A,B,C,D,E,F,G)).
'programs.Compute.P7.0'(A, B, C, D, E, F, G) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, H),
        'SharedPrograms':'Sharedprograms.ProgramLanguage.P2'(H, I),
        'Syntax':'Syntax.ApplySubstToFormula.P3'(B, E, J),
        'SharedPrograms':'Sharedprograms.MeltedBodyTyping.P8'(J, I, [], _, _, [], [], []),
        'programs.CompileObjectProgram.P1'(H),
        'programs.RunGoal.P6'(J, C, E, K, D, L),
        'programs.ConstraintsToBindings.P4'(L, G, K, F).
'~programs.Compute.P7.0'(A, B, C, D, E, F, G) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, H),
        'SharedPrograms':'~Sharedprograms.ProgramLanguage.P2'(H, I),
        'Syntax':'~Syntax.ApplySubstToFormula.P3'(B, E, J),
        'SharedPrograms':'~Sharedprograms.MeltedBodyTyping.P8'(J, I, [], _, _, [], [], []),
        '~programs.CompileObjectProgram.P1'(H),
        '~programs.RunGoal.P6'(J, C, E, K, D, L),
        '~programs.ConstraintsToBindings.P4'(L, G, K, F).
'programs.BaseInModule.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A]), 'Programs':'programs.BaseInModule.P5.0'(A,B,C,D,E)).
'~programs.BaseInModule.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A]), 'Programs':'~programs.BaseInModule.P5.0'(A,B,C,D,E)).
'programs.BaseInModule.P5.0'(A, B, C, D, E) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, F),
        'programs.CModulePart.P2'(C, G),
        'SharedPrograms':'Sharedprograms.ModulePartInProgram.P3'(F, B, G),
        'programs.ModulePartLanguage.P4'(G, B, F, H),
        'SharedPrograms':'Sharedprograms.BaseInLanguage.P2'(D, H),
        D='MetaDefs.Name.F4'(E,_,_,_).
'~programs.BaseInModule.P5.0'(A, B, C, D, E) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, F),
        '~programs.CModulePart.P2'(C, G),
        'SharedPrograms':'~Sharedprograms.ModulePartInProgram.P3'(F, B, G),
        '~programs.ModulePartLanguage.P4'(G, B, F, H),
        'SharedPrograms':'~Sharedprograms.BaseInLanguage.P2'(D, H),
        D='MetaDefs.Name.F4'(E,_,_,_).
'programs.AndCondition.P3'(A, B, 'ProgDefs.And.F2'(A,B)).
'~programs.AndCondition.P3'(A, B, 'ProgDefs.And.F2'(A,B)).
'programs.ApplicableDelay.P5'([A|B], [C|D], E, F, G) :-
        'Syntax':'Syntax.EmptyTermSubst.P1'(H),
        user:goedel_freeze(ground([E,H,A]), ('Syntax':'~Syntax.UnifyAtoms.P4'(A,E,H,_),true->F=A,G=C;'Programs':'programs.ApplicableDelay.P5'(B,D,E,F,G))).
'~programs.ApplicableDelay.P5'([A|B], [C|D], E, F, G) :-
        'Syntax':'~Syntax.EmptyTermSubst.P1'(H),
        user:goedel_freeze(ground([E,H,A]), ('Syntax':'~Syntax.UnifyAtoms.P4'(A,E,H,_),true->F=A,G=C;'Programs':'~programs.ApplicableDelay.P5'(B,D,E,F,G))).
'programs.CompileObjectCode.P1'('AVLTrees.Empty.C0').
'~programs.CompileObjectCode.P1'('AVLTrees.Empty.C0').
'programs.CompileObjectCode.P1'('AVLTrees.Tree.F4'(A,B,'ProgDefs.Code.F2'(C,D),E)) :-
        user:goedel_freeze(ground([B]), ('SharedPrograms':'~Sharedprograms.SystemModule.P1'(B),true->'Programs':'programs.EnsureLoaded.P1'(B);'Programs':'programs.EnsureCompiled.P3'(B,C,D))),
        'programs.CompileObjectCode.P1'(A),
        'programs.CompileObjectCode.P1'(E).
'~programs.CompileObjectCode.P1'('AVLTrees.Tree.F4'(A,B,'ProgDefs.Code.F2'(C,D),E)) :-
        user:goedel_freeze(ground([B]), ('SharedPrograms':'~Sharedprograms.SystemModule.P1'(B),true->'Programs':'~programs.EnsureLoaded.P1'(B);'Programs':'~programs.EnsureCompiled.P3'(B,C,D))),
        '~programs.CompileObjectCode.P1'(A),
        '~programs.CompileObjectCode.P1'(E).
'programs.CModulePart.P2'(A, B) :-
        user:goedel_freeze(nonvar(A)or nonvar(B), 'Programs':'programs.CModulePart.P2.0'(A,B)).
'~programs.CModulePart.P2'(A, B) :-
        user:goedel_freeze(nonvar(A)or nonvar(B), 'Programs':'~programs.CModulePart.P2.0'(A,B)).
'programs.CModulePart.P2.0'('programs.Export.C0', 'ProgDefs.Export.C0') :- !.
'~programs.CModulePart.P2.0'('programs.Export.C0', 'ProgDefs.Export.C0').
'programs.CModulePart.P2.0'('programs.Local.C0', 'ProgDefs.Local.C0') :- !.
'~programs.CModulePart.P2.0'('programs.Local.C0', 'ProgDefs.Local.C0').
'programs.CModulePart.P2.0'('programs.Module.C0', 'ProgDefs.Module.C0') :- !.
'~programs.CModulePart.P2.0'('programs.Module.C0', 'ProgDefs.Module.C0').
'programs.CModulePart.P2.0'('programs.Closed.C0', 'ProgDefs.Closed.C0') :- !.
'~programs.CModulePart.P2.0'('programs.Closed.C0', 'ProgDefs.Closed.C0').
'programs.CompileObjectProgram.P1'('ProgDefs.Program.F4'(_,_,_,A)) :-
        'AVLTrees':'AVLTrees.AVLToBinary.P2'(A, B),
        'programs.CompileObjectCode.P1'(B).
'~programs.CompileObjectProgram.P1'('ProgDefs.Program.F4'(_,_,_,A)) :-
        'AVLTrees':'~AVLTrees.AVLToBinary.P2'(A, B),
        '~programs.CompileObjectCode.P1'(B).
'programs.ComposeAll.P3'([], [], []).
'~programs.ComposeAll.P3'([], [], []).
'programs.ComposeAll.P3'([A|B], [C|D], [E|F]) :-
        'Syntax':'Syntax.ComposeTermSubsts.P3'(A, C, E),
        'programs.ComposeAll.P3'(B, D, F).
'~programs.ComposeAll.P3'([A|B], [C|D], [E|F]) :-
        'Syntax':'~Syntax.ComposeTermSubsts.P3'(A, C, E),
        '~programs.ComposeAll.P3'(B, D, F).
'programs.ConstructorInModule.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(ground([A]), 'Programs':'programs.ConstructorInModule.P6.0'(A,B,C,D,E,F)).
'~programs.ConstructorInModule.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(ground([A]), 'Programs':'~programs.ConstructorInModule.P6.0'(A,B,C,D,E,F)).
'programs.ConstructorInModule.P6.0'(A, B, C, D, E, F) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, G),
        'programs.CModulePart.P2'(C, H),
        'SharedPrograms':'Sharedprograms.ModulePartInProgram.P3'(G, B, H),
        'programs.ModulePartLanguage.P4'(H, B, G, I),
        'SharedPrograms':'Sharedprograms.ConstructorInLanguage.P3'(D, I, E),
        D='MetaDefs.Name.F4'(F,_,_,_).
'~programs.ConstructorInModule.P6.0'(A, B, C, D, E, F) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, G),
        '~programs.CModulePart.P2'(C, H),
        'SharedPrograms':'~Sharedprograms.ModulePartInProgram.P3'(G, B, H),
        '~programs.ModulePartLanguage.P4'(H, B, G, I),
        'SharedPrograms':'~Sharedprograms.ConstructorInLanguage.P3'(D, I, E),
        D='MetaDefs.Name.F4'(F,_,_,_).
'programs.ConditionToString.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Programs':'programs.ConditionToString.P2.0'(A,B)).
'~programs.ConditionToString.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Programs':'~programs.ConditionToString.P2.0'(A,B)).
'programs.ConditionToString.P2.0'(A, B) :-
        'SharedPrograms':'Sharedprograms.SConditionToString.P2'(A, B).
'~programs.ConditionToString.P2.0'(A, B) :-
        'SharedPrograms':'~Sharedprograms.SConditionToString.P2'(A, B).
'programs.ComputeAll.P7'(A, B, C, D, E, F, G) :-
        user:goedel_freeze(ground([A,B,C,E]), 'Programs':'programs.ComputeAll.P7.0'(A,B,C,D,E,F,G)).
'~programs.ComputeAll.P7'(A, B, C, D, E, F, G) :-
        user:goedel_freeze(ground([A,B,C,E]), 'Programs':'~programs.ComputeAll.P7.0'(A,B,C,D,E,F,G)).
'programs.ComputeAll.P7.0'(A, B, C, D, E, F, G) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, H),
        'SharedPrograms':'Sharedprograms.ProgramLanguage.P2'(H, I),
        'Syntax':'Syntax.ApplySubstToFormula.P3'(B, E, J),
        'SharedPrograms':'Sharedprograms.MeltedBodyTyping.P8'(J, I, [], _, _, [], [], []),
        'programs.CompileObjectProgram.P1'(H),
        'programs.RunAllGoal.P6'(J, C, E, K, D, L),
        'programs.ConstraintsToBindingsAll.P4'(L, G, K, F).
'~programs.ComputeAll.P7.0'(A, B, C, D, E, F, G) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, H),
        'SharedPrograms':'~Sharedprograms.ProgramLanguage.P2'(H, I),
        'Syntax':'~Syntax.ApplySubstToFormula.P3'(B, E, J),
        'SharedPrograms':'~Sharedprograms.MeltedBodyTyping.P8'(J, I, [], _, _, [], [], []),
        '~programs.CompileObjectProgram.P1'(H),
        '~programs.RunAllGoal.P6'(J, C, E, K, D, L),
        '~programs.ConstraintsToBindingsAll.P4'(L, G, K, F).
'programs.ConditionSatisfied.P2'('ProgDefs.Nonvar.F1'(A), B) :-
        'Syntax':'Syntax.BindingInTermSubst.P3'(B, A, C),
        'Syntax':'Syntax.NonVariable.P1'(C).
'~programs.ConditionSatisfied.P2'('ProgDefs.Nonvar.F1'(A), B) :-
        'Syntax':'~Syntax.BindingInTermSubst.P3'(B, A, C),
        'Syntax':'~Syntax.NonVariable.P1'(C).
'programs.ConditionSatisfied.P2'('ProgDefs.And.F2'(A,B), C) :-
        'programs.ConditionSatisfied.P2'(A, C),
        'programs.ConditionSatisfied.P2'(B, C).
'~programs.ConditionSatisfied.P2'('ProgDefs.And.F2'(A,B), C) :-
        '~programs.ConditionSatisfied.P2'(A, C),
        '~programs.ConditionSatisfied.P2'(B, C).
'programs.ConditionSatisfied.P2'('ProgDefs.Ground.F1'(A), B) :-
        'Syntax':'Syntax.BindingInTermSubst.P3'(B, A, C),
        'Syntax':'Syntax.GroundTerm.P1'(C).
'~programs.ConditionSatisfied.P2'('ProgDefs.Ground.F1'(A), B) :-
        'Syntax':'~Syntax.BindingInTermSubst.P3'(B, A, C),
        'Syntax':'~Syntax.GroundTerm.P1'(C).
'programs.ConditionSatisfied.P2'('ProgDefs.TrueCond.C0', _).
'~programs.ConditionSatisfied.P2'('ProgDefs.TrueCond.C0', _).
'programs.ConditionSatisfied.P2'('ProgDefs.Or.F2'(A,B), C) :-
        user:one_solution(('Programs':'programs.ConditionSatisfied.P2'(A,C);'Programs':'programs.ConditionSatisfied.P2'(B,C))).
'~programs.ConditionSatisfied.P2'('ProgDefs.Or.F2'(A,B), C) :-
        (   '~programs.ConditionSatisfied.P2'(A, C)
        ;   '~programs.ConditionSatisfied.P2'(B, C)
        ).
'programs.ConstraintsToBindings.P4'('MetaDefs.Empty.C0', 'MetaDefs.Empty.C0', A, A).
'~programs.ConstraintsToBindings.P4'('MetaDefs.Empty.C0', 'MetaDefs.Empty.C0', A, A).
'programs.ConstraintsToBindings.P4'('MetaDefs.&''.F2'(A,B), C, D, E) :-
        'programs.ConstraintsToBindings.P4'(A, F, D, G),
        'programs.ConstraintsToBindings.P4'(B, H, G, E),
        'Syntax':'Syntax.AndWithEmpty.P3'(F, H, C).
'~programs.ConstraintsToBindings.P4'('MetaDefs.&''.F2'(A,B), C, D, E) :-
        '~programs.ConstraintsToBindings.P4'(A, F, D, G),
        '~programs.ConstraintsToBindings.P4'(B, H, G, E),
        'Syntax':'~Syntax.AndWithEmpty.P3'(F, H, C).
'programs.ConstraintsToBindings.P4'('MetaDefs.Atom.F2'(A,B), C, D, E) :-
        user:one_solution(user:goedel_freeze(ground([B,A]),if(((A='MetaDefs.Name.F4'('"','"=',_,2),B=[F,G],'Syntax':'~Syntax.Variable.P1'(F)),true),('Substs':'Substs.BindVariable.P4'(F,G,D,E),C='MetaDefs.Empty.C0'),(E=D,C='MetaDefs.Atom.F2'(A,B))))).
'~programs.ConstraintsToBindings.P4'('MetaDefs.Atom.F2'(A,B), C, D, E) :-
        user:goedel_freeze(ground([B,A]), if(((A='MetaDefs.Name.F4'('"','"=',_,2),B=[F,G],'Syntax':'~Syntax.Variable.P1'(F)),true),('Substs':'~Substs.BindVariable.P4'(F,G,D,E),C='MetaDefs.Empty.C0'),(E=D,C='MetaDefs.Atom.F2'(A,B)))).
'programs.ConstantInModule.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(ground([A]), 'Programs':'programs.ConstantInModule.P6.0'(A,B,C,D,E,F)).
'~programs.ConstantInModule.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(ground([A]), 'Programs':'~programs.ConstantInModule.P6.0'(A,B,C,D,E,F)).
'programs.ConstantInModule.P6.0'(A, B, C, D, E, F) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, G),
        'programs.CModulePart.P2'(C, H),
        'SharedPrograms':'Sharedprograms.ModulePartInProgram.P3'(G, B, H),
        'programs.ModulePartLanguage.P4'(H, B, G, I),
        'SharedPrograms':'Sharedprograms.ConstantInLanguage.P3'(D, I, E),
        D='MetaDefs.Name.F4'(F,_,_,_).
'~programs.ConstantInModule.P6.0'(A, B, C, D, E, F) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, G),
        '~programs.CModulePart.P2'(C, H),
        'SharedPrograms':'~Sharedprograms.ModulePartInProgram.P3'(G, B, H),
        '~programs.ModulePartLanguage.P4'(H, B, G, I),
        'SharedPrograms':'~Sharedprograms.ConstantInLanguage.P3'(D, I, E),
        D='MetaDefs.Name.F4'(F,_,_,_).
'programs.ConstraintsToBindingsAll.P4'([], [], [], []).
'~programs.ConstraintsToBindingsAll.P4'([], [], [], []).
'programs.ConstraintsToBindingsAll.P4'([A|B], [C|D], [E|F], [G|H]) :-
        'programs.ConstraintsToBindings.P4'(A, C, E, G),
        'programs.ConstraintsToBindingsAll.P4'(B, D, F, H).
'~programs.ConstraintsToBindingsAll.P4'([A|B], [C|D], [E|F], [G|H]) :-
        '~programs.ConstraintsToBindings.P4'(A, C, E, G),
        '~programs.ConstraintsToBindingsAll.P4'(B, D, F, H).
'programs.ControlInProgram.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A]), 'Programs':'programs.ControlInProgram.P5.0'(A,B,C,D,E)).
'~programs.ControlInProgram.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A]), 'Programs':'~programs.ControlInProgram.P5.0'(A,B,C,D,E)).
'programs.ControlInProgram.P5.0'(A, B, C, D, E) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, F),
        'SharedPrograms':'Sharedprograms.SControlInProgram.P5'(F, B, C, D, E).
'~programs.ControlInProgram.P5.0'(A, B, C, D, E) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, F),
        'SharedPrograms':'~Sharedprograms.SControlInProgram.P5'(F, B, C, D, E).
'programs.DeclaredInClosedModule.P3'(A, B, C) :-
        user:goedel_freeze(ground([A,C]), 'Programs':'programs.DeclaredInClosedModule.P3.0'(A,B,C)).
'~programs.DeclaredInClosedModule.P3'(A, B, C) :-
        user:goedel_freeze(ground([A,C]), 'Programs':'~programs.DeclaredInClosedModule.P3.0'(A,B,C)).
'programs.DeclaredInClosedModule.P3.0'('ProgDefs.CachedProgram.F1'(A), B, C) :-
        'ProgramCache':'ProgramCache.GetCachedProgram.P2'(A, D),
        'programs.DeclaredInClosedModule.P3'(D, B, C).
'~programs.DeclaredInClosedModule.P3.0'('ProgDefs.CachedProgram.F1'(A), B, C) :-
        'ProgramCache':'~ProgramCache.GetCachedProgram.P2'(A, D),
        '~programs.DeclaredInClosedModule.P3'(D, B, C).
'programs.DeclaredInClosedModule.P3.0'('ProgDefs.Program.F4'(_,A,B,_), C, D) :-
        'Syntax':'Syntax.Atom.P1'(D),
        'Syntax':'Syntax.EmptyVarTyping.P1'(E),
        'SharedPrograms':'Sharedprograms.FormulaInLanguage.P4'(D, B, E, _),
        'programs.TopLevelName.P2'(D, 'MetaDefs.Name.F4'(C,_,_,_)),
        user:goedel_freeze(ground([C]), (user:not_equal([],[C],C,'"'),true->'AVLTrees':'AVLTrees.AVLSearch.P3'(A,C,'ProgDefs.ModDef.F4'('ProgDefs.ClosedKind.C0',_,_,_));true)).
'~programs.DeclaredInClosedModule.P3.0'('ProgDefs.Program.F4'(_,A,B,_), C, D) :-
        'Syntax':'~Syntax.Atom.P1'(D),
        'Syntax':'~Syntax.EmptyVarTyping.P1'(E),
        'SharedPrograms':'~Sharedprograms.FormulaInLanguage.P4'(D, B, E, _),
        '~programs.TopLevelName.P2'(D, 'MetaDefs.Name.F4'(C,_,_,_)),
        user:goedel_freeze(ground([C]), (user:not_equal([],[C],C,'"'),true->'AVLTrees':'~AVLTrees.AVLSearch.P3'(A,C,'ProgDefs.ModDef.F4'('ProgDefs.ClosedKind.C0',_,_,_));true)).
'programs.DeleteProgramConstant.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'programs.DeleteProgramConstant.P6.0'(A,B,C,D,E,F)).
'~programs.DeleteProgramConstant.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'~programs.DeleteProgramConstant.P6.0'(A,B,C,D,E,F)).
'programs.DeleteProgramConstant.P6.0'(A, B, C, D, E, F) :-
        'programs.DelDeclaration.P6'(F, B, C, D, 'ProgDefs.ConstantDecl.F1'(E), A).
'~programs.DeleteProgramConstant.P6.0'(A, B, C, D, E, F) :-
        '~programs.DelDeclaration.P6'(F, B, C, D, 'ProgDefs.ConstantDecl.F1'(E), A).
'programs.DelayInModule.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A]), 'Programs':'programs.DelayInModule.P5.0'(A,B,C,D,E)).
'~programs.DelayInModule.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A]), 'Programs':'~programs.DelayInModule.P5.0'(A,B,C,D,E)).
'programs.DelayInModule.P5.0'('ProgDefs.CachedProgram.F1'(A), B, C, D, E) :-
        'ProgramCache':'ProgramCache.GetCachedProgram.P2'(A, F),
        'programs.DelayInModule.P5'(F, B, C, D, E).
'~programs.DelayInModule.P5.0'('ProgDefs.CachedProgram.F1'(A), B, C, D, E) :-
        'ProgramCache':'~ProgramCache.GetCachedProgram.P2'(A, F),
        '~programs.DelayInModule.P5'(F, B, C, D, E).
'programs.DelayInModule.P5.0'('ProgDefs.Program.F4'(_,A,_,B), C, D, E, F) :-
        'programs.TopLevelName.P2'(E, 'MetaDefs.Name.F4'(C,G,_,H)),
        'SharedPrograms':'Sharedprograms.AVLFind.P3'(B, C, 'ProgDefs.Code.F2'(_,I)),
        'SharedPrograms':'Sharedprograms.AVLFind.P3'(I, G, J),
        'SharedPrograms':'Sharedprograms.FindPredDef.P3'(H, J, 'ProgDefs.PredDef.F4'(H,_,K,L)),
        'AVLTrees':'AVLTrees.AVLSearch.P3'(A, C, 'ProgDefs.ModDef.F4'(M,_,_,_)),
        'programs.DelayInKind.P5'(M, D, K, L, 'ProgDefs.Delay.F2'(E,F)).
'~programs.DelayInModule.P5.0'('ProgDefs.Program.F4'(_,A,_,B), C, D, E, F) :-
        '~programs.TopLevelName.P2'(E, 'MetaDefs.Name.F4'(C,G,_,H)),
        'SharedPrograms':'~Sharedprograms.AVLFind.P3'(B, C, 'ProgDefs.Code.F2'(_,I)),
        'SharedPrograms':'~Sharedprograms.AVLFind.P3'(I, G, J),
        'SharedPrograms':'~Sharedprograms.FindPredDef.P3'(H, J, 'ProgDefs.PredDef.F4'(H,_,K,L)),
        'AVLTrees':'~AVLTrees.AVLSearch.P3'(A, C, 'ProgDefs.ModDef.F4'(M,_,_,_)),
        '~programs.DelayInKind.P5'(M, D, K, L, 'ProgDefs.Delay.F2'(E,F)).
'programs.DelTypeDeclaration.P6'(A, B, C, D, E, F) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(F, G),
        'programs.CModulePart.P2'(C, H),
        'SharedPrograms':'Sharedprograms.ModulePartInProgram.P3'(G, B, H),
        user:goedel_freeze(ground([B]), user:goedel_not('SharedPrograms':'~Sharedprograms.SystemModule.P1'(B))),
        D='MetaDefs.Name.F4'(B,_,_,_),
        'programs.PartAccessibility.P2'(C, I),
        G='ProgDefs.Program.F4'(J,K,L,M),
        'programs.DeleteTypeSymbol.P5'(D, L, I, E, N),
        'programs.FreeTypeSymbol.P4'(B, C, D, G),
        A='ProgDefs.Program.F4'(J,K,N,M).
'~programs.DelTypeDeclaration.P6'(A, B, C, D, E, F) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(F, G),
        '~programs.CModulePart.P2'(C, H),
        'SharedPrograms':'~Sharedprograms.ModulePartInProgram.P3'(G, B, H),
        user:goedel_freeze(ground([B]), user:goedel_not('SharedPrograms':'~Sharedprograms.SystemModule.P1'(B))),
        D='MetaDefs.Name.F4'(B,_,_,_),
        '~programs.PartAccessibility.P2'(C, I),
        G='ProgDefs.Program.F4'(J,K,L,M),
        '~programs.DeleteTypeSymbol.P5'(D, L, I, E, N),
        '~programs.FreeTypeSymbol.P4'(B, C, D, G),
        A='ProgDefs.Program.F4'(J,K,N,M).
'programs.DefinitionInProgram.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A]), 'Programs':'programs.DefinitionInProgram.P4.0'(A,B,C,D)).
'~programs.DefinitionInProgram.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A]), 'Programs':'~programs.DefinitionInProgram.P4.0'(A,B,C,D)).
'programs.DefinitionInProgram.P4.0'('ProgDefs.CachedProgram.F1'(A), B, C, D) :-
        'ProgramCache':'ProgramCache.GetCachedProgram.P2'(A, E),
        'programs.DefinitionInProgram.P4'(E, B, C, D).
'~programs.DefinitionInProgram.P4.0'('ProgDefs.CachedProgram.F1'(A), B, C, D) :-
        'ProgramCache':'~ProgramCache.GetCachedProgram.P2'(A, E),
        '~programs.DefinitionInProgram.P4'(E, B, C, D).
'programs.DefinitionInProgram.P4.0'('ProgDefs.Program.F4'(_,A,B,C), D, E, F) :-
        E='MetaDefs.Name.F4'(D,G,H,I),
        'SharedPrograms':'Sharedprograms.OpenModuleAux.P2'(A, D),
        'programs.PredOrPropInLanguage.P3'(H, E, B),
        'AVLTrees':'AVLTrees.AVLSearch.P3'(C, D, 'ProgDefs.Code.F2'(_,J)),
        user:goedel_freeze(ground([I,J,G]), if((('AVLTrees':'~AVLTrees.AVLSearch.P3'(J,G,K),'SharedPrograms':'~Sharedprograms.FindPredDef.P3'(I,K,'ProgDefs.PredDef.F4'(I,L,_,_))),true),F=L,F=[])).
'~programs.DefinitionInProgram.P4.0'('ProgDefs.Program.F4'(_,A,B,C), D, E, F) :-
        E='MetaDefs.Name.F4'(D,G,H,I),
        'SharedPrograms':'~Sharedprograms.OpenModuleAux.P2'(A, D),
        '~programs.PredOrPropInLanguage.P3'(H, E, B),
        'AVLTrees':'~AVLTrees.AVLSearch.P3'(C, D, 'ProgDefs.Code.F2'(_,J)),
        user:goedel_freeze(ground([I,J,G]), if((('AVLTrees':'~AVLTrees.AVLSearch.P3'(J,G,K),'SharedPrograms':'~Sharedprograms.FindPredDef.P3'(I,K,'ProgDefs.PredDef.F4'(I,L,_,_))),true),F=L,F=[])).
'programs.DelDeclaration.P6'(A, B, C, D, E, F) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(F, G),
        'programs.CModulePart.P2'(C, H),
        'SharedPrograms':'Sharedprograms.ModulePartInProgram.P3'(G, B, H),
        user:goedel_freeze(ground([B]), user:goedel_not('SharedPrograms':'~Sharedprograms.SystemModule.P1'(B))),
        D='MetaDefs.Name.F4'(B,_,_,_),
        'programs.PartAccessibility.P2'(C, I),
        G='ProgDefs.Program.F4'(J,K,L,M),
        'programs.DeleteSymbol.P5'(D, L, I, E, N),
        'programs.FreeSymbol.P4'(B, C, D, G),
        A='ProgDefs.Program.F4'(J,K,N,M).
'~programs.DelDeclaration.P6'(A, B, C, D, E, F) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(F, G),
        '~programs.CModulePart.P2'(C, H),
        'SharedPrograms':'~Sharedprograms.ModulePartInProgram.P3'(G, B, H),
        user:goedel_freeze(ground([B]), user:goedel_not('SharedPrograms':'~Sharedprograms.SystemModule.P1'(B))),
        D='MetaDefs.Name.F4'(B,_,_,_),
        '~programs.PartAccessibility.P2'(C, I),
        G='ProgDefs.Program.F4'(J,K,L,M),
        '~programs.DeleteSymbol.P5'(D, L, I, E, N),
        '~programs.FreeSymbol.P4'(B, C, D, G),
        A='ProgDefs.Program.F4'(J,K,N,M).
'programs.DelayInKind.P5'('ProgDefs.NormalKind.C0', A, B, C, D) :-
        'programs.DelayInPart.P4'(A, B, C, D).
'~programs.DelayInKind.P5'('ProgDefs.NormalKind.C0', A, B, C, D) :-
        '~programs.DelayInPart.P4'(A, B, C, D).
'programs.DelayInKind.P5'('ProgDefs.ClosedKind.C0', 'programs.Closed.C0', A, _, B) :-
        'Lists':'Lists.Member.P2'(B, A).
'~programs.DelayInKind.P5'('ProgDefs.ClosedKind.C0', 'programs.Closed.C0', A, _, B) :-
        'Lists':'~Lists.Member.P2'(B, A).
'programs.DelayInKind.P5'('ProgDefs.ModuleKind.C0', 'programs.Module.C0', _, A, B) :-
        'Lists':'Lists.Member.P2'(B, A).
'~programs.DelayInKind.P5'('ProgDefs.ModuleKind.C0', 'programs.Module.C0', _, A, B) :-
        'Lists':'~Lists.Member.P2'(B, A).
'programs.DeleteDelay.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'programs.DeleteDelay.P6.0'(A,B,C,D,E,F)).
'~programs.DeleteDelay.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'~programs.DeleteDelay.P6.0'(A,B,C,D,E,F)).
'programs.DeleteDelay.P6.0'(A, B, C, D, E, 'ProgDefs.Program.F4'(F,G,H,I)) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, J),
        'programs.CModulePart.P2'(C, K),
        'SharedPrograms':'Sharedprograms.ModulePartInProgram.P3'(J, B, K),
        user:goedel_freeze(ground([B]), user:goedel_not('SharedPrograms':'~Sharedprograms.SystemModule.P1'(B))),
        'SharedPrograms':'Sharedprograms.NextModuleVersion.P2'(B, L),
        J='ProgDefs.Program.F4'(F,G,H,M),
        'AVLTrees':'AVLTrees.AVLUpdate.P5'(M, B, 'ProgDefs.Code.F2'(L,N), I, 'ProgDefs.Code.F2'(_,O)),
        D='MetaDefs.Atom.F2'('MetaDefs.Name.F4'(B,P,'MetaDefs.Predicate.C0',Q),_),
        'SharedPrograms':'Sharedprograms.AVLFind.P3'(O, P, R),
        'SharedPrograms':'Sharedprograms.PickPredDef.P4'(Q, R, 'ProgDefs.PredDef.F4'(Q,S,T,U), V),
        'programs.DeleteDelayFromPart.P6'(C, 'ProgDefs.Delay.F2'(D,E), T, U, W, X),
        user:goedel_freeze(ground([W,X,S]), ((S=[],W=[],X=[]),true->Y=V;Y=['ProgDefs.PredDef.F4'(Q,S,W,X)|V])),
        user:goedel_freeze(ground([Y]), (Y=[],true->'AVLTrees':'AVLTrees.AVLDelete.P3'(O,P,N);'AVLTrees':'AVLTrees.AVLUpdate.P5'(O,P,Y,N,_))).
'~programs.DeleteDelay.P6.0'(A, B, C, D, E, 'ProgDefs.Program.F4'(F,G,H,I)) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, J),
        '~programs.CModulePart.P2'(C, K),
        'SharedPrograms':'~Sharedprograms.ModulePartInProgram.P3'(J, B, K),
        user:goedel_freeze(ground([B]), user:goedel_not('SharedPrograms':'~Sharedprograms.SystemModule.P1'(B))),
        'SharedPrograms':'~Sharedprograms.NextModuleVersion.P2'(B, L),
        J='ProgDefs.Program.F4'(F,G,H,M),
        'AVLTrees':'~AVLTrees.AVLUpdate.P5'(M, B, 'ProgDefs.Code.F2'(L,N), I, 'ProgDefs.Code.F2'(_,O)),
        D='MetaDefs.Atom.F2'('MetaDefs.Name.F4'(B,P,'MetaDefs.Predicate.C0',Q),_),
        'SharedPrograms':'~Sharedprograms.AVLFind.P3'(O, P, R),
        'SharedPrograms':'~Sharedprograms.PickPredDef.P4'(Q, R, 'ProgDefs.PredDef.F4'(Q,S,T,U), V),
        '~programs.DeleteDelayFromPart.P6'(C, 'ProgDefs.Delay.F2'(D,E), T, U, W, X),
        user:goedel_freeze(ground([W,X,S]), ((S=[],W=[],X=[]),true->Y=V;Y=['ProgDefs.PredDef.F4'(Q,S,W,X)|V])),
        user:goedel_freeze(ground([Y]), (Y=[],true->'AVLTrees':'~AVLTrees.AVLDelete.P3'(O,P,N);'AVLTrees':'~AVLTrees.AVLUpdate.P5'(O,P,Y,N,_))).
'programs.DelayInPart.P4'('programs.Export.C0', A, _, B) :-
        'Lists':'Lists.Member.P2'(B, A).
'~programs.DelayInPart.P4'('programs.Export.C0', A, _, B) :-
        'Lists':'~Lists.Member.P2'(B, A).
'programs.DelayInPart.P4'('programs.Local.C0', _, A, B) :-
        'Lists':'Lists.Member.P2'(B, A).
'~programs.DelayInPart.P4'('programs.Local.C0', _, A, B) :-
        'Lists':'~Lists.Member.P2'(B, A).
'programs.DeleteImportFromPart.P6'('programs.Export.C0', A, B, C, D, C) :-
        'SharedPrograms':'Sharedprograms.PickOne.P3'(A, B, D).
'~programs.DeleteImportFromPart.P6'('programs.Export.C0', A, B, C, D, C) :-
        'SharedPrograms':'~Sharedprograms.PickOne.P3'(A, B, D).
'programs.DeleteImportFromPart.P6'('programs.Local.C0', A, B, C, B, D) :-
        'SharedPrograms':'Sharedprograms.PickOne.P3'(A, C, D).
'~programs.DeleteImportFromPart.P6'('programs.Local.C0', A, B, C, B, D) :-
        'SharedPrograms':'~Sharedprograms.PickOne.P3'(A, C, D).
'programs.DeleteImportFromPart.P6'('programs.Module.C0', A, B, C, B, D) :-
        'SharedPrograms':'Sharedprograms.PickOne.P3'(A, C, D).
'~programs.DeleteImportFromPart.P6'('programs.Module.C0', A, B, C, B, D) :-
        'SharedPrograms':'~Sharedprograms.PickOne.P3'(A, C, D).
'programs.DeleteDelayFromPart.P6'('programs.Export.C0', A, B, C, D, C) :-
        'SharedPrograms':'Sharedprograms.PickOne.P3'(A, B, D).
'~programs.DeleteDelayFromPart.P6'('programs.Export.C0', A, B, C, D, C) :-
        'SharedPrograms':'~Sharedprograms.PickOne.P3'(A, B, D).
'programs.DeleteDelayFromPart.P6'('programs.Local.C0', A, B, C, B, D) :-
        'SharedPrograms':'Sharedprograms.PickOne.P3'(A, C, D).
'~programs.DeleteDelayFromPart.P6'('programs.Local.C0', A, B, C, B, D) :-
        'SharedPrograms':'~Sharedprograms.PickOne.P3'(A, C, D).
'programs.DeleteDelayFromPart.P6'('programs.Module.C0', A, B, C, B, D) :-
        'SharedPrograms':'Sharedprograms.PickOne.P3'(A, C, D).
'~programs.DeleteDelayFromPart.P6'('programs.Module.C0', A, B, C, B, D) :-
        'SharedPrograms':'~Sharedprograms.PickOne.P3'(A, C, D).
'programs.DeleteProgramBase.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'programs.DeleteProgramBase.P5.0'(A,B,C,D,E)).
'~programs.DeleteProgramBase.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'~programs.DeleteProgramBase.P5.0'(A,B,C,D,E)).
'programs.DeleteProgramBase.P5.0'(A, B, C, D, E) :-
        'programs.DelTypeDeclaration.P6'(E, B, C, D, 'ProgDefs.BaseDecl.C0', A).
'~programs.DeleteProgramBase.P5.0'(A, B, C, D, E) :-
        '~programs.DelTypeDeclaration.P6'(E, B, C, D, 'ProgDefs.BaseDecl.C0', A).
'programs.DeleteProgramPredicate.P7'(A, B, C, D, E, F, G) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'programs.DeleteProgramPredicate.P7.0'(A,B,C,D,E,F,G)).
'~programs.DeleteProgramPredicate.P7'(A, B, C, D, E, F, G) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'~programs.DeleteProgramPredicate.P7.0'(A,B,C,D,E,F,G)).
'programs.DeleteProgramPredicate.P7.0'(A, B, C, D, E, F, G) :-
        'programs.DelDeclaration.P6'(G, B, C, D, 'ProgDefs.PredicateDecl.F3'(_,E,F), A).
'~programs.DeleteProgramPredicate.P7.0'(A, B, C, D, E, F, G) :-
        '~programs.DelDeclaration.P6'(G, B, C, D, 'ProgDefs.PredicateDecl.F3'(_,E,F), A).
'programs.DeleteProgramFunction.P8'(A, B, C, D, E, F, G, H) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'programs.DeleteProgramFunction.P8.0'(A,B,C,D,E,F,G,H)).
'~programs.DeleteProgramFunction.P8'(A, B, C, D, E, F, G, H) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'~programs.DeleteProgramFunction.P8.0'(A,B,C,D,E,F,G,H)).
'programs.DeleteProgramFunction.P8.0'(A, B, C, D, E, F, G, H) :-
        'programs.DelDeclaration.P6'(H, B, C, D, 'ProgDefs.FunctionDecl.F4'(_,E,F,G), A).
'~programs.DeleteProgramFunction.P8.0'(A, B, C, D, E, F, G, H) :-
        '~programs.DelDeclaration.P6'(H, B, C, D, 'ProgDefs.FunctionDecl.F4'(_,E,F,G), A).
'programs.DeleteProgramConstructor.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'programs.DeleteProgramConstructor.P6.0'(A,B,C,D,E,F)).
'~programs.DeleteProgramConstructor.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'~programs.DeleteProgramConstructor.P6.0'(A,B,C,D,E,F)).
'programs.DeleteProgramConstructor.P6.0'(A, B, C, D, E, F) :-
        'programs.DelTypeDeclaration.P6'(F, B, C, D, 'ProgDefs.ConstructorDecl.F1'(E), A).
'~programs.DeleteProgramConstructor.P6.0'(A, B, C, D, E, F) :-
        '~programs.DelTypeDeclaration.P6'(F, B, C, D, 'ProgDefs.ConstructorDecl.F1'(E), A).
'programs.DeleteProgramImport.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'programs.DeleteProgramImport.P5.0'(A,B,C,D,E)).
'~programs.DeleteProgramImport.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'~programs.DeleteProgramImport.P5.0'(A,B,C,D,E)).
'programs.DeleteProgramImport.P5.0'('ProgDefs.CachedProgram.F1'(A), B, C, D, E) :-
        'ProgramCache':'ProgramCache.GetCachedProgram.P2'(A, E),
        'programs.DeleteProgramImport.P5'(E, B, C, D, E).
'~programs.DeleteProgramImport.P5.0'('ProgDefs.CachedProgram.F1'(A), B, C, D, E) :-
        'ProgramCache':'~ProgramCache.GetCachedProgram.P2'(A, E),
        '~programs.DeleteProgramImport.P5'(E, B, C, D, E).
'programs.DeleteProgramImport.P5.0'('ProgDefs.Program.F4'(A,B,'ProgDefs.Language.F1'(C),D), E, F, G, 'ProgDefs.Program.F4'(A,H,'ProgDefs.Language.F1'(I),J)) :-
        'programs.CModulePart.P2'(F, K),
        'AVLTrees':'AVLTrees.AVLUpdate.P5'(B, E, 'ProgDefs.ModDef.F4'(L,M,N,O), P, 'ProgDefs.ModDef.F4'(L,Q,R,O)),
        'SharedPrograms':'Sharedprograms.OpenKind.P1'(L),
        'SharedPrograms':'Sharedprograms.KindHasPart.P2'(L, K),
        'programs.DeleteImportFromPart.P6'(F, G, Q, R, M, N),
        user:goedel_freeze(ground([G,B]), ('Programs':'~programs.UnreferencedModule.P2'(G,B),true->'AVLTrees':'AVLTrees.AVLDelete.P3'(P,G,H),'AVLTrees':'AVLTrees.AVLDelete.P3'(C,G,I),'AVLTrees':'AVLTrees.AVLDelete.P3'(D,G,J);H=P,I=C,J=D)).
'~programs.DeleteProgramImport.P5.0'('ProgDefs.Program.F4'(A,B,'ProgDefs.Language.F1'(C),D), E, F, G, 'ProgDefs.Program.F4'(A,H,'ProgDefs.Language.F1'(I),J)) :-
        '~programs.CModulePart.P2'(F, K),
        'AVLTrees':'~AVLTrees.AVLUpdate.P5'(B, E, 'ProgDefs.ModDef.F4'(L,M,N,O), P, 'ProgDefs.ModDef.F4'(L,Q,R,O)),
        'SharedPrograms':'~Sharedprograms.OpenKind.P1'(L),
        'SharedPrograms':'~Sharedprograms.KindHasPart.P2'(L, K),
        '~programs.DeleteImportFromPart.P6'(F, G, Q, R, M, N),
        user:goedel_freeze(ground([G,B]), ('Programs':'~programs.UnreferencedModule.P2'(G,B),true->'AVLTrees':'~AVLTrees.AVLDelete.P3'(P,G,H),'AVLTrees':'~AVLTrees.AVLDelete.P3'(C,G,I),'AVLTrees':'~AVLTrees.AVLDelete.P3'(D,G,J);H=P,I=C,J=D)).
'programs.DeleteStatement.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B]), 'Programs':'programs.DeleteStatement.P4.0'(A,B,C,D)).
'~programs.DeleteStatement.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B]), 'Programs':'~programs.DeleteStatement.P4.0'(A,B,C,D)).
'programs.DeleteStatement.P4.0'('ProgDefs.CachedProgram.F1'(A), B, C, D) :-
        'ProgramCache':'ProgramCache.GetCachedProgram.P2'(A, E),
        'programs.DeleteStatement.P4'(E, B, C, D).
'~programs.DeleteStatement.P4.0'('ProgDefs.CachedProgram.F1'(A), B, C, D) :-
        'ProgramCache':'~ProgramCache.GetCachedProgram.P2'(A, E),
        '~programs.DeleteStatement.P4'(E, B, C, D).
'programs.DeleteStatement.P4.0'('ProgDefs.Program.F4'(A,B,C,D), E, F, 'ProgDefs.Program.F4'(A,B,C,G)) :-
        user:goedel_freeze(ground([E]), user:goedel_not('SharedPrograms':'~Sharedprograms.SystemModule.P1'(E))),
        'SharedPrograms':'Sharedprograms.NextModuleVersion.P2'(E, H),
        'AVLTrees':'AVLTrees.AVLUpdate.P5'(D, E, 'ProgDefs.Code.F2'(H,I), G, 'ProgDefs.Code.F2'(_,J)),
        'programs.OpenStatementPredicate.P2'(F, 'MetaDefs.Name.F4'(_,K,_,L)),
        'SharedPrograms':'Sharedprograms.AVLFind.P3'(J, K, M),
        'SharedPrograms':'Sharedprograms.PickPredDef.P4'(L, M, 'ProgDefs.PredDef.F4'(L,N,O,P), Q),
        'Lists':'Lists.Delete.P3'(F, N, R),
        user:goedel_freeze(ground([O,P,R]), ((R=[],O=[],P=[]),true->S=Q;S=['ProgDefs.PredDef.F4'(L,R,O,P)|Q])),
        user:goedel_freeze(ground([S]), (S=[],true->'AVLTrees':'AVLTrees.AVLDelete.P3'(J,K,I);'AVLTrees':'AVLTrees.AVLUpdate.P5'(J,K,S,I,_))).
'~programs.DeleteStatement.P4.0'('ProgDefs.Program.F4'(A,B,C,D), E, F, 'ProgDefs.Program.F4'(A,B,C,G)) :-
        user:goedel_freeze(ground([E]), user:goedel_not('SharedPrograms':'~Sharedprograms.SystemModule.P1'(E))),
        'SharedPrograms':'~Sharedprograms.NextModuleVersion.P2'(E, H),
        'AVLTrees':'~AVLTrees.AVLUpdate.P5'(D, E, 'ProgDefs.Code.F2'(H,I), G, 'ProgDefs.Code.F2'(_,J)),
        '~programs.OpenStatementPredicate.P2'(F, 'MetaDefs.Name.F4'(_,K,_,L)),
        'SharedPrograms':'~Sharedprograms.AVLFind.P3'(J, K, M),
        'SharedPrograms':'~Sharedprograms.PickPredDef.P4'(L, M, 'ProgDefs.PredDef.F4'(L,N,O,P), Q),
        'Lists':'~Lists.Delete.P3'(F, N, R),
        user:goedel_freeze(ground([O,P,R]), ((R=[],O=[],P=[]),true->S=Q;S=['ProgDefs.PredDef.F4'(L,R,O,P)|Q])),
        user:goedel_freeze(ground([S]), (S=[],true->'AVLTrees':'~AVLTrees.AVLDelete.P3'(J,K,I);'AVLTrees':'~AVLTrees.AVLUpdate.P5'(J,K,S,I,_))).
'programs.DeleteProgramProposition.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'programs.DeleteProgramProposition.P5.0'(A,B,C,D,E)).
'~programs.DeleteProgramProposition.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'~programs.DeleteProgramProposition.P5.0'(A,B,C,D,E)).
'programs.DeleteProgramProposition.P5.0'(A, B, C, D, E) :-
        'programs.DelDeclaration.P6'(E, B, C, D, 'ProgDefs.PropositionDecl.C0', A).
'~programs.DeleteProgramProposition.P5.0'(A, B, C, D, E) :-
        '~programs.DelDeclaration.P6'(E, B, C, D, 'ProgDefs.PropositionDecl.C0', A).
'programs.DeleteTypeSymbol.P5'('MetaDefs.Name.F4'(A,B,C,D), 'ProgDefs.Language.F1'(E), F, G, 'ProgDefs.Language.F1'(H)) :-
        'SharedPrograms':'Sharedprograms.AVLFind.P3'(E, A, 'ProgDefs.Module.F3'(I,'ProgDefs.Categories.F2'(J,K),L)),
        'SharedPrograms':'Sharedprograms.AVLFind.P3'(J, B, M),
        'SharedPrograms':'Sharedprograms.FindDescriptor.P5'(M, I, C, D, G),
        'Lists':'Lists.DeleteFirst.P3'('ProgDefs.Symbol.F2'(F,G), M, N),
        user:goedel_freeze(ground([N]), (N=[],true->'AVLTrees':'AVLTrees.AVLDelete.P3'(J,B,O);'AVLTrees':'AVLTrees.AVLUpdate.P5'(J,B,N,O,_))),
        'AVLTrees':'AVLTrees.AVLUpdate.P5'(E, A, 'ProgDefs.Module.F3'(I,'ProgDefs.Categories.F2'(O,K),L), H, _).
'~programs.DeleteTypeSymbol.P5'('MetaDefs.Name.F4'(A,B,C,D), 'ProgDefs.Language.F1'(E), F, G, 'ProgDefs.Language.F1'(H)) :-
        'SharedPrograms':'~Sharedprograms.AVLFind.P3'(E, A, 'ProgDefs.Module.F3'(I,'ProgDefs.Categories.F2'(J,K),L)),
        'SharedPrograms':'~Sharedprograms.AVLFind.P3'(J, B, M),
        'SharedPrograms':'~Sharedprograms.FindDescriptor.P5'(M, I, C, D, G),
        'Lists':'~Lists.DeleteFirst.P3'('ProgDefs.Symbol.F2'(F,G), M, N),
        user:goedel_freeze(ground([N]), (N=[],true->'AVLTrees':'~AVLTrees.AVLDelete.P3'(J,B,O);'AVLTrees':'~AVLTrees.AVLUpdate.P5'(J,B,N,O,_))),
        'AVLTrees':'~AVLTrees.AVLUpdate.P5'(E, A, 'ProgDefs.Module.F3'(I,'ProgDefs.Categories.F2'(O,K),L), H, _).
'programs.DeleteSymbol.P5'('MetaDefs.Name.F4'(A,B,C,D), 'ProgDefs.Language.F1'(E), F, G, 'ProgDefs.Language.F1'(H)) :-
        'SharedPrograms':'Sharedprograms.AVLFind.P3'(E, A, 'ProgDefs.Module.F3'(I,'ProgDefs.Categories.F2'(J,K),L)),
        'SharedPrograms':'Sharedprograms.AVLFind.P3'(K, B, M),
        'SharedPrograms':'Sharedprograms.FindDescriptor.P5'(M, I, C, D, G),
        'Lists':'Lists.DeleteFirst.P3'('ProgDefs.Symbol.F2'(F,G), M, N),
        user:goedel_freeze(ground([N]), (N=[],true->'AVLTrees':'AVLTrees.AVLDelete.P3'(K,B,O);'AVLTrees':'AVLTrees.AVLUpdate.P5'(K,B,N,O,_))),
        'AVLTrees':'AVLTrees.AVLUpdate.P5'(E, A, 'ProgDefs.Module.F3'(I,'ProgDefs.Categories.F2'(J,O),L), H, _).
'~programs.DeleteSymbol.P5'('MetaDefs.Name.F4'(A,B,C,D), 'ProgDefs.Language.F1'(E), F, G, 'ProgDefs.Language.F1'(H)) :-
        'SharedPrograms':'~Sharedprograms.AVLFind.P3'(E, A, 'ProgDefs.Module.F3'(I,'ProgDefs.Categories.F2'(J,K),L)),
        'SharedPrograms':'~Sharedprograms.AVLFind.P3'(K, B, M),
        'SharedPrograms':'~Sharedprograms.FindDescriptor.P5'(M, I, C, D, G),
        'Lists':'~Lists.DeleteFirst.P3'('ProgDefs.Symbol.F2'(F,G), M, N),
        user:goedel_freeze(ground([N]), (N=[],true->'AVLTrees':'~AVLTrees.AVLDelete.P3'(K,B,O);'AVLTrees':'~AVLTrees.AVLUpdate.P5'(K,B,N,O,_))),
        'AVLTrees':'~AVLTrees.AVLUpdate.P5'(E, A, 'ProgDefs.Module.F3'(I,'ProgDefs.Categories.F2'(J,O),L), H, _).
'programs.Fail.P2'(A, B) :-
        user:goedel_freeze(ground([A,B]), 'Programs':'programs.Fail.P2.0'(A,B)).
'~programs.Fail.P2'(A, B) :-
        user:goedel_freeze(ground([A,B]), 'Programs':'~programs.Fail.P2.0'(A,B)).
'programs.Fail.P2.0'(A, B) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, C),
        'SharedPrograms':'Sharedprograms.ProgramLanguage.P2'(C, D),
        'SharedPrograms':'Sharedprograms.MeltedBodyTyping.P8'(B, D, [], _, _, [], [], []),
        'programs.CompileObjectProgram.P1'(C),
        'programs.FailedGoal.P1'(B).
'~programs.Fail.P2.0'(A, B) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, C),
        'SharedPrograms':'~Sharedprograms.ProgramLanguage.P2'(C, D),
        'SharedPrograms':'~Sharedprograms.MeltedBodyTyping.P8'(B, D, [], _, _, [], [], []),
        '~programs.CompileObjectProgram.P1'(C),
        '~programs.FailedGoal.P1'(B).
'programs.InsertProgramBase.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A,B,C,D]), 'Programs':'programs.InsertProgramBase.P5.0'(A,B,C,D,E)).
'~programs.InsertProgramBase.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A,B,C,D]), 'Programs':'~programs.InsertProgramBase.P5.0'(A,B,C,D,E)).
'programs.InsertProgramBase.P5.0'(A, B, C, D, E) :-
        'programs.InsTypeDeclaration.P6'(A, B, C, D, 'ProgDefs.BaseDecl.C0', E).
'~programs.InsertProgramBase.P5.0'(A, B, C, D, E) :-
        '~programs.InsTypeDeclaration.P6'(A, B, C, D, 'ProgDefs.BaseDecl.C0', E).
'programs.GroundCondition.P2'('MetaDefs.Var.F2'(A,B), 'ProgDefs.Ground.F1'('MetaDefs.Var.F2'(A,B))).
'~programs.GroundCondition.P2'('MetaDefs.Var.F2'(A,B), 'ProgDefs.Ground.F1'('MetaDefs.Var.F2'(A,B))).
'programs.GroundCondition.P2'('MetaDefs.Var.F1'(A), 'ProgDefs.Ground.F1'('MetaDefs.Var.F1'(A))).
'~programs.GroundCondition.P2'('MetaDefs.Var.F1'(A), 'ProgDefs.Ground.F1'('MetaDefs.Var.F1'(A))).
'programs.FreeTypeSymbol.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([B]), (B='programs.Export.C0',true->'Programs':'programs.TypeSymbolFreeInModule.P3'(A,C,D),D='ProgDefs.Program.F4'(_,E,_,_),user:goedel_freeze(ground([A,E,C,D]),user:goedel_not((('AVLTrees':'~AVLTrees.AVLMember.P3'(E,F,G),user:not_equal([],[F,A],F,A),'Programs':'~programs.ModuleImported.P3'(A,G,E)),user:goedel_freeze(ground([F,C,D]),user:goedel_not('Programs':'~programs.TypeSymbolFreeInModule.P3'(F,C,D))))));'Programs':'programs.TypeSymbolFreeInModule.P3'(A,C,D))).
'~programs.FreeTypeSymbol.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([B]), (B='programs.Export.C0',true->'Programs':'~programs.TypeSymbolFreeInModule.P3'(A,C,D),D='ProgDefs.Program.F4'(_,E,_,_),user:goedel_freeze(ground([A,E,C,D]),user:goedel_not((('AVLTrees':'~AVLTrees.AVLMember.P3'(E,F,G),user:not_equal([],[F,A],F,A),'Programs':'~programs.ModuleImported.P3'(A,G,E)),user:goedel_freeze(ground([F,C,D]),user:goedel_not('Programs':'~programs.TypeSymbolFreeInModule.P3'(F,C,D))))));'Programs':'~programs.TypeSymbolFreeInModule.P3'(A,C,D))).
'programs.FormulaInProgram.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'programs.FormulaInProgram.P4.0'(A,B,C,D)).
'~programs.FormulaInProgram.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'~programs.FormulaInProgram.P4.0'(A,B,C,D)).
'programs.FormulaInProgram.P4.0'('ProgDefs.CachedProgram.F1'(A), B, C, D) :-
        'ProgramCache':'ProgramCache.GetCachedProgram.P2'(A, E),
        'programs.FormulaInProgram.P4'(E, B, C, D).
'~programs.FormulaInProgram.P4.0'('ProgDefs.CachedProgram.F1'(A), B, C, D) :-
        'ProgramCache':'~ProgramCache.GetCachedProgram.P2'(A, E),
        '~programs.FormulaInProgram.P4'(E, B, C, D).
'programs.FormulaInProgram.P4.0'('ProgDefs.Program.F4'(_,_,A,_), B, C, D) :-
        'SharedPrograms':'Sharedprograms.FormulaInLanguage.P4'(C, A, B, D).
'~programs.FormulaInProgram.P4.0'('ProgDefs.Program.F4'(_,_,A,_), B, C, D) :-
        'SharedPrograms':'~Sharedprograms.FormulaInLanguage.P4'(C, A, B, D).
'programs.FreeSymbol.P4'(A, B, C, D) :-
        'programs.SymbolFreeInModule.P3'(A, C, D),
        user:goedel_freeze(ground([B]), (B='programs.Export.C0',true->D='ProgDefs.Program.F4'(_,E,_,_),user:goedel_freeze(ground([A,E,C,D]),user:goedel_not((('AVLTrees':'~AVLTrees.AVLMember.P3'(E,F,G),user:not_equal([],[F,A],F,A),'Programs':'~programs.ModuleImported.P3'(A,G,E)),user:goedel_freeze(ground([F,C,D]),user:goedel_not('Programs':'~programs.SymbolFreeInModule.P3'(F,C,D))))));true)).
'~programs.FreeSymbol.P4'(A, B, C, D) :-
        '~programs.SymbolFreeInModule.P3'(A, C, D),
        user:goedel_freeze(ground([B]), (B='programs.Export.C0',true->D='ProgDefs.Program.F4'(_,E,_,_),user:goedel_freeze(ground([A,E,C,D]),user:goedel_not((('AVLTrees':'~AVLTrees.AVLMember.P3'(E,F,G),user:not_equal([],[F,A],F,A),'Programs':'~programs.ModuleImported.P3'(A,G,E)),user:goedel_freeze(ground([F,C,D]),user:goedel_not('Programs':'~programs.SymbolFreeInModule.P3'(F,C,D))))));true)).
'programs.FunctionInModule.P8'(A, B, C, D, E, F, G, H) :-
        user:goedel_freeze(ground([A]), 'Programs':'programs.FunctionInModule.P8.0'(A,B,C,D,E,F,G,H)).
'~programs.FunctionInModule.P8'(A, B, C, D, E, F, G, H) :-
        user:goedel_freeze(ground([A]), 'Programs':'~programs.FunctionInModule.P8.0'(A,B,C,D,E,F,G,H)).
'programs.FunctionInModule.P8.0'(A, B, C, D, E, F, G, H) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, I),
        'programs.CModulePart.P2'(C, J),
        'SharedPrograms':'Sharedprograms.ModulePartInProgram.P3'(I, B, J),
        'programs.ModulePartLanguage.P4'(J, B, I, K),
        'SharedPrograms':'Sharedprograms.FunctionInLanguage.P5'(D, K, E, F, G),
        D='MetaDefs.Name.F4'(H,_,_,_).
'~programs.FunctionInModule.P8.0'(A, B, C, D, E, F, G, H) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, I),
        '~programs.CModulePart.P2'(C, J),
        'SharedPrograms':'~Sharedprograms.ModulePartInProgram.P3'(I, B, J),
        '~programs.ModulePartLanguage.P4'(J, B, I, K),
        'SharedPrograms':'~Sharedprograms.FunctionInLanguage.P5'(D, K, E, F, G),
        D='MetaDefs.Name.F4'(H,_,_,_).
'programs.ImportInModule.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A]), 'Programs':'programs.ImportInModule.P4.0'(A,B,C,D)).
'~programs.ImportInModule.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A]), 'Programs':'~programs.ImportInModule.P4.0'(A,B,C,D)).
'programs.ImportInModule.P4.0'('ProgDefs.CachedProgram.F1'(A), B, C, D) :-
        'ProgramCache':'ProgramCache.GetCachedProgram.P2'(A, E),
        'programs.ImportInModule.P4'(E, B, C, D).
'~programs.ImportInModule.P4.0'('ProgDefs.CachedProgram.F1'(A), B, C, D) :-
        'ProgramCache':'~ProgramCache.GetCachedProgram.P2'(A, E),
        '~programs.ImportInModule.P4'(E, B, C, D).
'programs.ImportInModule.P4.0'('ProgDefs.Program.F4'(_,A,_,_), B, C, D) :-
        'SharedPrograms':'Sharedprograms.AVLFind.P3'(A, B, 'ProgDefs.ModDef.F4'(E,F,G,_)),
        'programs.ImportInPart.P5'(C, E, F, G, D).
'~programs.ImportInModule.P4.0'('ProgDefs.Program.F4'(_,A,_,_), B, C, D) :-
        'SharedPrograms':'~Sharedprograms.AVLFind.P3'(A, B, 'ProgDefs.ModDef.F4'(E,F,G,_)),
        '~programs.ImportInPart.P5'(C, E, F, G, D).
'programs.HasIntensionalSet.P1'('MetaDefs.Term.F2'(_,A)) :-
        'programs.HasIntensionalSet1.P1'(A).
'~programs.HasIntensionalSet.P1'('MetaDefs.Term.F2'(_,A)) :-
        '~programs.HasIntensionalSet1.P1'(A).
'programs.HasIntensionalSet.P1'('MetaDefs.SuchThat.F2'(_,_)).
'~programs.HasIntensionalSet.P1'('MetaDefs.SuchThat.F2'(_,_)).
'programs.HasIntensionalSet1.P1'([A|B]) :-
        (   'programs.HasIntensionalSet.P1'(A)
        ;   'programs.HasIntensionalSet1.P1'(B)
        ).
'~programs.HasIntensionalSet1.P1'([A|B]) :-
        (   '~programs.HasIntensionalSet.P1'(A)
        ;   '~programs.HasIntensionalSet1.P1'(B)
        ).
'programs.InsTypeDeclaration.P6'(A, B, C, D, E, F) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, G),
        'programs.CModulePart.P2'(C, H),
        'SharedPrograms':'Sharedprograms.ModulePartInProgram.P3'(G, B, H),
        user:goedel_freeze(ground([B]), user:goedel_not('SharedPrograms':'~Sharedprograms.SystemModule.P1'(B))),
        D='MetaDefs.Name.F4'(B,_,_,_),
        'programs.ValidDeclaration.P4'(E, G, B, C),
        'programs.PartAccessibility.P2'(C, I),
        G='ProgDefs.Program.F4'(J,K,L,M),
        'SharedPrograms':'Sharedprograms.InsertTypeSymbol.P5'(D, L, I, E, N),
        F='ProgDefs.Program.F4'(J,K,N,M).
'~programs.InsTypeDeclaration.P6'(A, B, C, D, E, F) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, G),
        '~programs.CModulePart.P2'(C, H),
        'SharedPrograms':'~Sharedprograms.ModulePartInProgram.P3'(G, B, H),
        user:goedel_freeze(ground([B]), user:goedel_not('SharedPrograms':'~Sharedprograms.SystemModule.P1'(B))),
        D='MetaDefs.Name.F4'(B,_,_,_),
        '~programs.ValidDeclaration.P4'(E, G, B, C),
        '~programs.PartAccessibility.P2'(C, I),
        G='ProgDefs.Program.F4'(J,K,L,M),
        'SharedPrograms':'~Sharedprograms.InsertTypeSymbol.P5'(D, L, I, E, N),
        F='ProgDefs.Program.F4'(J,K,N,M).
'programs.InsDeclaration.P6'(A, B, C, D, E, F) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, G),
        'programs.CModulePart.P2'(C, H),
        'SharedPrograms':'Sharedprograms.ModulePartInProgram.P3'(G, B, H),
        user:goedel_freeze(ground([B]), user:goedel_not('SharedPrograms':'~Sharedprograms.SystemModule.P1'(B))),
        D='MetaDefs.Name.F4'(B,_,_,_),
        'programs.ValidDeclaration.P4'(E, G, B, C),
        'programs.PartAccessibility.P2'(C, I),
        G='ProgDefs.Program.F4'(J,K,L,M),
        'SharedPrograms':'Sharedprograms.InsertSymbol.P5'(D, L, I, E, N),
        F='ProgDefs.Program.F4'(J,K,N,M).
'~programs.InsDeclaration.P6'(A, B, C, D, E, F) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, G),
        '~programs.CModulePart.P2'(C, H),
        'SharedPrograms':'~Sharedprograms.ModulePartInProgram.P3'(G, B, H),
        user:goedel_freeze(ground([B]), user:goedel_not('SharedPrograms':'~Sharedprograms.SystemModule.P1'(B))),
        D='MetaDefs.Name.F4'(B,_,_,_),
        '~programs.ValidDeclaration.P4'(E, G, B, C),
        '~programs.PartAccessibility.P2'(C, I),
        G='ProgDefs.Program.F4'(J,K,L,M),
        'SharedPrograms':'~Sharedprograms.InsertSymbol.P5'(D, L, I, E, N),
        F='ProgDefs.Program.F4'(J,K,N,M).
'programs.ImportInPart.P5'('programs.Closed.C0', _, A, _, B) :-
        'SharedPrograms':'Sharedprograms.FindMember.P2'(B, A).
'~programs.ImportInPart.P5'('programs.Closed.C0', _, A, _, B) :-
        'SharedPrograms':'~Sharedprograms.FindMember.P2'(B, A).
'programs.ImportInPart.P5'('programs.Export.C0', _, A, _, B) :-
        'SharedPrograms':'Sharedprograms.FindMember.P2'(B, A).
'~programs.ImportInPart.P5'('programs.Export.C0', _, A, _, B) :-
        'SharedPrograms':'~Sharedprograms.FindMember.P2'(B, A).
'programs.ImportInPart.P5'('programs.Module.C0', _, _, A, B) :-
        'SharedPrograms':'Sharedprograms.FindMember.P2'(B, A).
'~programs.ImportInPart.P5'('programs.Module.C0', _, _, A, B) :-
        'SharedPrograms':'~Sharedprograms.FindMember.P2'(B, A).
'programs.ImportInPart.P5'('programs.Local.C0', A, _, B, C) :-
        user:not_equal([], [A], A, 'ProgDefs.ClosedKind.C0'),
        'SharedPrograms':'Sharedprograms.FindMember.P2'(C, B).
'~programs.ImportInPart.P5'('programs.Local.C0', A, _, B, C) :-
        user:not_equal([], [A], A, 'ProgDefs.ClosedKind.C0'),
        'SharedPrograms':'~Sharedprograms.FindMember.P2'(C, B).
'programs.InsertDelay.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(ground([A,B,C,D,E]), 'Programs':'programs.InsertDelay.P6.0'(A,B,C,D,E,F)).
'~programs.InsertDelay.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(ground([A,B,C,D,E]), 'Programs':'~programs.InsertDelay.P6.0'(A,B,C,D,E,F)).
'programs.InsertDelay.P6.0'(A, B, C, D, E, 'ProgDefs.Program.F4'(F,G,H,I)) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, J),
        'programs.CModulePart.P2'(C, K),
        'SharedPrograms':'Sharedprograms.ModulePartInProgram.P3'(J, B, K),
        user:not_equal([], [K], K, 'ProgDefs.Closed.C0'),
        'SharedPrograms':'Sharedprograms.ModuleLanguage.P3'(J, B, H),
        'Syntax':'Syntax.EmptyVarTyping.P1'(L),
        'SharedPrograms':'Sharedprograms.FormulaInLanguage.P4'(D, H, L, _),
        'Syntax':'Syntax.PredicateAtom.P3'(D, 'MetaDefs.Name.F4'(B,M,_,N), _),
        'programs.IntensionalSetFree.P1'(D),
        'SharedPrograms':'Sharedprograms.NextModuleVersion.P2'(B, O),
        J='ProgDefs.Program.F4'(F,G,H,P),
        'AVLTrees':'AVLTrees.AVLUpdate.P5'(P, B, 'ProgDefs.Code.F2'(O,Q), I, 'ProgDefs.Code.F2'(_,R)),
        'AVLTrees':'AVLTrees.AVLAmend.P6'(R, M, S, [], Q, T),
        user:goedel_freeze(ground([N,T]), if(('Lists':'~Lists.DeleteFirst.P3'('ProgDefs.PredDef.F4'(N,U,V,W),T,X),true),('SharedPrograms':'Sharedprograms.UpdateDelays.P6'(K,'ProgDefs.Delay.F2'(D,E),V,W,Y,Z),S=['ProgDefs.PredDef.F4'(N,U,Y,Z)|X]),('SharedPrograms':'Sharedprograms.UpdateDelays.P6'(K,'ProgDefs.Delay.F2'(D,E),[],[],Y,Z),S=['ProgDefs.PredDef.F4'(N,[],Y,Z)|T]))).
'~programs.InsertDelay.P6.0'(A, B, C, D, E, 'ProgDefs.Program.F4'(F,G,H,I)) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, J),
        '~programs.CModulePart.P2'(C, K),
        'SharedPrograms':'~Sharedprograms.ModulePartInProgram.P3'(J, B, K),
        user:not_equal([], [K], K, 'ProgDefs.Closed.C0'),
        'SharedPrograms':'~Sharedprograms.ModuleLanguage.P3'(J, B, H),
        'Syntax':'~Syntax.EmptyVarTyping.P1'(L),
        'SharedPrograms':'~Sharedprograms.FormulaInLanguage.P4'(D, H, L, _),
        'Syntax':'~Syntax.PredicateAtom.P3'(D, 'MetaDefs.Name.F4'(B,M,_,N), _),
        '~programs.IntensionalSetFree.P1'(D),
        'SharedPrograms':'~Sharedprograms.NextModuleVersion.P2'(B, O),
        J='ProgDefs.Program.F4'(F,G,H,P),
        'AVLTrees':'~AVLTrees.AVLUpdate.P5'(P, B, 'ProgDefs.Code.F2'(O,Q), I, 'ProgDefs.Code.F2'(_,R)),
        'AVLTrees':'~AVLTrees.AVLAmend.P6'(R, M, S, [], Q, T),
        user:goedel_freeze(ground([N,T]), if(('Lists':'~Lists.DeleteFirst.P3'('ProgDefs.PredDef.F4'(N,U,V,W),T,X),true),('SharedPrograms':'~Sharedprograms.UpdateDelays.P6'(K,'ProgDefs.Delay.F2'(D,E),V,W,Y,Z),S=['ProgDefs.PredDef.F4'(N,U,Y,Z)|X]),('SharedPrograms':'~Sharedprograms.UpdateDelays.P6'(K,'ProgDefs.Delay.F2'(D,E),[],[],Y,Z),S=['ProgDefs.PredDef.F4'(N,[],Y,Z)|T]))).
'programs.InsertProgramProposition.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A,B,C,D]), 'Programs':'programs.InsertProgramProposition.P5.0'(A,B,C,D,E)).
'~programs.InsertProgramProposition.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A,B,C,D]), 'Programs':'~programs.InsertProgramProposition.P5.0'(A,B,C,D,E)).
'programs.InsertProgramProposition.P5.0'(A, B, C, D, E) :-
        'programs.InsDeclaration.P6'(A, B, C, D, 'ProgDefs.PropositionDecl.C0', E).
'~programs.InsertProgramProposition.P5.0'(A, B, C, D, E) :-
        '~programs.InsDeclaration.P6'(A, B, C, D, 'ProgDefs.PropositionDecl.C0', E).
'programs.InsertProgramFunction.P8'(A, B, C, D, E, F, G, H) :-
        user:goedel_freeze(ground([A,B,C,D,E,F,G]), 'Programs':'programs.InsertProgramFunction.P8.0'(A,B,C,D,E,F,G,H)).
'~programs.InsertProgramFunction.P8'(A, B, C, D, E, F, G, H) :-
        user:goedel_freeze(ground([A,B,C,D,E,F,G]), 'Programs':'~programs.InsertProgramFunction.P8.0'(A,B,C,D,E,F,G,H)).
'programs.InsertProgramFunction.P8.0'(A, B, C, D, E, F, G, H) :-
        'programs.InsDeclaration.P6'(A, B, C, D, 'ProgDefs.FunctionDecl.F4'(_,E,F,G), H).
'~programs.InsertProgramFunction.P8.0'(A, B, C, D, E, F, G, H) :-
        '~programs.InsDeclaration.P6'(A, B, C, D, 'ProgDefs.FunctionDecl.F4'(_,E,F,G), H).
'programs.InsertProgramConstructor.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(ground([A,B,C,D,E]), 'Programs':'programs.InsertProgramConstructor.P6.0'(A,B,C,D,E,F)).
'~programs.InsertProgramConstructor.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(ground([A,B,C,D,E]), 'Programs':'~programs.InsertProgramConstructor.P6.0'(A,B,C,D,E,F)).
'programs.InsertProgramConstructor.P6.0'(A, B, C, D, E, F) :-
        'programs.InsTypeDeclaration.P6'(A, B, C, D, 'ProgDefs.ConstructorDecl.F1'(E), F).
'~programs.InsertProgramConstructor.P6.0'(A, B, C, D, E, F) :-
        '~programs.InsTypeDeclaration.P6'(A, B, C, D, 'ProgDefs.ConstructorDecl.F1'(E), F).
'programs.InsertProgramConstant.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(ground([A,B,C,D,E]), 'Programs':'programs.InsertProgramConstant.P6.0'(A,B,C,D,E,F)).
'~programs.InsertProgramConstant.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(ground([A,B,C,D,E]), 'Programs':'~programs.InsertProgramConstant.P6.0'(A,B,C,D,E,F)).
'programs.InsertProgramConstant.P6.0'(A, B, C, D, E, F) :-
        'programs.InsDeclaration.P6'(A, B, C, D, 'ProgDefs.ConstantDecl.F1'(E), F).
'~programs.InsertProgramConstant.P6.0'(A, B, C, D, E, F) :-
        '~programs.InsDeclaration.P6'(A, B, C, D, 'ProgDefs.ConstantDecl.F1'(E), F).
'programs.InsertProgramImport.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A,B,C,D]), 'Programs':'programs.InsertProgramImport.P5.0'(A,B,C,D,E)).
'~programs.InsertProgramImport.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A,B,C,D]), 'Programs':'~programs.InsertProgramImport.P5.0'(A,B,C,D,E)).
'programs.InsertProgramImport.P5.0'('ProgDefs.CachedProgram.F1'(A), B, C, D, E) :-
        'ProgramCache':'ProgramCache.GetCachedProgram.P2'(A, E),
        'programs.InsertProgramImport.P5'(E, B, C, D, E).
'~programs.InsertProgramImport.P5.0'('ProgDefs.CachedProgram.F1'(A), B, C, D, E) :-
        'ProgramCache':'~ProgramCache.GetCachedProgram.P2'(A, E),
        '~programs.InsertProgramImport.P5'(E, B, C, D, E).
'programs.InsertProgramImport.P5.0'('ProgDefs.Program.F4'(A,B,'ProgDefs.Language.F1'(C),D), E, F, G, 'ProgDefs.Program.F4'(A,H,'ProgDefs.Language.F1'(I),J)) :-
        'programs.CModulePart.P2'(F, K),
        'AVLTrees':'AVLTrees.AVLUpdate.P5'(B, E, 'ProgDefs.ModDef.F4'(L,M,N,O), P, 'ProgDefs.ModDef.F4'(L,Q,R,O)),
        user:goedel_freeze(ground([E]), user:goedel_not('SharedPrograms':'~Sharedprograms.SystemModule.P1'(E))),
        'SharedPrograms':'Sharedprograms.KindHasPart.P2'(L, K),
        'SharedPrograms':'Sharedprograms.AddImportToPart.P6'(K, G, Q, R, M, N),
        user:goedel_freeze(ground([G,P]), ('AVLTrees':'~AVLTrees.AVLSearch.P3'(P,G,_),true->H=P,I=C,J=D;'SharedPrograms':'Sharedprograms.AddModule.P7'(G,P,C,D,H,I,J))).
'~programs.InsertProgramImport.P5.0'('ProgDefs.Program.F4'(A,B,'ProgDefs.Language.F1'(C),D), E, F, G, 'ProgDefs.Program.F4'(A,H,'ProgDefs.Language.F1'(I),J)) :-
        '~programs.CModulePart.P2'(F, K),
        'AVLTrees':'~AVLTrees.AVLUpdate.P5'(B, E, 'ProgDefs.ModDef.F4'(L,M,N,O), P, 'ProgDefs.ModDef.F4'(L,Q,R,O)),
        user:goedel_freeze(ground([E]), user:goedel_not('SharedPrograms':'~Sharedprograms.SystemModule.P1'(E))),
        'SharedPrograms':'~Sharedprograms.KindHasPart.P2'(L, K),
        'SharedPrograms':'~Sharedprograms.AddImportToPart.P6'(K, G, Q, R, M, N),
        user:goedel_freeze(ground([G,P]), ('AVLTrees':'~AVLTrees.AVLSearch.P3'(P,G,_),true->H=P,I=C,J=D;'SharedPrograms':'~Sharedprograms.AddModule.P7'(G,P,C,D,H,I,J))).
'programs.InsertProgramPredicate.P7'(A, B, C, D, E, F, G) :-
        user:goedel_freeze(ground([A,B,C,D,E,F]), 'Programs':'programs.InsertProgramPredicate.P7.0'(A,B,C,D,E,F,G)).
'~programs.InsertProgramPredicate.P7'(A, B, C, D, E, F, G) :-
        user:goedel_freeze(ground([A,B,C,D,E,F]), 'Programs':'~programs.InsertProgramPredicate.P7.0'(A,B,C,D,E,F,G)).
'programs.InsertProgramPredicate.P7.0'(A, B, C, D, E, F, G) :-
        'programs.InsDeclaration.P6'(A, B, C, D, 'ProgDefs.PredicateDecl.F3'(_,E,F), G).
'~programs.InsertProgramPredicate.P7.0'(A, B, C, D, E, F, G) :-
        '~programs.InsDeclaration.P6'(A, B, C, D, 'ProgDefs.PredicateDecl.F3'(_,E,F), G).
'programs.IntensionalSetFree.P1'('MetaDefs.Atom.F2'(_,A)) :-
        user:goedel_freeze(ground([A]), user:goedel_not('Programs':'~programs.HasIntensionalSet1.P1'(A))).
'~programs.IntensionalSetFree.P1'('MetaDefs.Atom.F2'(_,A)) :-
        user:goedel_freeze(ground([A]), user:goedel_not('Programs':'~programs.HasIntensionalSet1.P1'(A))).
'programs.InstanceOfHead.P3'('MetaDefs.Atom.F2'(A,B), 'MetaDefs.Atom.F2'(A,C), D) :-
        'Syntax':'Syntax.EmptyTermSubst.P1'(E),
        'programs.InstanceOfHead2.P4'(B, C, E, D).
'~programs.InstanceOfHead.P3'('MetaDefs.Atom.F2'(A,B), 'MetaDefs.Atom.F2'(A,C), D) :-
        'Syntax':'~Syntax.EmptyTermSubst.P1'(E),
        '~programs.InstanceOfHead2.P4'(B, C, E, D).
'programs.InsertStatement.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'programs.InsertStatement.P4.0'(A,B,C,D)).
'~programs.InsertStatement.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'~programs.InsertStatement.P4.0'(A,B,C,D)).
'programs.InsertStatement.P4.0'(A, B, C, 'ProgDefs.Program.F4'(D,E,F,G)) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, H),
        user:goedel_freeze(ground([B]), user:goedel_not('SharedPrograms':'~Sharedprograms.SystemModule.P1'(B))),
        'programs.StatementInModuleLanguage.P3'(H, B, C),
        'programs.OpenStatementPredicate.P2'(C, 'MetaDefs.Name.F4'(B,I,_,J)),
        'SharedPrograms':'Sharedprograms.NextModuleVersion.P2'(B, K),
        H='ProgDefs.Program.F4'(D,E,F,L),
        'AVLTrees':'AVLTrees.AVLUpdate.P5'(L, B, 'ProgDefs.Code.F2'(K,M), G, 'ProgDefs.Code.F2'(_,N)),
        'AVLTrees':'AVLTrees.AVLAmend.P6'(N, I, O, [], M, P),
        user:goedel_freeze(ground([J,P]), if(('Lists':'~Lists.DeleteFirst.P3'('ProgDefs.PredDef.F4'(J,Q,R,S),P,T),true),O=['ProgDefs.PredDef.F4'(J,[C|Q],R,S)|T],O=['ProgDefs.PredDef.F4'(J,[C],[],[])|P])).
'~programs.InsertStatement.P4.0'(A, B, C, 'ProgDefs.Program.F4'(D,E,F,G)) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, H),
        user:goedel_freeze(ground([B]), user:goedel_not('SharedPrograms':'~Sharedprograms.SystemModule.P1'(B))),
        '~programs.StatementInModuleLanguage.P3'(H, B, C),
        '~programs.OpenStatementPredicate.P2'(C, 'MetaDefs.Name.F4'(B,I,_,J)),
        'SharedPrograms':'~Sharedprograms.NextModuleVersion.P2'(B, K),
        H='ProgDefs.Program.F4'(D,E,F,L),
        'AVLTrees':'~AVLTrees.AVLUpdate.P5'(L, B, 'ProgDefs.Code.F2'(K,M), G, 'ProgDefs.Code.F2'(_,N)),
        'AVLTrees':'~AVLTrees.AVLAmend.P6'(N, I, O, [], M, P),
        user:goedel_freeze(ground([J,P]), if(('Lists':'~Lists.DeleteFirst.P3'('ProgDefs.PredDef.F4'(J,Q,R,S),P,T),true),O=['ProgDefs.PredDef.F4'(J,[C|Q],R,S)|T],O=['ProgDefs.PredDef.F4'(J,[C],[],[])|P])).
'programs.InstanceOfHead1.P4'('MetaDefs.Var.F2'(A,B), C, D, E) :-
        'Syntax':'Syntax.BindingToTermSubst.P3'('MetaDefs.Var.F2'(A,B), C, F),
        'Syntax':'Syntax.ComposeTermSubsts.P3'(D, F, E).
'~programs.InstanceOfHead1.P4'('MetaDefs.Var.F2'(A,B), C, D, E) :-
        'Syntax':'~Syntax.BindingToTermSubst.P3'('MetaDefs.Var.F2'(A,B), C, F),
        'Syntax':'~Syntax.ComposeTermSubsts.P3'(D, F, E).
'programs.InstanceOfHead1.P4'('MetaDefs.Var.F1'(A), B, C, D) :-
        'Syntax':'Syntax.BindingToTermSubst.P3'('MetaDefs.Var.F1'(A), B, E),
        'Syntax':'Syntax.ComposeTermSubsts.P3'(C, E, D).
'~programs.InstanceOfHead1.P4'('MetaDefs.Var.F1'(A), B, C, D) :-
        'Syntax':'~Syntax.BindingToTermSubst.P3'('MetaDefs.Var.F1'(A), B, E),
        'Syntax':'~Syntax.ComposeTermSubsts.P3'(C, E, D).
'programs.InstanceOfHead1.P4'('MetaDefs.Term.F2'(A,B), 'MetaDefs.Term.F2'(A,C), D, E) :-
        'programs.InstanceOfHead2.P4'(B, C, D, E).
'~programs.InstanceOfHead1.P4'('MetaDefs.Term.F2'(A,B), 'MetaDefs.Term.F2'(A,C), D, E) :-
        '~programs.InstanceOfHead2.P4'(B, C, D, E).
'programs.InstanceOfHead1.P4'('MetaDefs.CTerm.F1'(A), 'MetaDefs.CTerm.F1'(A), B, B).
'~programs.InstanceOfHead1.P4'('MetaDefs.CTerm.F1'(A), 'MetaDefs.CTerm.F1'(A), B, B).
'programs.InstanceOfHead1.P4'('MetaDefs.Int.F1'(A), 'MetaDefs.Int.F1'(A), B, B).
'~programs.InstanceOfHead1.P4'('MetaDefs.Int.F1'(A), 'MetaDefs.Int.F1'(A), B, B).
'programs.InstanceOfHead1.P4'('MetaDefs.Str.F1'(A), 'MetaDefs.Str.F1'(A), B, B).
'~programs.InstanceOfHead1.P4'('MetaDefs.Str.F1'(A), 'MetaDefs.Str.F1'(A), B, B).
'programs.InstanceOfHead1.P4'('MetaDefs.Prm.F1'(A), 'MetaDefs.Prm.F1'(A), B, B).
'~programs.InstanceOfHead1.P4'('MetaDefs.Prm.F1'(A), 'MetaDefs.Prm.F1'(A), B, B).
'programs.InstanceOfHead2.P4'([], [], A, A).
'~programs.InstanceOfHead2.P4'([], [], A, A).
'programs.InstanceOfHead2.P4'([A|B], [C|D], E, F) :-
        'programs.InstanceOfHead1.P4'(A, C, E, G),
        'programs.InstanceOfHead2.P4'(B, D, G, F).
'~programs.InstanceOfHead2.P4'([A|B], [C|D], E, F) :-
        '~programs.InstanceOfHead1.P4'(A, C, E, G),
        '~programs.InstanceOfHead2.P4'(B, D, G, F).
'programs.ListTypesInModule.P4'(A, B, C, D) :-
        'programs.CModulePart.P2'(C, E),
        'programs.ModulePartLanguage.P4'(E, B, A, F),
        'SharedPrograms':'Sharedprograms.ListTypesInLanguage.P2'(D, F).
'~programs.ListTypesInModule.P4'(A, B, C, D) :-
        '~programs.CModulePart.P2'(C, E),
        '~programs.ModulePartLanguage.P4'(E, B, A, F),
        'SharedPrograms':'~Sharedprograms.ListTypesInLanguage.P2'(D, F).
'programs.ProgramTermToString.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'programs.ProgramTermToString.P4.0'(A,B,C,D)).
'~programs.ProgramTermToString.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'~programs.ProgramTermToString.P4.0'(A,B,C,D)).
'programs.ProgramTermToString.P4.0'(A, B, C, D) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, E),
        'SharedPrograms':'Sharedprograms.SProgramTermToString.P4'(E, B, C, D).
'~programs.ProgramTermToString.P4.0'(A, B, C, D) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, E),
        'SharedPrograms':'~Sharedprograms.SProgramTermToString.P4'(E, B, C, D).
'programs.ProgramConstructorName.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A])and(ground([B])and(ground([C])and ground([D])))or ground([E]), 'Programs':'programs.ProgramConstructorName.P5.0'(A,B,C,D,E)).
'~programs.ProgramConstructorName.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A])and(ground([B])and(ground([C])and ground([D])))or ground([E]), 'Programs':'~programs.ProgramConstructorName.P5.0'(A,B,C,D,E)).
'programs.ProgramConstructorName.P5.0'(A, B, C, D, 'MetaDefs.Name.F4'(B,C,'MetaDefs.Constructor.C0',D)) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, E),
        'programs.ModuleInProgram.P2'(E, B).
'~programs.ProgramConstructorName.P5.0'(A, B, C, D, 'MetaDefs.Name.F4'(B,C,'MetaDefs.Constructor.C0',D)) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, E),
        '~programs.ModuleInProgram.P2'(E, B).
'programs.OpenModule.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Programs':'programs.OpenModule.P2.0'(A,B)).
'~programs.OpenModule.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Programs':'~programs.OpenModule.P2.0'(A,B)).
'programs.OpenModule.P2.0'(A, B) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, C),
        'SharedPrograms':'Sharedprograms.SOpenModule.P2'(C, B).
'~programs.OpenModule.P2.0'(A, B) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, C),
        'SharedPrograms':'~Sharedprograms.SOpenModule.P2'(C, B).
'programs.ModulePartLanguage.P4'('ProgDefs.Export.C0', A, B, C) :-
        'SharedPrograms':'Sharedprograms.ExportLanguage.P3'(B, A, C).
'~programs.ModulePartLanguage.P4'('ProgDefs.Export.C0', A, B, C) :-
        'SharedPrograms':'~Sharedprograms.ExportLanguage.P3'(B, A, C).
'programs.ModulePartLanguage.P4'('ProgDefs.Closed.C0', A, B, C) :-
        'SharedPrograms':'Sharedprograms.ExportLanguage.P3'(B, A, C).
'~programs.ModulePartLanguage.P4'('ProgDefs.Closed.C0', A, B, C) :-
        'SharedPrograms':'~Sharedprograms.ExportLanguage.P3'(B, A, C).
'programs.ModulePartLanguage.P4'('ProgDefs.Local.C0', A, B, C) :-
        'SharedPrograms':'Sharedprograms.ModuleLanguage.P3'(B, A, C).
'~programs.ModulePartLanguage.P4'('ProgDefs.Local.C0', A, B, C) :-
        'SharedPrograms':'~Sharedprograms.ModuleLanguage.P3'(B, A, C).
'programs.ModulePartLanguage.P4'('ProgDefs.Module.C0', A, B, C) :-
        'SharedPrograms':'Sharedprograms.ModuleLanguage.P3'(B, A, C).
'~programs.ModulePartLanguage.P4'('ProgDefs.Module.C0', A, B, C) :-
        'SharedPrograms':'~Sharedprograms.ModuleLanguage.P3'(B, A, C).
'programs.ModuleInProgram.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Programs':'programs.ModuleInProgram.P2.0'(A,B)).
'~programs.ModuleInProgram.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Programs':'~programs.ModuleInProgram.P2.0'(A,B)).
'programs.ModuleInProgram.P2.0'('ProgDefs.CachedProgram.F1'(A), B) :-
        'ProgramCache':'ProgramCache.GetCachedProgram.P2'(A, C),
        'programs.ModuleInProgram.P2'(C, B).
'~programs.ModuleInProgram.P2.0'('ProgDefs.CachedProgram.F1'(A), B) :-
        'ProgramCache':'~ProgramCache.GetCachedProgram.P2'(A, C),
        '~programs.ModuleInProgram.P2'(C, B).
'programs.ModuleInProgram.P2.0'('ProgDefs.Program.F4'(_,A,_,_), B) :-
        'programs.ModuleInProgramAux.P2'(A, B).
'~programs.ModuleInProgram.P2.0'('ProgDefs.Program.F4'(_,A,_,_), B) :-
        '~programs.ModuleInProgramAux.P2'(A, B).
'programs.ModuleImported.P3'(A, 'ProgDefs.ModDef.F4'(_,B,C,D), E) :-
        'Lists':'Lists.Append.P3'(B, C, F),
        'Lists':'Lists.Append.P3'(D, F, G),
        'programs.ReachableModules.P4'(G, E, [], H),
        'Lists':'Lists.MemberCheck.P2'(A, H).
'~programs.ModuleImported.P3'(A, 'ProgDefs.ModDef.F4'(_,B,C,D), E) :-
        'Lists':'~Lists.Append.P3'(B, C, F),
        'Lists':'~Lists.Append.P3'(D, F, G),
        '~programs.ReachableModules.P4'(G, E, [], H),
        'Lists':'~Lists.MemberCheck.P2'(A, H).
'programs.NewProgram.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Programs':'programs.NewProgram.P2.0'(A,B)).
'~programs.NewProgram.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Programs':'~programs.NewProgram.P2.0'(A,B)).
'programs.NewProgram.P2.0'(A, B) :-
        'programs.NewProgramAux.P2'(B, A).
'~programs.NewProgram.P2.0'(A, B) :-
        '~programs.NewProgramAux.P2'(B, A).
'programs.NonVarCondition.P2'('MetaDefs.Var.F2'(A,B), 'ProgDefs.Nonvar.F1'('MetaDefs.Var.F2'(A,B))).
'~programs.NonVarCondition.P2'('MetaDefs.Var.F2'(A,B), 'ProgDefs.Nonvar.F1'('MetaDefs.Var.F2'(A,B))).
'programs.NonVarCondition.P2'('MetaDefs.Var.F1'(A), 'ProgDefs.Nonvar.F1'('MetaDefs.Var.F1'(A))).
'~programs.NonVarCondition.P2'('MetaDefs.Var.F1'(A), 'ProgDefs.Nonvar.F1'('MetaDefs.Var.F1'(A))).
'programs.PredOrPropInLanguage.P3'('MetaDefs.Predicate.C0', A, B) :-
        'SharedPrograms':'Sharedprograms.PredicateInLanguage.P4'(A, B, _, _).
'~programs.PredOrPropInLanguage.P3'('MetaDefs.Predicate.C0', A, B) :-
        'SharedPrograms':'~Sharedprograms.PredicateInLanguage.P4'(A, B, _, _).
'programs.PredOrPropInLanguage.P3'('MetaDefs.Proposition.C0', A, B) :-
        'SharedPrograms':'Sharedprograms.PropositionInLanguage.P2'(A, B).
'~programs.PredOrPropInLanguage.P3'('MetaDefs.Proposition.C0', A, B) :-
        'SharedPrograms':'~Sharedprograms.PropositionInLanguage.P2'(A, B).
'programs.OrCondition.P3'(A, B, 'ProgDefs.Or.F2'(A,B)).
'~programs.OrCondition.P3'(A, B, 'ProgDefs.Or.F2'(A,B)).
'programs.OpenStatementPredicate.P2'(B, A) :-
        user:goedel_freeze(nonvar(B), 'Programs':'programs.OpenStatementPredicate.P2.1'(B,A)).
'~programs.OpenStatementPredicate.P2'(B, A) :-
        user:goedel_freeze(nonvar(B), 'Programs':'~programs.OpenStatementPredicate.P2.1'(B,A)).
'programs.OpenStatementPredicate.P2.1'('MetaDefs.<-''.F2'(A,B), C) :- !,
        user:goedel_freeze(nonvar(A), 'Programs':'programs.OpenStatementPredicate.P2.0'('MetaDefs.<-''.F2'(A,B),C)).
'~programs.OpenStatementPredicate.P2.1'('MetaDefs.<-''.F2'(A,B), C) :- !,
        user:goedel_freeze(nonvar(A), 'Programs':'~programs.OpenStatementPredicate.P2.0'('MetaDefs.<-''.F2'(A,B),C)).
'programs.OpenStatementPredicate.P2.1'(A, B) :-
        'programs.OpenStatementPredicate.P2.0'(A, B).
'~programs.OpenStatementPredicate.P2.1'(A, B) :-
        '~programs.OpenStatementPredicate.P2.0'(A, B).
'programs.OpenStatementPredicate.P2.0'('MetaDefs.<-''.F2'('MetaDefs.PAtom.F1'(A),_), A).
'~programs.OpenStatementPredicate.P2.0'('MetaDefs.<-''.F2'('MetaDefs.PAtom.F1'(A),_), A).
'programs.OpenStatementPredicate.P2.0'('MetaDefs.<-''.F2'('MetaDefs.Atom.F2'(A,_),_), A).
'~programs.OpenStatementPredicate.P2.0'('MetaDefs.<-''.F2'('MetaDefs.Atom.F2'(A,_),_), A).
'programs.PartAccessibility.P2'('programs.Export.C0', 'ProgDefs.Exported.C0').
'~programs.PartAccessibility.P2'('programs.Export.C0', 'ProgDefs.Exported.C0').
'programs.PartAccessibility.P2'('programs.Closed.C0', 'ProgDefs.Exported.C0').
'~programs.PartAccessibility.P2'('programs.Closed.C0', 'ProgDefs.Exported.C0').
'programs.PartAccessibility.P2'('programs.Local.C0', 'ProgDefs.Hidden.C0').
'~programs.PartAccessibility.P2'('programs.Local.C0', 'ProgDefs.Hidden.C0').
'programs.PartAccessibility.P2'('programs.Module.C0', 'ProgDefs.Hidden.C0').
'~programs.PartAccessibility.P2'('programs.Module.C0', 'ProgDefs.Hidden.C0').
'programs.ProgramBaseName.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A])and(ground([B])and ground([C]))or ground([D]), 'Programs':'programs.ProgramBaseName.P4.0'(A,B,C,D)).
'~programs.ProgramBaseName.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A])and(ground([B])and ground([C]))or ground([D]), 'Programs':'~programs.ProgramBaseName.P4.0'(A,B,C,D)).
'programs.ProgramBaseName.P4.0'(A, B, C, 'MetaDefs.Name.F4'(B,C,'MetaDefs.Base.C0',0)) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, D),
        'programs.ModuleInProgram.P2'(D, B).
'~programs.ProgramBaseName.P4.0'(A, B, C, 'MetaDefs.Name.F4'(B,C,'MetaDefs.Base.C0',0)) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, D),
        '~programs.ModuleInProgram.P2'(D, B).
'programs.PredicateInModule.P7'(A, B, C, D, E, F, G) :-
        user:goedel_freeze(ground([A]), 'Programs':'programs.PredicateInModule.P7.0'(A,B,C,D,E,F,G)).
'~programs.PredicateInModule.P7'(A, B, C, D, E, F, G) :-
        user:goedel_freeze(ground([A]), 'Programs':'~programs.PredicateInModule.P7.0'(A,B,C,D,E,F,G)).
'programs.PredicateInModule.P7.0'(A, B, C, D, E, F, G) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, H),
        'programs.CModulePart.P2'(C, I),
        'SharedPrograms':'Sharedprograms.ModulePartInProgram.P3'(H, B, I),
        'programs.ModulePartLanguage.P4'(I, B, H, J),
        'SharedPrograms':'Sharedprograms.PredicateInLanguage.P4'(D, J, E, F),
        D='MetaDefs.Name.F4'(G,_,_,_).
'~programs.PredicateInModule.P7.0'(A, B, C, D, E, F, G) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, H),
        '~programs.CModulePart.P2'(C, I),
        'SharedPrograms':'~Sharedprograms.ModulePartInProgram.P3'(H, B, I),
        '~programs.ModulePartLanguage.P4'(I, B, H, J),
        'SharedPrograms':'~Sharedprograms.PredicateInLanguage.P4'(D, J, E, F),
        D='MetaDefs.Name.F4'(G,_,_,_).
'programs.ProgramConstantName.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A])and(ground([B])and ground([C]))or ground([D]), 'Programs':'programs.ProgramConstantName.P4.0'(A,B,C,D)).
'~programs.ProgramConstantName.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A])and(ground([B])and ground([C]))or ground([D]), 'Programs':'~programs.ProgramConstantName.P4.0'(A,B,C,D)).
'programs.ProgramConstantName.P4.0'(A, B, C, 'MetaDefs.Name.F4'(B,C,'MetaDefs.Constant.C0',0)) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, D),
        'programs.ModuleInProgram.P2'(D, B).
'~programs.ProgramConstantName.P4.0'(A, B, C, 'MetaDefs.Name.F4'(B,C,'MetaDefs.Constant.C0',0)) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, D),
        '~programs.ModuleInProgram.P2'(D, B).
'programs.ProgramFunctionName.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A])and(ground([B])and(ground([C])and ground([D])))or ground([E]), 'Programs':'programs.ProgramFunctionName.P5.0'(A,B,C,D,E)).
'~programs.ProgramFunctionName.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A])and(ground([B])and(ground([C])and ground([D])))or ground([E]), 'Programs':'~programs.ProgramFunctionName.P5.0'(A,B,C,D,E)).
'programs.ProgramFunctionName.P5.0'(A, B, C, D, 'MetaDefs.Name.F4'(B,C,'MetaDefs.Function.C0',D)) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, E),
        'programs.ModuleInProgram.P2'(E, B).
'~programs.ProgramFunctionName.P5.0'(A, B, C, D, 'MetaDefs.Name.F4'(B,C,'MetaDefs.Function.C0',D)) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, E),
        '~programs.ModuleInProgram.P2'(E, B).
'programs.ProgramFormulaToString.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'programs.ProgramFormulaToString.P4.0'(A,B,C,D)).
'~programs.ProgramFormulaToString.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'~programs.ProgramFormulaToString.P4.0'(A,B,C,D)).
'programs.ProgramFormulaToString.P4.0'(A, B, C, D) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, E),
        'SharedPrograms':'Sharedprograms.SProgramFormulaToString.P4'(E, B, C, D).
'~programs.ProgramFormulaToString.P4.0'(A, B, C, D) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, E),
        'SharedPrograms':'~Sharedprograms.SProgramFormulaToString.P4'(E, B, C, D).
'programs.ProgramPropositionName.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A])and(ground([B])and ground([C]))or ground([D]), 'Programs':'programs.ProgramPropositionName.P4.0'(A,B,C,D)).
'~programs.ProgramPropositionName.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A])and(ground([B])and ground([C]))or ground([D]), 'Programs':'~programs.ProgramPropositionName.P4.0'(A,B,C,D)).
'programs.ProgramPropositionName.P4.0'(A, B, C, 'MetaDefs.Name.F4'(B,C,'MetaDefs.Proposition.C0',0)) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, D),
        'programs.ModuleInProgram.P2'(D, B).
'~programs.ProgramPropositionName.P4.0'(A, B, C, 'MetaDefs.Name.F4'(B,C,'MetaDefs.Proposition.C0',0)) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, D),
        '~programs.ModuleInProgram.P2'(D, B).
'programs.ProgramPredicateName.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A])and(ground([B])and(ground([C])and ground([D])))or ground([E]), 'Programs':'programs.ProgramPredicateName.P5.0'(A,B,C,D,E)).
'~programs.ProgramPredicateName.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A])and(ground([B])and(ground([C])and ground([D])))or ground([E]), 'Programs':'~programs.ProgramPredicateName.P5.0'(A,B,C,D,E)).
'programs.ProgramPredicateName.P5.0'(A, B, C, D, 'MetaDefs.Name.F4'(B,C,'MetaDefs.Predicate.C0',D)) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, E),
        'programs.ModuleInProgram.P2'(E, B).
'~programs.ProgramPredicateName.P5.0'(A, B, C, D, 'MetaDefs.Name.F4'(B,C,'MetaDefs.Predicate.C0',D)) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, E),
        '~programs.ModuleInProgram.P2'(E, B).
'programs.StringToProgramTerm.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'programs.StringToProgramTerm.P4.0'(A,B,C,D)).
'~programs.StringToProgramTerm.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'~programs.StringToProgramTerm.P4.0'(A,B,C,D)).
'programs.StringToProgramTerm.P4.0'(A, B, C, D) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, E),
        'programs.StringToProgramTermAux.P4'(E, B, C, D).
'~programs.StringToProgramTerm.P4.0'(A, B, C, D) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, E),
        '~programs.StringToProgramTermAux.P4'(E, B, C, D).
'programs.StatementInModule.P3'(A, B, C) :-
        user:goedel_freeze(ground([A]), 'Programs':'programs.StatementInModule.P3.0'(A,B,C)).
'~programs.StatementInModule.P3'(A, B, C) :-
        user:goedel_freeze(ground([A]), 'Programs':'~programs.StatementInModule.P3.0'(A,B,C)).
'programs.StatementInModule.P3.0'(A, B, C) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, D),
        'programs.OpenStatementPredicate.P2'(C, E),
        'programs.DefinitionInProgram.P4'(D, B, E, F),
        'Lists':'Lists.Member.P2'(C, F).
'~programs.StatementInModule.P3.0'(A, B, C) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, D),
        '~programs.OpenStatementPredicate.P2'(C, E),
        '~programs.DefinitionInProgram.P4'(D, B, E, F),
        'Lists':'~Lists.Member.P2'(C, F).
'programs.PropositionInModule.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A]), 'Programs':'programs.PropositionInModule.P5.0'(A,B,C,D,E)).
'~programs.PropositionInModule.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A]), 'Programs':'~programs.PropositionInModule.P5.0'(A,B,C,D,E)).
'programs.PropositionInModule.P5.0'(A, B, C, D, E) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, F),
        'programs.CModulePart.P2'(C, G),
        'SharedPrograms':'Sharedprograms.ModulePartInProgram.P3'(F, B, G),
        'programs.ModulePartLanguage.P4'(G, B, F, H),
        'SharedPrograms':'Sharedprograms.PropositionInLanguage.P2'(D, H),
        D='MetaDefs.Name.F4'(E,_,_,_).
'~programs.PropositionInModule.P5.0'(A, B, C, D, E) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, F),
        '~programs.CModulePart.P2'(C, G),
        'SharedPrograms':'~Sharedprograms.ModulePartInProgram.P3'(F, B, G),
        '~programs.ModulePartLanguage.P4'(G, B, F, H),
        'SharedPrograms':'~Sharedprograms.PropositionInLanguage.P2'(D, H),
        D='MetaDefs.Name.F4'(E,_,_,_).
'programs.ProgramTypeToString.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'programs.ProgramTypeToString.P4.0'(A,B,C,D)).
'~programs.ProgramTypeToString.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'~programs.ProgramTypeToString.P4.0'(A,B,C,D)).
'programs.ProgramTypeToString.P4.0'(A, B, C, D) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, E),
        'SharedPrograms':'Sharedprograms.SProgramTypeToString.P4'(E, B, C, D).
'~programs.ProgramTypeToString.P4.0'(A, B, C, D) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, E),
        'SharedPrograms':'~Sharedprograms.SProgramTypeToString.P4'(E, B, C, D).
'programs.RunnableAtom.P2'(A, B) :-
        user:goedel_freeze(ground([A,B]), 'Programs':'programs.RunnableAtom.P2.0'(A,B)).
'~programs.RunnableAtom.P2'(A, B) :-
        user:goedel_freeze(ground([A,B]), 'Programs':'~programs.RunnableAtom.P2.0'(A,B)).
'programs.RunnableAtom.P2.0'(A, B) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, C),
        'programs.DeclaredInOpenModule.P3'(C, D, B),
        'Syntax':'Syntax.PredicateAtom.P3'(B, E, _),
        'programs.ControlInProgram.P5'(C, D, E, F, G),
        user:goedel_freeze(ground([B,G,F]), if(('Programs':'~programs.ApplicableDelay.P5'(F,G,B,H,I),true),('Syntax':'Syntax.RenameFormulas.P3'([H],[B],[J]),'Programs':'programs.InstanceOfHead.P3'(H,J,K),'Programs':'programs.ConditionSatisfied.P2'(I,K)),true)).
'~programs.RunnableAtom.P2.0'(A, B) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, C),
        '~programs.DeclaredInOpenModule.P3'(C, D, B),
        'Syntax':'~Syntax.PredicateAtom.P3'(B, E, _),
        '~programs.ControlInProgram.P5'(C, D, E, F, G),
        user:goedel_freeze(ground([B,G,F]), if(('Programs':'~programs.ApplicableDelay.P5'(F,G,B,H,I),true),('Syntax':'~Syntax.RenameFormulas.P3'([H],[B],[J]),'Programs':'~programs.InstanceOfHead.P3'(H,J,K),'Programs':'~programs.ConditionSatisfied.P2'(I,K)),true)).
'programs.RightHandType.P4'('MetaDefs.BType.F1'(A), B, C, D) :-
        'programs.BaseInModule.P5'(B, C, D, A, C).
'~programs.RightHandType.P4'('MetaDefs.BType.F1'(A), B, C, D) :-
        '~programs.BaseInModule.P5'(B, C, D, A, C).
'programs.RightHandType.P4'('MetaDefs.Type.F2'(A,_), B, C, D) :-
        'programs.ConstructorInModule.P6'(B, C, D, A, _, C).
'~programs.RightHandType.P4'('MetaDefs.Type.F2'(A,_), B, C, D) :-
        '~programs.ConstructorInModule.P6'(B, C, D, A, _, C).
'programs.StringToCondition.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Programs':'programs.StringToCondition.P2.0'(A,B)).
'~programs.StringToCondition.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Programs':'~programs.StringToCondition.P2.0'(A,B)).
'programs.StringToCondition.P2.0'(A, B) :-
        'SharedPrograms':'Sharedprograms.SStringToCondition.P2'(A, B).
'~programs.StringToCondition.P2.0'(A, B) :-
        'SharedPrograms':'~Sharedprograms.SStringToCondition.P2'(A, B).
'programs.StatementMatchAtom.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,C]), 'Programs':'programs.StatementMatchAtom.P4.0'(A,B,C,D)).
'~programs.StatementMatchAtom.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,C]), 'Programs':'~programs.StatementMatchAtom.P4.0'(A,B,C,D)).
'programs.StatementMatchAtom.P4.0'('ProgDefs.CachedProgram.F1'(A), B, C, D) :-
        'ProgramCache':'ProgramCache.GetCachedProgram.P2'(A, E),
        'programs.StatementMatchAtom.P4'(E, B, C, D).
'~programs.StatementMatchAtom.P4.0'('ProgDefs.CachedProgram.F1'(A), B, C, D) :-
        'ProgramCache':'~ProgramCache.GetCachedProgram.P2'(A, E),
        '~programs.StatementMatchAtom.P4'(E, B, C, D).
'programs.StatementMatchAtom.P4.0'('ProgDefs.Program.F4'(_,A,B,C), D, E, F) :-
        'Syntax':'Syntax.Atom.P1'(E),
        'Syntax':'Syntax.EmptyVarTyping.P1'(G),
        'SharedPrograms':'Sharedprograms.FormulaInLanguage.P4'(E, B, G, _),
        'programs.TopLevelName.P2'(E, 'MetaDefs.Name.F4'(D,H,_,I)),
        'SharedPrograms':'Sharedprograms.OpenModuleAux.P2'(A, D),
        'AVLTrees':'AVLTrees.AVLSearch.P3'(C, D, 'ProgDefs.Code.F2'(_,J)),
        'AVLTrees':'AVLTrees.AVLSearch.P3'(J, H, K),
        'Lists':'Lists.MemberCheck.P2'('ProgDefs.PredDef.F4'(I,L,_,_), K),
        'Lists':'Lists.Member.P2'(F, L).
'~programs.StatementMatchAtom.P4.0'('ProgDefs.Program.F4'(_,A,B,C), D, E, F) :-
        'Syntax':'~Syntax.Atom.P1'(E),
        'Syntax':'~Syntax.EmptyVarTyping.P1'(G),
        'SharedPrograms':'~Sharedprograms.FormulaInLanguage.P4'(E, B, G, _),
        '~programs.TopLevelName.P2'(E, 'MetaDefs.Name.F4'(D,H,_,I)),
        'SharedPrograms':'~Sharedprograms.OpenModuleAux.P2'(A, D),
        'AVLTrees':'~AVLTrees.AVLSearch.P3'(C, D, 'ProgDefs.Code.F2'(_,J)),
        'AVLTrees':'~AVLTrees.AVLSearch.P3'(J, H, K),
        'Lists':'~Lists.MemberCheck.P2'('ProgDefs.PredDef.F4'(I,L,_,_), K),
        'Lists':'~Lists.Member.P2'(F, L).
'programs.StatementInModuleLanguage.P3'(A, B, C) :-
        'SharedPrograms':'Sharedprograms.ModuleLanguage.P3'(A, B, D),
        'SharedPrograms':'Sharedprograms.StatementInLanguage.P5'(C, D, _, _, []).
'~programs.StatementInModuleLanguage.P3'(A, B, C) :-
        'SharedPrograms':'~Sharedprograms.ModuleLanguage.P3'(A, B, D),
        'SharedPrograms':'~Sharedprograms.StatementInLanguage.P5'(C, D, _, _, []).
'programs.StringToProgramFormula.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'programs.StringToProgramFormula.P4.0'(A,B,C,D)).
'~programs.StringToProgramFormula.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'~programs.StringToProgramFormula.P4.0'(A,B,C,D)).
'programs.StringToProgramFormula.P4.0'(A, B, C, D) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, E),
        'programs.StringToProgramFormulaAux.P4'(E, B, C, D).
'~programs.StringToProgramFormula.P4.0'(A, B, C, D) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, E),
        '~programs.StringToProgramFormulaAux.P4'(E, B, C, D).
'programs.TermInProgram.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'programs.TermInProgram.P5.0'(A,B,C,D,E)).
'~programs.TermInProgram.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'~programs.TermInProgram.P5.0'(A,B,C,D,E)).
'programs.TermInProgram.P5.0'('ProgDefs.CachedProgram.F1'(A), B, C, D, E) :-
        'ProgramCache':'ProgramCache.GetCachedProgram.P2'(A, F),
        'programs.TermInProgram.P5'(F, B, C, D, E).
'~programs.TermInProgram.P5.0'('ProgDefs.CachedProgram.F1'(A), B, C, D, E) :-
        'ProgramCache':'~ProgramCache.GetCachedProgram.P2'(A, F),
        '~programs.TermInProgram.P5'(F, B, C, D, E).
'programs.TermInProgram.P5.0'('ProgDefs.Program.F4'(_,_,A,_), B, C, D, E) :-
        'SharedPrograms':'Sharedprograms.TermInLanguage.P5'(C, A, B, E, D).
'~programs.TermInProgram.P5.0'('ProgDefs.Program.F4'(_,_,A,_), B, C, D, E) :-
        'SharedPrograms':'~Sharedprograms.TermInLanguage.P5'(C, A, B, E, D).
'programs.SymbolFreeInModule.P3'(A, B, 'ProgDefs.Program.F4'(_,_,_,C)) :-
        'AVLTrees':'AVLTrees.AVLSearch.P3'(C, A, 'ProgDefs.Code.F2'(_,D)),
        user:goedel_freeze(ground([B,D]), user:goedel_not((('AVLTrees':'~AVLTrees.AVLMember.P3'(D,_,E),'Lists':'~Lists.Member.P2'('ProgDefs.PredDef.F4'(_,F,G,H),E)),('Lists':'~Lists.Member.P2'(I,F),'Programs':'~programs.SymbolInFormula.P2'(I,B);'Lists':'~Lists.Member.P2'(J,G),'Programs':'~programs.SymbolInDelay.P2'(J,B);'Lists':'~Lists.Member.P2'(K,H),'Programs':'~programs.SymbolInDelay.P2'(K,B))))).
'~programs.SymbolFreeInModule.P3'(A, B, 'ProgDefs.Program.F4'(_,_,_,C)) :-
        'AVLTrees':'~AVLTrees.AVLSearch.P3'(C, A, 'ProgDefs.Code.F2'(_,D)),
        user:goedel_freeze(ground([B,D]), user:goedel_not((('AVLTrees':'~AVLTrees.AVLMember.P3'(D,_,E),'Lists':'~Lists.Member.P2'('ProgDefs.PredDef.F4'(_,F,G,H),E)),('Lists':'~Lists.Member.P2'(I,F),'Programs':'~programs.SymbolInFormula.P2'(I,B);'Lists':'~Lists.Member.P2'(J,G),'Programs':'~programs.SymbolInDelay.P2'(J,B);'Lists':'~Lists.Member.P2'(K,H),'Programs':'~programs.SymbolInDelay.P2'(K,B))))).
'programs.Succeed.P3'(A, B, C) :-
        user:goedel_freeze(ground([A,B]), 'Programs':'programs.Succeed.P3.0'(A,B,C)).
'~programs.Succeed.P3'(A, B, C) :-
        user:goedel_freeze(ground([A,B]), 'Programs':'~programs.Succeed.P3.0'(A,B,C)).
'programs.Succeed.P3.0'(A, B, C) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, D),
        'SharedPrograms':'Sharedprograms.ProgramLanguage.P2'(D, E),
        'SharedPrograms':'Sharedprograms.MeltedBodyTyping.P8'(B, E, [], _, _, [], [], []),
        'programs.CompileObjectProgram.P1'(D),
        'Syntax':'Syntax.FormulaMaxVarIndex.P2'([B], F),
        'Syntax':'Syntax.EmptyTermSubst.P1'(G),
        'programs.RunGoal.P6'(B, F, G, C, _, _).
'~programs.Succeed.P3.0'(A, B, C) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, D),
        'SharedPrograms':'~Sharedprograms.ProgramLanguage.P2'(D, E),
        'SharedPrograms':'~Sharedprograms.MeltedBodyTyping.P8'(B, E, [], _, _, [], [], []),
        '~programs.CompileObjectProgram.P1'(D),
        'Syntax':'~Syntax.FormulaMaxVarIndex.P2'([B], F),
        'Syntax':'~Syntax.EmptyTermSubst.P1'(G),
        '~programs.RunGoal.P6'(B, F, G, C, _, _).
'programs.StringToProgramType.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'programs.StringToProgramType.P4.0'(A,B,C,D)).
'~programs.StringToProgramType.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Programs':'~programs.StringToProgramType.P4.0'(A,B,C,D)).
'programs.StringToProgramType.P4.0'(A, B, C, D) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, E),
        'programs.StringToProgramTypeAux.P4'(E, B, C, D).
'~programs.StringToProgramType.P4.0'(A, B, C, D) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, E),
        '~programs.StringToProgramTypeAux.P4'(E, B, C, D).
'programs.SucceedAll.P3'(A, B, C) :-
        user:goedel_freeze(ground([A,B]), 'Programs':'programs.SucceedAll.P3.0'(A,B,C)).
'~programs.SucceedAll.P3'(A, B, C) :-
        user:goedel_freeze(ground([A,B]), 'Programs':'~programs.SucceedAll.P3.0'(A,B,C)).
'programs.SucceedAll.P3.0'(A, B, C) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, D),
        'SharedPrograms':'Sharedprograms.ProgramLanguage.P2'(D, E),
        'SharedPrograms':'Sharedprograms.MeltedBodyTyping.P8'(B, E, [], _, _, [], [], []),
        'programs.CompileObjectProgram.P1'(D),
        'Syntax':'Syntax.FormulaMaxVarIndex.P2'([B], F),
        'Syntax':'Syntax.EmptyTermSubst.P1'(G),
        'programs.RunAllGoal.P6'(B, F, G, C, _, _).
'~programs.SucceedAll.P3.0'(A, B, C) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, D),
        'SharedPrograms':'~Sharedprograms.ProgramLanguage.P2'(D, E),
        'SharedPrograms':'~Sharedprograms.MeltedBodyTyping.P8'(B, E, [], _, _, [], [], []),
        '~programs.CompileObjectProgram.P1'(D),
        'Syntax':'~Syntax.FormulaMaxVarIndex.P2'([B], F),
        'Syntax':'~Syntax.EmptyTermSubst.P1'(G),
        '~programs.RunAllGoal.P6'(B, F, G, C, _, _).
'programs.SymbolInTermList.P2'([A|B], C) :-
        (   'programs.SymbolInTerm.P2'(A, C)
        ;   'programs.SymbolInTermList.P2'(B, C)
        ).
'~programs.SymbolInTermList.P2'([A|B], C) :-
        (   '~programs.SymbolInTerm.P2'(A, C)
        ;   '~programs.SymbolInTermList.P2'(B, C)
        ).
'programs.SymbolInFormula.P2'('MetaDefs.PAtom.F1'(A), A).
'~programs.SymbolInFormula.P2'('MetaDefs.PAtom.F1'(A), A).
'programs.SymbolInFormula.P2'('MetaDefs.Atom.F2'(A,B), C) :-
        (   C=A
        ;   'programs.SymbolInTermList.P2'(B, C)
        ).
'~programs.SymbolInFormula.P2'('MetaDefs.Atom.F2'(A,B), C) :-
        (   C=A
        ;   '~programs.SymbolInTermList.P2'(B, C)
        ).
'programs.SymbolInFormula.P2'('MetaDefs.~''.F1'(A), B) :-
        'programs.SymbolInFormula.P2'(A, B).
'~programs.SymbolInFormula.P2'('MetaDefs.~''.F1'(A), B) :-
        '~programs.SymbolInFormula.P2'(A, B).
'programs.SymbolInFormula.P2'('MetaDefs.&''.F2'(A,B), C) :-
        (   'programs.SymbolInFormula.P2'(A, C)
        ;   'programs.SymbolInFormula.P2'(B, C)
        ).
'~programs.SymbolInFormula.P2'('MetaDefs.&''.F2'(A,B), C) :-
        (   '~programs.SymbolInFormula.P2'(A, C)
        ;   '~programs.SymbolInFormula.P2'(B, C)
        ).
'programs.SymbolInFormula.P2'('MetaDefs.\\/''.F2'(A,B), C) :-   % added \ djd
        (   'programs.SymbolInFormula.P2'(A, C)
        ;   'programs.SymbolInFormula.P2'(B, C)
        ).
'~programs.SymbolInFormula.P2'('MetaDefs.\\/''.F2'(A,B), C) :-  % added \ djd
        (   '~programs.SymbolInFormula.P2'(A, C)
        ;   '~programs.SymbolInFormula.P2'(B, C)
        ).
'programs.SymbolInFormula.P2'('MetaDefs.->''.F2'(A,B), C) :-
        (   'programs.SymbolInFormula.P2'(A, C)
        ;   'programs.SymbolInFormula.P2'(B, C)
        ).
'~programs.SymbolInFormula.P2'('MetaDefs.->''.F2'(A,B), C) :-
        (   '~programs.SymbolInFormula.P2'(A, C)
        ;   '~programs.SymbolInFormula.P2'(B, C)
        ).
'programs.SymbolInFormula.P2'('MetaDefs.<-''.F2'(A,B), C) :-
        (   'programs.SymbolInFormula.P2'(A, C)
        ;   'programs.SymbolInFormula.P2'(B, C)
        ).
'~programs.SymbolInFormula.P2'('MetaDefs.<-''.F2'(A,B), C) :-
        (   '~programs.SymbolInFormula.P2'(A, C)
        ;   '~programs.SymbolInFormula.P2'(B, C)
        ).
'programs.SymbolInFormula.P2'('MetaDefs.<->''.F2'(A,B), C) :-
        (   'programs.SymbolInFormula.P2'(A, C)
        ;   'programs.SymbolInFormula.P2'(B, C)
        ).
'~programs.SymbolInFormula.P2'('MetaDefs.<->''.F2'(A,B), C) :-
        (   '~programs.SymbolInFormula.P2'(A, C)
        ;   '~programs.SymbolInFormula.P2'(B, C)
        ).
'programs.SymbolInFormula.P2'('MetaDefs.All.F2'(_,A), B) :-
        'programs.SymbolInFormula.P2'(A, B).
'~programs.SymbolInFormula.P2'('MetaDefs.All.F2'(_,A), B) :-
        '~programs.SymbolInFormula.P2'(A, B).
'programs.SymbolInFormula.P2'('MetaDefs.Some.F2'(_,A), B) :-
        'programs.SymbolInFormula.P2'(A, B).
'~programs.SymbolInFormula.P2'('MetaDefs.Some.F2'(_,A), B) :-
        '~programs.SymbolInFormula.P2'(A, B).
'programs.SymbolInFormula.P2'('MetaDefs.ISTE.F4'(_,A,B,C), D) :-
        (   'programs.SymbolInFormula.P2'(A, D)
        ;   'programs.SymbolInFormula.P2'(B, D)
        ;   'programs.SymbolInFormula.P2'(C, D)
        ).
'~programs.SymbolInFormula.P2'('MetaDefs.ISTE.F4'(_,A,B,C), D) :-
        (   '~programs.SymbolInFormula.P2'(A, D)
        ;   '~programs.SymbolInFormula.P2'(B, D)
        ;   '~programs.SymbolInFormula.P2'(C, D)
        ).
'programs.SymbolInFormula.P2'('MetaDefs.ITE.F3'(A,B,C), D) :-
        (   'programs.SymbolInFormula.P2'(A, D)
        ;   'programs.SymbolInFormula.P2'(B, D)
        ;   'programs.SymbolInFormula.P2'(C, D)
        ).
'~programs.SymbolInFormula.P2'('MetaDefs.ITE.F3'(A,B,C), D) :-
        (   '~programs.SymbolInFormula.P2'(A, D)
        ;   '~programs.SymbolInFormula.P2'(B, D)
        ;   '~programs.SymbolInFormula.P2'(C, D)
        ).
'programs.SymbolInFormula.P2'('MetaDefs.IST.F3'(_,A,B), C) :-
        (   'programs.SymbolInFormula.P2'(A, C)
        ;   'programs.SymbolInFormula.P2'(B, C)
        ).
'~programs.SymbolInFormula.P2'('MetaDefs.IST.F3'(_,A,B), C) :-
        (   '~programs.SymbolInFormula.P2'(A, C)
        ;   '~programs.SymbolInFormula.P2'(B, C)
        ).
'programs.SymbolInFormula.P2'('MetaDefs.IT.F2'(A,B), C) :-
        (   'programs.SymbolInFormula.P2'(A, C)
        ;   'programs.SymbolInFormula.P2'(B, C)
        ).
'~programs.SymbolInFormula.P2'('MetaDefs.IT.F2'(A,B), C) :-
        (   '~programs.SymbolInFormula.P2'(A, C)
        ;   '~programs.SymbolInFormula.P2'(B, C)
        ).
'programs.SymbolInDelay.P2'('ProgDefs.Delay.F2'(A,_), B) :-
        'programs.SymbolInFormula.P2'(A, B).
'~programs.SymbolInDelay.P2'('ProgDefs.Delay.F2'(A,_), B) :-
        '~programs.SymbolInFormula.P2'(A, B).
'programs.SymbolInTerm.P2'('MetaDefs.CTerm.F1'(A), A).
'~programs.SymbolInTerm.P2'('MetaDefs.CTerm.F1'(A), A).
'programs.SymbolInTerm.P2'('MetaDefs.Term.F2'(A,B), C) :-
        (   A=C
        ;   'programs.SymbolInTermList.P2'(B, C)
        ).
'~programs.SymbolInTerm.P2'('MetaDefs.Term.F2'(A,B), C) :-
        (   A=C
        ;   '~programs.SymbolInTermList.P2'(B, C)
        ).
'programs.SymbolInTerm.P2'('MetaDefs.SuchThat.F2'(A,B), C) :-
        (   'programs.SymbolInTerm.P2'(A, C)
        ;   'programs.SymbolInFormula.P2'(B, C)
        ).
'~programs.SymbolInTerm.P2'('MetaDefs.SuchThat.F2'(A,B), C) :-
        (   '~programs.SymbolInTerm.P2'(A, C)
        ;   '~programs.SymbolInFormula.P2'(B, C)
        ).
'programs.TermInModule.P7'(A, B, C, D, E, F, G) :-
        user:goedel_freeze(ground([A,B,C,D,E]), 'Programs':'programs.TermInModule.P7.0'(A,B,C,D,E,F,G)).
'~programs.TermInModule.P7'(A, B, C, D, E, F, G) :-
        user:goedel_freeze(ground([A,B,C,D,E]), 'Programs':'~programs.TermInModule.P7.0'(A,B,C,D,E,F,G)).
'programs.TermInModule.P7.0'(A, B, C, D, E, F, G) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, H),
        'programs.CModulePart.P2'(C, I),
        'programs.ModulePartLanguage.P4'(I, B, H, J),
        'SharedPrograms':'Sharedprograms.TermInLanguage.P5'(E, J, D, G, F).
'~programs.TermInModule.P7.0'(A, B, C, D, E, F, G) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, H),
        '~programs.CModulePart.P2'(C, I),
        '~programs.ModulePartLanguage.P4'(I, B, H, J),
        'SharedPrograms':'~Sharedprograms.TermInLanguage.P5'(E, J, D, G, F).
'programs.TypeInModule.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C,D]), 'Programs':'programs.TypeInModule.P4.0'(A,B,C,D)).
'~programs.TypeInModule.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C,D]), 'Programs':'~programs.TypeInModule.P4.0'(A,B,C,D)).
'programs.TypeInModule.P4.0'(A, B, C, D) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, E),
        'programs.CModulePart.P2'(C, F),
        'programs.ModulePartLanguage.P4'(F, B, E, G),
        'SharedPrograms':'Sharedprograms.TypeInLanguage.P2'(D, G).
'~programs.TypeInModule.P4.0'(A, B, C, D) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, E),
        '~programs.CModulePart.P2'(C, F),
        '~programs.ModulePartLanguage.P4'(F, B, E, G),
        'SharedPrograms':'~Sharedprograms.TypeInLanguage.P2'(D, G).
'programs.TopLevelName.P2'(A, B) :-
        user:goedel_freeze(nonvar(A), 'Programs':'programs.TopLevelName.P2.0'(A,B)).
'~programs.TopLevelName.P2'(A, B) :-
        user:goedel_freeze(nonvar(A), 'Programs':'~programs.TopLevelName.P2.0'(A,B)).
'programs.TopLevelName.P2.0'('MetaDefs.PAtom.F1'(A), A).
'~programs.TopLevelName.P2.0'('MetaDefs.PAtom.F1'(A), A).
'programs.TopLevelName.P2.0'('MetaDefs.Atom.F2'(A,_), A).
'~programs.TopLevelName.P2.0'('MetaDefs.Atom.F2'(A,_), A).
'programs.TopLevelName.P2.0'('MetaDefs.XPAtom.F1'(A), A).
'~programs.TopLevelName.P2.0'('MetaDefs.XPAtom.F1'(A), A).
'programs.TopLevelName.P2.0'('MetaDefs.XAtom.F2'(A,_), A).
'~programs.TopLevelName.P2.0'('MetaDefs.XAtom.F2'(A,_), A).
'programs.TrueCondition.P1'('ProgDefs.TrueCond.C0').
'~programs.TrueCondition.P1'('ProgDefs.TrueCond.C0').
'programs.TypeSymbolInType.P2'('MetaDefs.BType.F1'(A), A).
'~programs.TypeSymbolInType.P2'('MetaDefs.BType.F1'(A), A).
'programs.TypeSymbolInType.P2'('MetaDefs.Type.F2'(A,B), C) :-
        (   A=C
        ;   'programs.TypeSymbolInTypeList.P2'(B, C)
        ).
'~programs.TypeSymbolInType.P2'('MetaDefs.Type.F2'(A,B), C) :-
        (   A=C
        ;   '~programs.TypeSymbolInTypeList.P2'(B, C)
        ).
'programs.TypeSymbolFreeInModule.P3'(A, B, 'ProgDefs.Program.F4'(_,_,'ProgDefs.Language.F1'(C),_)) :-
        'AVLTrees':'AVLTrees.AVLSearch.P3'(C, A, 'ProgDefs.Module.F3'(_,'ProgDefs.Categories.F2'(_,D),_)),
        user:goedel_freeze(ground([B,D]), user:goedel_not(user:goedel_freeze(ground([F,B,D]),user:goedel_not(((user:goedel_freeze(ground([E,D]),user:goedel_not('AVLTrees':'~AVLTrees.AVLMember.P3'(D,_,E)));user:goedel_freeze(ground([F,E]),user:goedel_not('Lists':'~Lists.Member.P2'('ProgDefs.Symbol.F2'(_,F),E))));user:goedel_freeze(ground([F,B]),user:goedel_not('Programs':'~programs.TypeSymbolInDeclaration.P2'(F,B)))))))).
'~programs.TypeSymbolFreeInModule.P3'(A, B, 'ProgDefs.Program.F4'(_,_,'ProgDefs.Language.F1'(C),_)) :-
        'AVLTrees':'~AVLTrees.AVLSearch.P3'(C, A, 'ProgDefs.Module.F3'(_,'ProgDefs.Categories.F2'(_,D),_)),
        user:goedel_freeze(ground([B,D]), user:goedel_not(user:goedel_freeze(ground([F,B,D]),user:goedel_not(((user:goedel_freeze(ground([E,D]),user:goedel_not('AVLTrees':'~AVLTrees.AVLMember.P3'(D,_,E)));user:goedel_freeze(ground([F,E]),user:goedel_not('Lists':'~Lists.Member.P2'('ProgDefs.Symbol.F2'(_,F),E))));user:goedel_freeze(ground([F,B]),user:goedel_not('Programs':'~programs.TypeSymbolInDeclaration.P2'(F,B)))))))).
'programs.TypeInProgram.P2'(A, B) :-
        user:goedel_freeze(ground([A,B]), 'Programs':'programs.TypeInProgram.P2.0'(A,B)).
'~programs.TypeInProgram.P2'(A, B) :-
        user:goedel_freeze(ground([A,B]), 'Programs':'~programs.TypeInProgram.P2.0'(A,B)).
'programs.TypeInProgram.P2.0'('ProgDefs.CachedProgram.F1'(A), B) :-
        'ProgramCache':'ProgramCache.GetCachedProgram.P2'(A, C),
        'programs.TypeInProgram.P2'(C, B).
'~programs.TypeInProgram.P2.0'('ProgDefs.CachedProgram.F1'(A), B) :-
        'ProgramCache':'~ProgramCache.GetCachedProgram.P2'(A, C),
        '~programs.TypeInProgram.P2'(C, B).
'programs.TypeInProgram.P2.0'('ProgDefs.Program.F4'(_,_,A,_), B) :-
        'SharedPrograms':'Sharedprograms.TypeInLanguage.P2'(B, A).
'~programs.TypeInProgram.P2.0'('ProgDefs.Program.F4'(_,_,A,_), B) :-
        'SharedPrograms':'~Sharedprograms.TypeInLanguage.P2'(B, A).
'programs.TypeSymbolInDeclaration.P2'('ProgDefs.ConstantDecl.F1'(A), B) :-
        'programs.TypeSymbolInType.P2'(A, B).
'~programs.TypeSymbolInDeclaration.P2'('ProgDefs.ConstantDecl.F1'(A), B) :-
        '~programs.TypeSymbolInType.P2'(A, B).
'programs.TypeSymbolInDeclaration.P2'('ProgDefs.FunctionDecl.F4'(_,_,A,B), C) :-
        (   'programs.TypeSymbolInTypeList.P2'(A, C)
        ;   'programs.TypeSymbolInType.P2'(B, C)
        ).
'~programs.TypeSymbolInDeclaration.P2'('ProgDefs.FunctionDecl.F4'(_,_,A,B), C) :-
        (   '~programs.TypeSymbolInTypeList.P2'(A, C)
        ;   '~programs.TypeSymbolInType.P2'(B, C)
        ).
'programs.TypeSymbolInDeclaration.P2'('ProgDefs.PredicateDecl.F3'(_,_,A), B) :-
        'programs.TypeSymbolInTypeList.P2'(A, B).
'~programs.TypeSymbolInDeclaration.P2'('ProgDefs.PredicateDecl.F3'(_,_,A), B) :-
        '~programs.TypeSymbolInTypeList.P2'(A, B).
'programs.UnreferencedModule.P2'(A, B) :-
        user:goedel_freeze(ground([E,A,B]), user:goedel_not(('AVLTrees':'~AVLTrees.AVLMember.P3'(B,_,'ProgDefs.ModDef.F4'(_,C,D,E)),('Lists':'~Lists.Member.P2'(A,D);'Lists':'~Lists.Member.P2'(A,C);'Lists':'~Lists.Member.P2'(A,E))))).
'~programs.UnreferencedModule.P2'(A, B) :-
        user:goedel_freeze(ground([E,A,B]), user:goedel_not(('AVLTrees':'~AVLTrees.AVLMember.P3'(B,_,'ProgDefs.ModDef.F4'(_,C,D,E)),('Lists':'~Lists.Member.P2'(A,D);'Lists':'~Lists.Member.P2'(A,C);'Lists':'~Lists.Member.P2'(A,E))))).
'programs.TypeSymbolInTypeList.P2'([A|B], C) :-
        (   'programs.TypeSymbolInType.P2'(A, C)
        ;   'programs.TypeSymbolInTypeList.P2'(B, C)
        ).
'~programs.TypeSymbolInTypeList.P2'([A|B], C) :-
        (   '~programs.TypeSymbolInType.P2'(A, C)
        ;   '~programs.TypeSymbolInTypeList.P2'(B, C)
        ).
'programs.ValidDeclaration.P4'('ProgDefs.BaseDecl.C0', _, _, _).
'~programs.ValidDeclaration.P4'('ProgDefs.BaseDecl.C0', _, _, _).
'programs.ValidDeclaration.P4'('ProgDefs.ConstructorDecl.F1'(_), _, _, _).
'~programs.ValidDeclaration.P4'('ProgDefs.ConstructorDecl.F1'(_), _, _, _).
'programs.ValidDeclaration.P4'('ProgDefs.ConstantDecl.F1'(A), B, C, D) :-
        'programs.TypeInModule.P4'(B, C, D, A),
        'programs.RightHandType.P4'(A, B, C, D).
'~programs.ValidDeclaration.P4'('ProgDefs.ConstantDecl.F1'(A), B, C, D) :-
        '~programs.TypeInModule.P4'(B, C, D, A),
        '~programs.RightHandType.P4'(A, B, C, D).
'programs.ValidDeclaration.P4'('ProgDefs.FunctionDecl.F4'(_,_,A,B), C, D, E) :-
        'programs.ListTypesInModule.P4'(C, D, E, [B|A]),
        'programs.RightHandType.P4'(B, C, D, E),
        'programs.Transparent.P2'(A, B).
'~programs.ValidDeclaration.P4'('ProgDefs.FunctionDecl.F4'(_,_,A,B), C, D, E) :-
        '~programs.ListTypesInModule.P4'(C, D, E, [B|A]),
        '~programs.RightHandType.P4'(B, C, D, E),
        '~programs.Transparent.P2'(A, B).
'programs.ValidDeclaration.P4'('ProgDefs.PropositionDecl.C0', _, _, _).
'~programs.ValidDeclaration.P4'('ProgDefs.PropositionDecl.C0', _, _, _).
'programs.ValidDeclaration.P4'('ProgDefs.PredicateDecl.F3'(_,_,A), B, C, D) :-
        'programs.ListTypesInModule.P4'(B, C, D, A).
'~programs.ValidDeclaration.P4'('ProgDefs.PredicateDecl.F3'(_,_,A), B, C, D) :-
        '~programs.ListTypesInModule.P4'(B, C, D, A).
%------------------------------------------------------------------------------
% Supplementary Prolog routines for system module Program
%------------------------------------------------------------------------------
%------------------------------------------------------------------------------
% String to Ground Representation conversion
%------------------------------------------------------------------------------

'programs.StringToProgramTypeAux.P4'(Program, Module, String, [Type]) :-
   name(String, [0'"|Chars]),
   user:append(Chars, [0'.], Chars1),
   user:get_one_item_2nd_aux(Chars1, Remains, Tokens),
   Remains = [],
   user:'Parserprograms.LocalSymbolTable.P3'(Program, Module, SymbolTable),
   user:declared_type(Tokens, RestTokens, [], Type, _ModuleName, 0, 0,
			SymbolTable, donot_print),
   Type \== null,
   RestTokens = [].

'~programs.StringToProgramTypeAux.P4'(Program, Module, String, Types) :-
   'programs.StringToProgramTypeAux.P4'(Program, Module, String, Types).

%------------------------------------------------------------------------------
 
'programs.StringToProgramTermAux.P4'(Program, Module, String, Terms) :-
   name(String, [0'"|Chars]),
   user:append(Chars, [0'.], Chars1),
   user:get_one_item_2nd_aux(Chars1, Remains, Tokens),
   Remains = [],
   user:'Parserprograms.LocalSymbolTable.P3'(Program, Module, SymbolTable),
   user:term(Tokens, Return, SymbolTable),
   ( user:select_return(Return, null, Terms2, Remains, _ErrorReturn)
     -> Remains = []
     ;  format(user_error, 'Internal error No 29.~n', [])
   ),
   Terms2 = [_|_],
   user:'Sharedprograms.ProgramLanguage.P2'(Program, Language),
   user:'Parserprograms.CheckTermAux.P6'(Terms2, Language, 0, [], Terms, []).

'~programs.StringToProgramTermAux.P4'(Program, Module, String, Terms) :-
   'programs.StringToProgramTermAux.P4'(Program, Module, String, Terms).

%------------------------------------------------------------------------------
 
% OFormula ::= Statement | Body | Goal
% NB: the colon notation for Goal is not accepted

'programs.StringToProgramFormulaAux.P4'(Program, Module, String, Formulae) :-
   name(String, [0'"|Chars]),
   user:append(Chars, [0'.], Chars1),
   user:get_one_item_2nd_aux(Chars1, Rest, Tokens),
   Rest= [],
   user:'Parserprograms.LocalSymbolTable.P3'(Program, Module, SymbolTable),
   ( Tokens = [graphic_name('<-')|Tokens2]
     -> ( Tokens2 = []
	  -> CFormulae = ['MetaDefs.<-''.F2'('MetaDefs.Empty.C0','MetaDefs.Empty.C0')]
	  ;  user:body(Tokens2, CFormulae2, _ErrorReturn1, SymbolTable),
             CFormulae2 = [_|_],
	     user:create_formula('MetaDefs.<-''.F2',
			[['MetaDefs.Empty.C0'], CFormulae2], CFormulae)
	)
     ;  user:headatom(Tokens, Remains, Module, HeadAtoms, _ErrorReturn2,
			SymbolTable),
	( ( HeadAtoms = [];
	    \+ Remains = [graphic_name('<-')|_] % this covers the case of atom
	  )
	  -> user:body(Tokens, CFormulae, _ErrorReturn3, SymbolTable),
             CFormulae = [_|_]
	  ;  Remains = [graphic_name('<-')|Remains2],
	     ( Remains2 = []
	       -> user:create_formula('MetaDefs.<-''.F2',
				[HeadAtoms, ['MetaDefs.Empty.C0']], CFormulae)
	       ;  user:body(Remains2, BodyFormulae, _ErrorReturn4, SymbolTable),
                  BodyFormulae = [_|_],
		  user:create_formula('MetaDefs.<-''.F2',
				[HeadAtoms, BodyFormulae], CFormulae)
	     )
	)
   ),
   user:'Sharedprograms.ProgramLanguage.P2'(Program, Language),
   user:'Parserprograms.CheckFormulaAux.P6'(CFormulae, Language, 0, []
      , Formulae, _),
   Formulae = [_|_]. % Fail if no parses are well-typed

'~programs.StringToProgramFormulaAux.P4'(Program, Module, String, Formulae) :-
   'programs.StringToProgramFormulaAux.P4'(Program, Module, String, Formulae).

%------------------------------------------------------------------------------
% New Program
%------------------------------------------------------------------------------

% problem: AVLTrees is taken as a system module and loaded automatically

'programs.NewProgramAux.P2'(Program, MainModule) :-
   ( user:system_module_name(MainModule) -> 
     user:gstring2string(MainModule, Str),
     user:load_system_module(Str, Program)
   ; user:'Sharedprograms.NextModuleVersion.P2'(MainModule, Version),
     user:'Sharedprograms.ProgramSkeleton.P4'(MainModule
        , 'ProgDefs.NormalKind.C0', Version, Program)
   ).

'~programs.NewProgramAux.P2'(Program, MainModule) :-
   'programs.NewProgramAux.P2'(Program, MainModule).

%------------------------------------------------------------------------------
% Transparency check
%------------------------------------------------------------------------------

'programs.Transparent.P2'(DomainType, RangeType) :-
   user:transparency_check(DomainType, RangeType).

'~programs.Transparent.P2'(DomainType, RangeType) :-
   user:transparency_check(DomainType, RangeType).

%------------------------------------------------------------------------------
% Module manipulation
%------------------------------------------------------------------------------

'programs.ModuleInProgramAux.P2'(Modules, Module) :-
   ( var(Module) ->
     (user:'AVLTrees.AVLMember.P3'(Modules, Module, _); Module = '"')
   ; ( Module == '"' ->
       true
     ; user:'AVLTrees.AVLSearch.P3'(Modules, Module, _)
     )
   ).

'~programs.ModuleInProgramAux.P2'(Modules, Module) :-
   'programs.ModuleInProgramAux.P2'(Modules, Module).

%------------------------------------------------------------------------------
% Support for Succeed (primitive version)
%------------------------------------------------------------------------------

:- dynamic compiled_module_version/2.

'programs.EnsureCompiled.P3'(Module, Version, Code) :-
   ( compiled_module_version(Module, Version) ->
     true
   ; user:compile_object_module(Module, Code),
     retractall(compiled_module_version(Module, _)),
     assert(compiled_module_version(Module, Version))
   ).   

'~programs.EnsureCompiled.P3'(Module, Version, Code) :-
   'programs.EnsureCompiled.P3'(Module, Version, Code).


% 'programs.EnsureLoaded.P1'(GModule) :-
%    ( user:loaded(GModule) ->
%      true
%    ; user:gstring2string(GModule, Module),
%      user:file_finder(Module, _, PrologFile, _),
%      nofileerrors,
%      ( load(PrologFile) ->
%        assert(user:loaded(GModule))
%      ; format(user_error, 'Succeed: can''t find file ~a~n', [PrologFile])
%      ),
%      fileerrors
%    ).
% 
% '~programs.EnsureLoaded.P1'(GModule) :-
%    'programs.EnsureLoaded.P1'(GModule).

'programs.EnsureLoaded.P1'(M) :-
   user:system_module_name(M).

'~programs.EnsureLoaded.P1'(M) :-
   'programs.EnsureLoaded.P1'(M).


'programs.RunAllGoal.P6'(Goal, FirstFree, InputSubst, Answers, LastFree
      , Residues
      ) :-
   user:compile_object_goal(Goal, ReflectedGoal, FreeVars, VarDict, []),
   findall( (VarDict, Suspended), 
            execute_goal(ReflectedGoal, Suspended),
            Results
          ),
   make_results(Results, FreeVars, FirstFree, InputSubst, FirstFree, Answers
      , Residues, LastFree).

'~programs.RunAllGoal.P6'(Goal, FirstFree, InputSubst, Answers, LastFree
      , Residues
      ) :-
   'programs.RunAllGoal.P6'(Goal, FirstFree, InputSubst, Answers, LastFree
      , Residues).


make_results([], _, _, _, MaxFree, [], [], MaxFree).

make_results([(VarDict, Unsolved)|Results], FreeVars, FirstFree, InputSubst
      , MaxFreeSoFar, [Answer|Answers], [Residue|Residues], MaxFree
      ) :-
   make_answer_subst(FreeVars, VarDict, FirstFree, InputSubst, Answer
      , Free1),
   make_residue(Unsolved, Free1, Residue, NextFree),
   ( NextFree > MaxFreeSoFar ->
     NewMaxSoFar = NextFree
   ; NewMaxSoFar = MaxFreeSoFar
   ),
   make_results(Results, FreeVars, FirstFree, InputSubst, NewMaxSoFar
      , Answers, Residues, MaxFree).


'programs.RunGoal.P6'(Goal, FirstFree, InputSubst, Answer, LastFree
      , Residue
      ) :-
   user:compile_object_goal(Goal, ReflectedGoal, FreeVars, VarDict, []),
   execute_goal(ReflectedGoal, Unsolved),
   make_answer_subst(FreeVars, VarDict, FirstFree, InputSubst, Answer
      , Free1),
   make_residue(Unsolved, Free1, Residue, LastFree).

'~programs.RunGoal.P6'(Goal, FirstFree, InputSubst, Answer, LastFree
      , Residue
      ) :-
   'programs.RunGoal.P6'(Goal, FirstFree, InputSubst, Answer, LastFree
      , Residue).


'programs.FailedGoal.P1'(Goal) :-
   user:compile_object_goal(Goal, ReflectedGoal, _, _, [0'~]),
   execute_goal(\+ ReflectedGoal, []).

'~programs.FailedGoal.P1'(Goal) :-
   'programs.FailedGoal.P1'(Goal).


execute_goal(ReflectedGoal, Suspended) :-
   on_exception(catch_in_query, 
      call_residue(ReflectedGoal, Suspended),
      fail).                               % fail if an exception occurs


make_answer_subst([], _, Free, Answer, Answer, Free).

make_answer_subst([Var|Vars], VarDict, VarNumber, SubstSoFar, Answer
      , NewVarNumber
      ) :-
   user:member(Var/Value, VarDict), !,
   user:pobj_to_ground(Value, VarNumber, VarNumber1, GroundTerm),
   'Substs':'Substs.BindVariable.P4'(Var, GroundTerm, SubstSoFar, SubstSoFar1),
   make_answer_subst(Vars, VarDict, VarNumber1, SubstSoFar1, Answer
      , NewVarNumber).


make_residue(Unsolved, FirstFree, Residue, LastFree) :-
   clean_unsolved_goals(Unsolved, CleanUnsolved),
   make_residue1(CleanUnsolved, FirstFree, Residue, LastFree).


make_residue1([], LastFree, 'MetaDefs.Empty.C0', LastFree).

make_residue1([Goal|Goals], FirstFree, Residue, LastFree) :-
   patom_to_ground(Goal, FirstFree, Ground, Free1),
   make_residue2(Goals, Free1, Ground, Residue, LastFree).


make_residue2([], LastFree, Residue, Residue, LastFree).

make_residue2([Goal|Goals], FirstFree, SoFar, Residue, LastFree) :-
   patom_to_ground(Goal, FirstFree, Ground, Free1),
   make_residue2(Goals, Free1, 'MetaDefs.&''.F2'(SoFar, Ground), Residue
      , LastFree).


patom_to_ground(Atom, VarNo, Ground, NewVarNo) :-
   ( Atom = not_equal(_, Term1, Term2) ->
     user:list_pobj_to_ground([Term1, Term2], VarNo, NewVarNo, GArgs),
     Ground = 'MetaDefs.Atom.F2'('MetaDefs.Name.F4'('"', '"~='
        , 'MetaDefs.Predicate.C0', 2), GArgs)
   ; Atom = Module:RealAtom ->   % deals with constraints
     RealAtom =.. [Predicate|ExtendedArgs],
     remove_last(ExtendedArgs, Args, Last),
     constraint_goal_conversion(Module, Predicate, GSymbol, Arity),
     user:string2Gstring(Module, GModule),
     Name = 'MetaDefs.Name.F4'(GModule, GSymbol, 'MetaDefs.Function.C0', Arity),
     Ground = 'MetaDefs.Atom.F2'('MetaDefs.Name.F4'('"','"=',
                                         'MetaDefs.Predicate.C0',2),
                          [Left, 'MetaDefs.Term.F2'(Name, GArgs)]),
     user:pobj_to_ground(Last, VarNo, VarNo2, Left),
     user:list_pobj_to_ground(Args, VarNo2, NewVarNo, GArgs)      
   ; Atom =.. [Predicate|Args],
     user:string2Gstring(Predicate, PredString),
     user:symbol_name(Name, PredString),
     ( Args = [] ->
       Ground = 'MetaDefs.PAtom.F1'(Name),
       NewVarNo = VarNo
     ; Ground = 'MetaDefs.Atom.F2'(Name, GArgs),
       user:list_pobj_to_ground(Args, VarNo, NewVarNo, GArgs)
     )
   ).

remove_last([X], [], X) :- !.
remove_last([X|Xs], [X|Ys], Z) :-
   remove_last(Xs, Ys, Z).

clean_unsolved_goals([], []).

clean_unsolved_goals([_-Goal|Goals], NewGoals) :-
   clean_unsolved_goals_aux(Goal, NewGoal),
   ( NewGoal = null
     -> NewGoals = NewGoals2
     ;  NewGoals = [NewGoal|NewGoals2]
   ),
   clean_unsolved_goals(Goals, NewGoals2).


clean_unsolved_goals_aux(freeze_on_vlist(_, _, _, _), null) :- !.
clean_unsolved_goals_aux(_:freeze_on_vlist(_, _, _, _), null) :- !.

clean_unsolved_goals_aux(freeze_nonvar_and(_, _, _), null) :- !.
clean_unsolved_goals_aux(_:freeze_nonvar_and(_, _, _), null) :- !.

clean_unsolved_goals_aux(evaluate_delay_aux(_, _), null) :- !.
clean_unsolved_goals_aux(_:evaluate_delay_aux(_, _), null) :- !.

clean_unsolved_goals_aux(my_freeze(_, _:Goal, _), NewGoal) :- !,
   clean_unsolved_goals_aux(Goal, NewGoal).
clean_unsolved_goals_aux(_:my_freeze(_, _:Goal, _), NewGoal) :- !,
   clean_unsolved_goals_aux(Goal, NewGoal).

clean_unsolved_goals_aux(call(Goal), NewGoal) :- !,
   clean_unsolved_goals_aux(Goal, NewGoal).
clean_unsolved_goals_aux(_:call(Goal), NewGoal) :- !,
   clean_unsolved_goals_aux(Goal, NewGoal).

clean_unsolved_goals_aux(Module:Goal, NewGoal) :- !,
   ( constraint_goal(Module, Goal) ->
     NewGoal = Module:Goal
   ; clean_unsolved_goals_aux(Goal, NewGoal)
   ).

clean_unsolved_goals_aux(Goal, Goal) :- !.


constraint_goal(Module, Goal) :-
   module_with_constraints(Module),
   Goal =.. [Predicate|_],
   constraint_goal_conversion(Module, Predicate, _, _).


module_with_constraints('Integers').
module_with_constraints('Rationals').
module_with_constraints('Strings').
module_with_constraints('Sets').

constraint_goal_conversion('Integers', negative, '"-', 1):- !.
constraint_goal_conversion('Integers', minus, '"-', 2):- !.
constraint_goal_conversion('Integers', plus, '"+', 2):- !.
constraint_goal_conversion('Integers', times, '"*', 2):- !.
constraint_goal_conversion('Integers', divides, '"Div', 2):- !.
constraint_goal_conversion('Integers', power, '"^', 2):- !.
constraint_goal_conversion('Integers', mod, '"Mod', 2):- !.
constraint_goal_conversion('Integers', maximum, '"Max', 2):- !.
constraint_goal_conversion('Integers', minimum, '"Min', 2):- !.
constraint_goal_conversion('Integers', absolute, '"Abs', 1):- !.

constraint_goal_conversion('Rationals', negative, '"-', 1):- !.
constraint_goal_conversion('Rationals', minus, '"-', 2):- !.
constraint_goal_conversion('Rationals', plus, '"+', 2):- !.
constraint_goal_conversion('Rationals', times, '"*', 2):- !.
constraint_goal_conversion('Rationals', divides, '"/', 2):- !.
constraint_goal_conversion('Rationals', power, '"^', 2):- !.
constraint_goal_conversion('Rationals', mod, '"Mod', 2):- !.
constraint_goal_conversion('Rationals', maximum, '"Max', 2):- !.
constraint_goal_conversion('Rationals', minimum, '"Min', 2):- !.
constraint_goal_conversion('Rationals', absolute, '"Abs', 1):- !.
constraint_goal_conversion('Rationals', rational, '"//', 2):- !.

constraint_goal_conversion('Sets', normalise, '"Inc', 2):- !. % Wrong!
constraint_goal_conversion('Sets', diff, '"\\', 2):- !.   % added \ djd          
constraint_goal_conversion('Sets', set_of, '"SuchThat', 3):- !.

constraint_goal_conversion('Strings', concat, '"++', 2):- !.
%% :- module('SharedPrograms', []).
:- module(sharedPrograms).  %% converted djd

:- discontiguous 'sharedPrograms.ChainExprToIntDL.P6'/6. %% added djd
:- discontiguous '~sharedPrograms.ChainExprToIntDL.P6'/6. %% added djd
:- discontiguous 'sharedPrograms.AddOtherModulesAux.P7'/7. %% added djd
:- discontiguous '~sharedPrograms.AddOtherModulesAux.P7'/7. %% added djd
:- discontiguous 'sharedPrograms.AddImportToPart.P6'/6. %% added djd
:- discontiguous '~sharedPrograms.AddImportToPart.P6'/6. %% added djd
:- discontiguous 'sharedPrograms.Accessible.P2'/2. %% added djd
:- discontiguous '~sharedPrograms.Accessible.P2'/2. %% added djd
:- discontiguous 'sharedPrograms.AddLiftedLanguage.P4'/4. %% added djd
:- discontiguous '~sharedPrograms.AddLiftedLanguage.P4'/4. %% added djd
:- discontiguous 'sharedPrograms.BinaryConnective.P3'/3. %% added djd
:- discontiguous '~sharedPrograms.BinaryConnective.P3'/3. %% added djd
:- discontiguous 'sharedPrograms.AtomToIntDL.P8'/8. %% added djd
:- discontiguous '~sharedPrograms.AtomToIntDL.P8'/8. %% added djd
:- discontiguous 'sharedPrograms.BinConnectiveChars.P3'/3. %% added djd
:- discontiguous '~sharedPrograms.BinConnectiveChars.P3'/3. %% added djd
:- discontiguous 'sharedPrograms.CLPrec.P2'/2. %% added djd
:- discontiguous '~sharedPrograms.CLPrec.P2'/2. %% added djd
:- discontiguous 'sharedPrograms.BindsTighter.P2'/2. %% added djd
:- discontiguous '~sharedPrograms.BindsTighter.P2'/2. %% added djd
:- discontiguous 'sharedPrograms.CRPrec.P2'/2. %% added djd
:- discontiguous '~sharedPrograms.CRPrec.P2'/2. %% added djd
:- discontiguous 'sharedPrograms.CheckHeadArgs1.P4'/4. %% added djd
:- discontiguous '~sharedPrograms.CheckHeadArgs1.P4'/4. %% added djd
:- discontiguous 'sharedPrograms.CheckHeadArgs.P4'/4. %% added djd
:- discontiguous '~sharedPrograms.CheckHeadArgs.P4'/4. %% added djd
:- discontiguous 'sharedPrograms.ContainsConditional.P1'/1. %% added djd
:- discontiguous '~sharedPrograms.ContainsConditional.P1'/1. %% added djd
:- discontiguous 'sharedPrograms.DivideBindings.P4'/4. %% added djd
:- discontiguous '~sharedPrograms.DivideBindings.P4'/4. %% added djd
:- discontiguous 'sharedPrograms.DeleteUnderscores.P2'/2. %% added djd
:- discontiguous '~sharedPrograms.DeleteUnderscores.P2'/2. %% added djd
:- discontiguous 'sharedPrograms.DivideBindingsAux.P5'/5. %% added djd
:- discontiguous '~sharedPrograms.DivideBindingsAux.P5'/5. %% added djd
:- discontiguous 'sharedPrograms.ExpandStringAux.P3'/3. %% added djd
:- discontiguous '~sharedPrograms.ExpandStringAux.P3'/3. %% added djd
:- discontiguous 'sharedPrograms.FixVariableTyping.P2'/2. %% added djd
:- discontiguous '~sharedPrograms.FixVariableTyping.P2'/2. %% added djd
:- discontiguous 'sharedPrograms.FormulaToIntDL.P6'/6. %% added djd
:- discontiguous '~sharedPrograms.FormulaToIntDL.P6'/6. %% added djd
:- discontiguous 'sharedPrograms.ImportedLanguage.P6'/6. %% added djd
:- discontiguous '~sharedPrograms.ImportedLanguage.P6'/6. %% added djd
:- discontiguous 'sharedPrograms.HeadAtom.P9'/9. %% added djd
:- discontiguous '~sharedPrograms.HeadAtom.P9'/9. %% added djd
:- discontiguous 'sharedPrograms.KindHasPart.P2'/2. %% added djd
:- discontiguous '~sharedPrograms.KindHasPart.P2'/2. %% added djd
:- discontiguous 'sharedPrograms.IsVariable.P1'/1. %% added djd
:- discontiguous '~sharedPrograms.IsVariable.P1'/1. %% added djd
:- discontiguous 'sharedPrograms.LPrec.P2'/2. %% added djd
:- discontiguous '~sharedPrograms.LPrec.P2'/2. %% added djd
:- discontiguous 'sharedPrograms.ListTypesInLanguage.P2'/2. %% added djd
:- discontiguous '~sharedPrograms.ListTypesInLanguage.P2'/2. %% added djd
:- discontiguous 'sharedPrograms.LookupParDictAux.P5'/5. %% added djd
:- discontiguous '~sharedPrograms.LookupParDictAux.P5'/5. %% added djd
:- discontiguous 'sharedPrograms.LookupVarTypingAux.P5'/5. %% added djd
:- discontiguous '~sharedPrograms.LookupVarTypingAux.P5'/5. %% added djd
:- discontiguous 'sharedPrograms.MeltVariableTyping.P4'/4. %% added djd
:- discontiguous '~sharedPrograms.MeltVariableTyping.P4'/4. %% added djd
:- discontiguous 'sharedPrograms.MeltType.P4'/4. %% added djd
:- discontiguous '~sharedPrograms.MeltType.P4'/4. %% added djd
:- discontiguous 'sharedPrograms.MatchingName.P3'/3. %% added djd
:- discontiguous '~sharedPrograms.MatchingName.P3'/3. %% added djd
:- discontiguous 'sharedPrograms.MeltTypeList.P4'/4. %% added djd
:- discontiguous '~sharedPrograms.MeltTypeList.P4'/4. %% added djd
:- discontiguous 'sharedPrograms.MeltedAtomTyping.P8'/8. %% added djd
:- discontiguous '~sharedPrograms.MeltedAtomTyping.P8'/8. %% added djd
:- discontiguous 'sharedPrograms.MeltedArgumentTyping.P9'/9. %% added djd
:- discontiguous '~sharedPrograms.MeltedArgumentTyping.P9'/9. %% added djd
:- discontiguous 'sharedPrograms.MeltedTermType.P9'/9. %% added djd
:- discontiguous '~sharedPrograms.MeltedTermType.P9'/9. %% added djd
:- discontiguous 'sharedPrograms.MeltedStandardTyping.P8'/8. %% added djd
:- discontiguous '~sharedPrograms.MeltedStandardTyping.P8'/8. %% added djd
:- discontiguous 'sharedPrograms.OpenKind.P1'/1. %% added djd
:- discontiguous '~sharedPrograms.OpenKind.P1'/1. %% added djd
:- discontiguous 'sharedPrograms.MustBracketThen.P1'/1. %% added djd
:- discontiguous '~sharedPrograms.MustBracketThen.P1'/1. %% added djd
:- discontiguous 'sharedPrograms.QuantifiedFormula.P3'/3. %% added djd
:- discontiguous '~sharedPrograms.QuantifiedFormula.P3'/3. %% added djd
:- discontiguous 'sharedPrograms.RPrec.P2'/2. %% added djd
:- discontiguous '~sharedPrograms.RPrec.P2'/2. %% added djd
:- discontiguous 'sharedPrograms.QuantifierChars.P3'/3. %% added djd
:- discontiguous '~sharedPrograms.QuantifierChars.P3'/3. %% added djd
:- discontiguous 'sharedPrograms.ReformatDelays.P3'/3. %% added djd
:- discontiguous '~sharedPrograms.ReformatDelays.P3'/3. %% added djd
:- discontiguous 'sharedPrograms.RestVarListToIntDL.P6'/6. %% added djd
:- discontiguous '~sharedPrograms.RestVarListToIntDL.P6'/6. %% added djd
:- discontiguous 'sharedPrograms.SimpleCondToIntDL.P3'/3. %% added djd
:- discontiguous '~sharedPrograms.SimpleCondToIntDL.P3'/3. %% added djd
:- discontiguous 'sharedPrograms.TypeInLanguage.P2'/2. %% added djd
:- discontiguous '~sharedPrograms.TypeInLanguage.P2'/2. %% added djd
:- discontiguous 'sharedPrograms.TermToIntDL.P9'/9. %% added djd
:- discontiguous '~sharedPrograms.TermToIntDL.P9'/9. %% added djd
:- discontiguous 'sharedPrograms.TermListToIntDLAux.P6'/6. %% added djd
:- discontiguous '~sharedPrograms.TermListToIntDLAux.P6'/6. %% added djd
:- discontiguous 'sharedPrograms.TermToIntDLAux.P11'/11. %% added djd
:- discontiguous '~sharedPrograms.TermToIntDLAux.P11'/11. %% added djd
:- discontiguous 'sharedPrograms.TypeListToIntDLAux.P4'/4. %% added djd
:- discontiguous '~sharedPrograms.TypeListToIntDLAux.P4'/4. %% added djd
:- discontiguous 'sharedPrograms.TypeToIntDL.P4'/4. %% added djd
:- discontiguous '~sharedPrograms.TypeToIntDL.P4'/4. %% added djd
:- discontiguous 'sharedPrograms.UpdateDelays.P6'/6. %% added djd
:- discontiguous '~sharedPrograms.UpdateDelays.P6'/6. %% added djd


:- op(500, yfx, and).
:- op(400, yfx, or).

'sharedPrograms.ModulePartInProgram.P3'('ProgDefs.Program.F4'(_,A,_,_), B, C) :-
        'sharedPrograms.AVLFind.P3'(A, B, 'ProgDefs.ModDef.F4'(D,_,_,_)),
        'sharedPrograms.KindHasPart.P2'(D, C).
'~sharedPrograms.ModulePartInProgram.P3'('ProgDefs.Program.F4'(_,A,_,_), B, C) :-
        '~sharedPrograms.AVLFind.P3'(A, B, 'ProgDefs.ModDef.F4'(D,_,_,_)),
        '~sharedPrograms.KindHasPart.P2'(D, C).
'sharedPrograms.InitialiseLanguage.P2'(A, B) :-
        'sharedPrograms.InsertSymbol.P5'('MetaDefs.Name.F4'('"','"True','MetaDefs.Proposition.C0',0), A, 'ProgDefs.Exported.C0', 'ProgDefs.PropositionDecl.C0', C),
        'sharedPrograms.InsertSymbol.P5'('MetaDefs.Name.F4'('"','"False','MetaDefs.Proposition.C0',0), C, 'ProgDefs.Exported.C0', 'ProgDefs.PropositionDecl.C0', D),
        'sharedPrograms.InsertSymbol.P5'('MetaDefs.Name.F4'('"','"=','MetaDefs.Predicate.C0',2), D, 'ProgDefs.Exported.C0', 'ProgDefs.PredicateDecl.F3'(2,'Syntax.ZPZ.C0',['MetaDefs.Par.F1'(0),'MetaDefs.Par.F1'(0)]), E),
        'sharedPrograms.InsertSymbol.P5'('MetaDefs.Name.F4'('"','"~=','MetaDefs.Predicate.C0',2), E, 'ProgDefs.Exported.C0', 'ProgDefs.PredicateDecl.F3'(2,'Syntax.ZPZ.C0',['MetaDefs.Par.F1'(0),'MetaDefs.Par.F1'(0)]), B).
'~sharedPrograms.InitialiseLanguage.P2'(A, B) :-
        '~sharedPrograms.InsertSymbol.P5'('MetaDefs.Name.F4'('"','"True','MetaDefs.Proposition.C0',0), A, 'ProgDefs.Exported.C0', 'ProgDefs.PropositionDecl.C0', C),
        '~sharedPrograms.InsertSymbol.P5'('MetaDefs.Name.F4'('"','"False','MetaDefs.Proposition.C0',0), C, 'ProgDefs.Exported.C0', 'ProgDefs.PropositionDecl.C0', D),
        '~sharedPrograms.InsertSymbol.P5'('MetaDefs.Name.F4'('"','"=','MetaDefs.Predicate.C0',2), D, 'ProgDefs.Exported.C0', 'ProgDefs.PredicateDecl.F3'(2,'Syntax.ZPZ.C0',['MetaDefs.Par.F1'(0),'MetaDefs.Par.F1'(0)]), E),
        '~sharedPrograms.InsertSymbol.P5'('MetaDefs.Name.F4'('"','"~=','MetaDefs.Predicate.C0',2), E, 'ProgDefs.Exported.C0', 'ProgDefs.PredicateDecl.F3'(2,'Syntax.ZPZ.C0',['MetaDefs.Par.F1'(0),'MetaDefs.Par.F1'(0)]), B).
'sharedPrograms.ChainExprToIntDL.P6'('MetaDefs.CTerm.F1'(_), _, _, _, A, A).
'~sharedPrograms.ChainExprToIntDL.P6'('MetaDefs.CTerm.F1'(_), _, _, _, A, A).
'sharedPrograms.ChainExprToIntDL.P6'('MetaDefs.Var.F2'(A,B), C, D, E, F, G) :-
        'sharedPrograms.CharDL.P3'('"|', F, H),
        'sharedPrograms.TermToIntDL.P9'('MetaDefs.Var.F2'(A,B), C, D, E, _, _, _, H, G).
'~sharedPrograms.ChainExprToIntDL.P6'('MetaDefs.Var.F2'(A,B), C, D, E, F, G) :-
        '~sharedPrograms.CharDL.P3'('"|', F, H),
        '~sharedPrograms.TermToIntDL.P9'('MetaDefs.Var.F2'(A,B), C, D, E, _, _, _, H, G).
'sharedPrograms.ChainExprToIntDL.P6'('MetaDefs.Var.F1'(A), B, C, D, E, F) :-
        'sharedPrograms.CharDL.P3'('"|', E, G),
        'sharedPrograms.TermToIntDL.P9'('MetaDefs.Var.F1'(A), B, C, D, _, _, _, G, F).
'~sharedPrograms.ChainExprToIntDL.P6'('MetaDefs.Var.F1'(A), B, C, D, E, F) :-
        '~sharedPrograms.CharDL.P3'('"|', E, G),
        '~sharedPrograms.TermToIntDL.P9'('MetaDefs.Var.F1'(A), B, C, D, _, _, _, G, F).
'sharedPrograms.ChainExprToIntDL.P6'('MetaDefs.Term.F2'(_,[A,B]), C, D, E, F, G) :-
        'sharedPrograms.CharDL.P3'('",', F, H),
        'sharedPrograms.TermToIntDL.P9'(A, C, D, E, _, _, _, H, I),
        'sharedPrograms.ChainExprToIntDL.P6'(B, C, D, E, I, G).
'~sharedPrograms.ChainExprToIntDL.P6'('MetaDefs.Term.F2'(_,[A,B]), C, D, E, F, G) :-
        '~sharedPrograms.CharDL.P3'('",', F, H),
        '~sharedPrograms.TermToIntDL.P9'(A, C, D, E, _, _, _, H, I),
        '~sharedPrograms.ChainExprToIntDL.P6'(B, C, D, E, I, G).
'sharedPrograms.AddOtherModulesAux.P7'([], A, B, C, A, B, C).
'~sharedPrograms.AddOtherModulesAux.P7'([], A, B, C, A, B, C).
'sharedPrograms.AddOtherModulesAux.P7'([A|B], C, D, E, F, G, H) :-
        'sharedPrograms.AddModule.P7'(A, C, D, E, I, J, K),
        'sharedPrograms.AddOtherModulesAux.P7'(B, I, J, K, F, G, H).
'~sharedPrograms.AddOtherModulesAux.P7'([A|B], C, D, E, F, G, H) :-
        '~sharedPrograms.AddModule.P7'(A, C, D, E, I, J, K),
        '~sharedPrograms.AddOtherModulesAux.P7'(B, I, J, K, F, G, H).
'sharedPrograms.AddModule.P7'(A, B, C, D, E, F, G) :-
        user:goedel_freeze(ground([A]), ('SharedPrograms':'~sharedPrograms.SystemModule.P1'(A),true->'SharedPrograms':'sharedPrograms.SystemModuleRep.P4'(A,H,I,J),'AVLTrees':'AVLTrees.AVLInsert.P4'(B,A,H,K),'AVLTrees':'AVLTrees.AVLInsert.P4'(C,A,I,L),'AVLTrees':'AVLTrees.AVLInsert.P4'(D,A,'ProgDefs.Code.F2'(0,J),M),'SharedPrograms':'sharedPrograms.AddOtherModules.P7'(H,K,L,M,E,F,G);'AVLTrees':'AVLTrees.AVLInsert.P4'(B,A,'ProgDefs.ModDef.F4'('ProgDefs.NormalKind.C0',[],[],[]),E),F=C,'AVLTrees':'AVLTrees.AVLIsEmpty.P1'(N),'SharedPrograms':'sharedPrograms.NextModuleVersion.P2'(A,O),'AVLTrees':'AVLTrees.AVLInsert.P4'(D,A,'ProgDefs.Code.F2'(O,N),G))).
'~sharedPrograms.AddModule.P7'(A, B, C, D, E, F, G) :-
        user:goedel_freeze(ground([A]), ('SharedPrograms':'~sharedPrograms.SystemModule.P1'(A),true->'SharedPrograms':'~sharedPrograms.SystemModuleRep.P4'(A,H,I,J),'AVLTrees':'~AVLTrees.AVLInsert.P4'(B,A,H,K),'AVLTrees':'~AVLTrees.AVLInsert.P4'(C,A,I,L),'AVLTrees':'~AVLTrees.AVLInsert.P4'(D,A,'ProgDefs.Code.F2'(0,J),M),'SharedPrograms':'~sharedPrograms.AddOtherModules.P7'(H,K,L,M,E,F,G);'AVLTrees':'~AVLTrees.AVLInsert.P4'(B,A,'ProgDefs.ModDef.F4'('ProgDefs.NormalKind.C0',[],[],[]),E),F=C,'AVLTrees':'~AVLTrees.AVLIsEmpty.P1'(N),'SharedPrograms':'~sharedPrograms.NextModuleVersion.P2'(A,O),'AVLTrees':'~AVLTrees.AVLInsert.P4'(D,A,'ProgDefs.Code.F2'(O,N),G))).
'sharedPrograms.AddImportToPart.P6'('ProgDefs.Export.C0', A, B, C, [A|B], C).
'~sharedPrograms.AddImportToPart.P6'('ProgDefs.Export.C0', A, B, C, [A|B], C).
'sharedPrograms.AddImportToPart.P6'('ProgDefs.Closed.C0', A, B, C, [A|B], C).
'~sharedPrograms.AddImportToPart.P6'('ProgDefs.Closed.C0', A, B, C, [A|B], C).
'sharedPrograms.AddImportToPart.P6'('ProgDefs.Local.C0', A, B, C, B, [A|C]).
'~sharedPrograms.AddImportToPart.P6'('ProgDefs.Local.C0', A, B, C, B, [A|C]).
'sharedPrograms.AddImportToPart.P6'('ProgDefs.Module.C0', A, B, C, B, [A|C]).
'~sharedPrograms.AddImportToPart.P6'('ProgDefs.Module.C0', A, B, C, B, [A|C]).
'sharedPrograms.Accessible.P2'('ProgDefs.Exported.C0', 'ProgDefs.Exported.C0').
'~sharedPrograms.Accessible.P2'('ProgDefs.Exported.C0', 'ProgDefs.Exported.C0').
'sharedPrograms.Accessible.P2'('ProgDefs.Hidden.C0', _).
'~sharedPrograms.Accessible.P2'('ProgDefs.Hidden.C0', _).
'sharedPrograms.AddLiftedLanguage.P4'([], _, A, A).
'~sharedPrograms.AddLiftedLanguage.P4'([], _, A, A).
'sharedPrograms.AddLiftedLanguage.P4'(['ProgDefs.Lift.F2'(B,C)|A], D, E, F) :-
        user:goedel_freeze(ground([D,B]), ('Lists':'~Lists.Member.P2'(B,D),true->G=E;'AVLTrees':'AVLTrees.AVLIsEmpty.P1'(H),user:goedel_freeze(ground([H,B,E]),if(('AVLTrees':'~AVLTrees.AVLUpdate.P5'(E,B,'ProgDefs.Module.F3'('ProgDefs.Exported.C0','ProgDefs.Categories.F2'(I,H),[]),J,'ProgDefs.Module.F3'(_,'ProgDefs.Categories.F2'(K,_),_)),true),('AVLTrees':'AVLTrees.AVLJoin.P3'(C,K,I),G=J),'AVLTrees':'AVLTrees.AVLInsert.P4'(E,B,'ProgDefs.Module.F3'('ProgDefs.Exported.C0','ProgDefs.Categories.F2'(C,H),[]),G))))),
        'sharedPrograms.AddLiftedLanguage.P4'(A, D, G, F).
'~sharedPrograms.AddLiftedLanguage.P4'(['ProgDefs.Lift.F2'(B,C)|A], D, E, F) :-
        user:goedel_freeze(ground([D,B]), ('Lists':'~Lists.Member.P2'(B,D),true->G=E;'AVLTrees':'~AVLTrees.AVLIsEmpty.P1'(H),user:goedel_freeze(ground([H,B,E]),if(('AVLTrees':'~AVLTrees.AVLUpdate.P5'(E,B,'ProgDefs.Module.F3'('ProgDefs.Exported.C0','ProgDefs.Categories.F2'(I,H),[]),J,'ProgDefs.Module.F3'(_,'ProgDefs.Categories.F2'(K,_),_)),true),('AVLTrees':'~AVLTrees.AVLJoin.P3'(C,K,I),G=J),'AVLTrees':'~AVLTrees.AVLInsert.P4'(E,B,'ProgDefs.Module.F3'('ProgDefs.Exported.C0','ProgDefs.Categories.F2'(C,H),[]),G))))),
        '~sharedPrograms.AddLiftedLanguage.P4'(A, D, G, F).
'sharedPrograms.AddOtherModules.P7'('ProgDefs.ModDef.F4'(_,A,B,C), D, E, F, G, H, I) :-
        'Lists':'Lists.Append.P3'(C, A, J),
        'Lists':'Lists.Append.P3'(B, J, K),
        'sharedPrograms.AddOtherModulesAux.P7'(K, D, E, F, G, H, I).
'~sharedPrograms.AddOtherModules.P7'('ProgDefs.ModDef.F4'(_,A,B,C), D, E, F, G, H, I) :-
        'Lists':'~Lists.Append.P3'(C, A, J),
        'Lists':'~Lists.Append.P3'(B, J, K),
        '~sharedPrograms.AddOtherModulesAux.P7'(K, D, E, F, G, H, I).
'sharedPrograms.BinaryConnective.P3'('MetaDefs.&''.F2'(A,B), A, B).
'~sharedPrograms.BinaryConnective.P3'('MetaDefs.&''.F2'(A,B), A, B).
'sharedPrograms.BinaryConnective.P3'('MetaDefs.\\/''.F2'(A,B), A, B). % added \ djd
'~sharedPrograms.BinaryConnective.P3'('MetaDefs.\\/''.F2'(A,B), A, B). % added \ djd
'sharedPrograms.BinaryConnective.P3'('MetaDefs.->''.F2'(A,B), A, B).
'~sharedPrograms.BinaryConnective.P3'('MetaDefs.->''.F2'(A,B), A, B).
'sharedPrograms.BinaryConnective.P3'('MetaDefs.<-''.F2'(A,B), A, B).
'~sharedPrograms.BinaryConnective.P3'('MetaDefs.<-''.F2'(A,B), A, B).
'sharedPrograms.BinaryConnective.P3'('MetaDefs.<->''.F2'(A,B), A, B).
'~sharedPrograms.BinaryConnective.P3'('MetaDefs.<->''.F2'(A,B), A, B).
'sharedPrograms.BaseInLanguage.P2'(A, B) :-
        'sharedPrograms.TypeSymbolInLanguage.P3'(A, B, 'ProgDefs.BaseDecl.C0').
'~sharedPrograms.BaseInLanguage.P2'(A, B) :-
        '~sharedPrograms.TypeSymbolInLanguage.P3'(A, B, 'ProgDefs.BaseDecl.C0').
'sharedPrograms.AtomToIntDL.P8'('Syntax.NoPredInd.C0', 'MetaDefs.Name.F4'(A,B,C,D), E, F, G, H, I, J) :-
        user:goedel_freeze(ground([D,C,A,B]), ((A='"Integers',B='"Interval',C='MetaDefs.Predicate.C0',D=3),true->E=[K,L,M],'SharedPrograms':'sharedPrograms.ClassifyToken.P2'('"=<',N),'Strings':'Strings.StringInts.P2'('"=<',O),'SharedPrograms':'sharedPrograms.TermToIntDL.P9'(K,F,G,H,_,_,P,I,Q),'SharedPrograms':'sharedPrograms.SpaceIfNeeded.P4'(P,N,Q,R),'Lists':'Lists.Append.P3'(O,S,R),'SharedPrograms':'sharedPrograms.TermToIntDL.P9'(L,F,G,H,_,T,U,V,W),'SharedPrograms':'sharedPrograms.SpaceIfNeeded.P4'(N,T,S,V),'SharedPrograms':'sharedPrograms.SpaceIfNeeded.P4'(U,N,W,X),'Lists':'Lists.Append.P3'(O,Y,X),'SharedPrograms':'sharedPrograms.TermToIntDL.P9'(M,F,G,H,_,Z,_,A1,J),'SharedPrograms':'sharedPrograms.SpaceIfNeeded.P4'(N,Z,Y,A1);'Strings':'Strings.StringInts.P2'(B,B1),'Lists':'Lists.Append.P3'(B1,Q,I),'SharedPrograms':'sharedPrograms.CharDL.P3'('"(',Q,R),'SharedPrograms':'sharedPrograms.TermListToIntDL.P6'(E,F,G,H,R,S),'SharedPrograms':'sharedPrograms.CharDL.P3'('")',S,J))).
'~sharedPrograms.AtomToIntDL.P8'('Syntax.NoPredInd.C0', 'MetaDefs.Name.F4'(A,B,C,D), E, F, G, H, I, J) :-
        user:goedel_freeze(ground([D,C,A,B]), ((A='"Integers',B='"Interval',C='MetaDefs.Predicate.C0',D=3),true->E=[K,L,M],'SharedPrograms':'~sharedPrograms.ClassifyToken.P2'('"=<',N),'Strings':'~Strings.StringInts.P2'('"=<',O),'SharedPrograms':'~sharedPrograms.TermToIntDL.P9'(K,F,G,H,_,_,P,I,Q),'SharedPrograms':'~sharedPrograms.SpaceIfNeeded.P4'(P,N,Q,R),'Lists':'~Lists.Append.P3'(O,S,R),'SharedPrograms':'~sharedPrograms.TermToIntDL.P9'(L,F,G,H,_,T,U,V,W),'SharedPrograms':'~sharedPrograms.SpaceIfNeeded.P4'(N,T,S,V),'SharedPrograms':'~sharedPrograms.SpaceIfNeeded.P4'(U,N,W,X),'Lists':'~Lists.Append.P3'(O,Y,X),'SharedPrograms':'~sharedPrograms.TermToIntDL.P9'(M,F,G,H,_,Z,_,A1,J),'SharedPrograms':'~sharedPrograms.SpaceIfNeeded.P4'(N,Z,Y,A1);'Strings':'~Strings.StringInts.P2'(B,B1),'Lists':'~Lists.Append.P3'(B1,Q,I),'SharedPrograms':'~sharedPrograms.CharDL.P3'('"(',Q,R),'SharedPrograms':'~sharedPrograms.TermListToIntDL.P6'(E,F,G,H,R,S),'SharedPrograms':'~sharedPrograms.CharDL.P3'('")',S,J))).
'sharedPrograms.AtomToIntDL.P8'('Syntax.ZPZ.C0', 'MetaDefs.Name.F4'(_,A,_,_), [B,C], D, E, F, G, H) :-
        'sharedPrograms.TermToIntDL.P9'(B, D, E, F, _, _, I, G, J),
        'sharedPrograms.ClassifyToken.P2'(A, K),
        'sharedPrograms.SpaceIfNeeded.P4'(I, K, J, L),
        'Strings':'Strings.StringInts.P2'(A, M),
        'Lists':'Lists.Append.P3'(M, N, L),
        'sharedPrograms.TermToIntDL.P9'(C, D, E, F, _, O, _, P, H),
        'sharedPrograms.SpaceIfNeeded.P4'(O, K, N, P).
'~sharedPrograms.AtomToIntDL.P8'('Syntax.ZPZ.C0', 'MetaDefs.Name.F4'(_,A,_,_), [B,C], D, E, F, G, H) :-
        '~sharedPrograms.TermToIntDL.P9'(B, D, E, F, _, _, I, G, J),
        '~sharedPrograms.ClassifyToken.P2'(A, K),
        '~sharedPrograms.SpaceIfNeeded.P4'(I, K, J, L),
        'Strings':'~Strings.StringInts.P2'(A, M),
        'Lists':'~Lists.Append.P3'(M, N, L),
        '~sharedPrograms.TermToIntDL.P9'(C, D, E, F, _, O, _, P, H),
        '~sharedPrograms.SpaceIfNeeded.P4'(O, K, N, P).
'sharedPrograms.AtomToIntDL.P8'('Syntax.ZP.C0', 'MetaDefs.Name.F4'(_,A,_,_), [B], C, D, E, F, G) :-
        'sharedPrograms.TermToIntDL.P9'(B, C, D, E, _, _, H, F, I),
        'sharedPrograms.ClassifyToken.P2'(A, J),
        'sharedPrograms.SpaceIfNeeded.P4'(H, J, I, K),
        'Strings':'Strings.StringInts.P2'(A, L),
        'Lists':'Lists.Append.P3'(L, G, K).
'~sharedPrograms.AtomToIntDL.P8'('Syntax.ZP.C0', 'MetaDefs.Name.F4'(_,A,_,_), [B], C, D, E, F, G) :-
        '~sharedPrograms.TermToIntDL.P9'(B, C, D, E, _, _, H, F, I),
        '~sharedPrograms.ClassifyToken.P2'(A, J),
        '~sharedPrograms.SpaceIfNeeded.P4'(H, J, I, K),
        'Strings':'~Strings.StringInts.P2'(A, L),
        'Lists':'~Lists.Append.P3'(L, G, K).
'sharedPrograms.AtomToIntDL.P8'('Syntax.PZ.C0', 'MetaDefs.Name.F4'(_,A,_,_), [B], C, D, E, F, G) :-
        'sharedPrograms.ClassifyToken.P2'(A, H),
        'Strings':'Strings.StringInts.P2'(A, I),
        'Lists':'Lists.Append.P3'(I, J, F),
        'sharedPrograms.TermToIntDL.P9'(B, C, D, E, _, K, _, L, G),
        'sharedPrograms.SpaceIfNeeded.P4'(K, H, J, L).
'~sharedPrograms.AtomToIntDL.P8'('Syntax.PZ.C0', 'MetaDefs.Name.F4'(_,A,_,_), [B], C, D, E, F, G) :-
        '~sharedPrograms.ClassifyToken.P2'(A, H),
        'Strings':'~Strings.StringInts.P2'(A, I),
        'Lists':'~Lists.Append.P3'(I, J, F),
        '~sharedPrograms.TermToIntDL.P9'(B, C, D, E, _, K, _, L, G),
        '~sharedPrograms.SpaceIfNeeded.P4'(K, H, J, L).
'sharedPrograms.AndSeqToIntDL.P3'('ProgDefs.And.F2'(A,B), C, D) :-
        'sharedPrograms.SimpleCondToIntDL.P3'(A, C, E),
        'Strings':'Strings.StringInts.P2'('" & ', F),
        'Lists':'Lists.Append.P3'(F, G, E),
        user:goedel_freeze(ground([B]), (B='ProgDefs.And.F2'(_,_),true->'SharedPrograms':'sharedPrograms.AndSeqToIntDL.P3'(B,G,D);'SharedPrograms':'sharedPrograms.SimpleCondToIntDL.P3'(B,G,D))).
'~sharedPrograms.AndSeqToIntDL.P3'('ProgDefs.And.F2'(A,B), C, D) :-
        '~sharedPrograms.SimpleCondToIntDL.P3'(A, C, E),
        'Strings':'~Strings.StringInts.P2'('" & ', F),
        'Lists':'~Lists.Append.P3'(F, G, E),
        user:goedel_freeze(ground([B]), (B='ProgDefs.And.F2'(_,_),true->'SharedPrograms':'~sharedPrograms.AndSeqToIntDL.P3'(B,G,D);'SharedPrograms':'~sharedPrograms.SimpleCondToIntDL.P3'(B,G,D))).
'sharedPrograms.BinConnectiveChars.P3'('MetaDefs.&''.F2'(_,_), A, B) :-
        'Strings':'Strings.StringInts.P2'('" & ', C),
        'Lists':'Lists.Append.P3'(C, B, A).
'~sharedPrograms.BinConnectiveChars.P3'('MetaDefs.&''.F2'(_,_), A, B) :-
        'Strings':'~Strings.StringInts.P2'('" & ', C),
        'Lists':'~Lists.Append.P3'(C, B, A).
'sharedPrograms.BinConnectiveChars.P3'('MetaDefs.\\/''.F2'(_,_), A, B) :- % added \ djd
        'Strings':'Strings.StringInts.P2'('" \\/ ', C), % added \ djd
        'Lists':'Lists.Append.P3'(C, B, A).
'~sharedPrograms.BinConnectiveChars.P3'('MetaDefs.\\/''.F2'(_,_), A, B) :- % added \ djd
        'Strings':'~Strings.StringInts.P2'('" \\/ ', C), % added \ djd
        'Lists':'~Lists.Append.P3'(C, B, A).
'sharedPrograms.BinConnectiveChars.P3'('MetaDefs.->''.F2'(_,_), A, B) :-
        'Strings':'Strings.StringInts.P2'('" -> ', C),
        'Lists':'Lists.Append.P3'(C, B, A).
'~sharedPrograms.BinConnectiveChars.P3'('MetaDefs.->''.F2'(_,_), A, B) :-
        'Strings':'~Strings.StringInts.P2'('" -> ', C),
        'Lists':'~Lists.Append.P3'(C, B, A).
'sharedPrograms.BinConnectiveChars.P3'('MetaDefs.<-''.F2'(_,_), A, B) :-
        'Strings':'Strings.StringInts.P2'('" <- ', C),
        'Lists':'Lists.Append.P3'(C, B, A).
'~sharedPrograms.BinConnectiveChars.P3'('MetaDefs.<-''.F2'(_,_), A, B) :-
        'Strings':'~Strings.StringInts.P2'('" <- ', C),
        'Lists':'~Lists.Append.P3'(C, B, A).
'sharedPrograms.BinConnectiveChars.P3'('MetaDefs.<->''.F2'(_,_), A, B) :-
        'Strings':'Strings.StringInts.P2'('" <-> ', C),
        'Lists':'Lists.Append.P3'(C, B, A).
'~sharedPrograms.BinConnectiveChars.P3'('MetaDefs.<->''.F2'(_,_), A, B) :-
        'Strings':'~Strings.StringInts.P2'('" <-> ', C),
        'Lists':'~Lists.Append.P3'(C, B, A).
'sharedPrograms.BinaryInfixToIntDL.P12'(A, 'MetaDefs.Name.F4'(B,C,_,_), D, E, F, G, H, I, J, K, L, M) :-
        user:goedel_freeze(ground([D,B,E,C]), if(((B='"Rationals',C='"//',D='MetaDefs.Int.F1'(N),E='MetaDefs.Int.F1'(O)),true),'SharedPrograms':'sharedPrograms.RationalToIntDL.P9'(N,O,F,G,I,J,K,L,M),(I=A,'SharedPrograms':'sharedPrograms.TermToIntDL.P9'(D,F,G,H,P,Q,R,S,T),'SharedPrograms':'sharedPrograms.TermToIntDL.P9'(E,F,G,H,U,V,W,X,Y),'SharedPrograms':'sharedPrograms.ClassifyToken.P2'(C,Z),user:goedel_freeze(ground([A,P]),(('SharedPrograms':'~sharedPrograms.RPrec.P2'(P,A1),'SharedPrograms':'~sharedPrograms.LPrec.P2'(A,B1),'SharedPrograms':'~sharedPrograms.BindsTighter.P2'(A1,B1)),true->J=Q,L=S,'SharedPrograms':'sharedPrograms.SpaceIfNeeded.P4'(R,Z,T,C1);J='sharedPrograms.Bounded.C0','SharedPrograms':'sharedPrograms.CharDL.P3'('"(',L,S),'SharedPrograms':'sharedPrograms.CharDL.P3'('")',T,C1))),'Strings':'Strings.StringInts.P2'(C,D1),'Lists':'Lists.Append.P3'(D1,E1,C1),user:goedel_freeze(ground([A,U]),(('SharedPrograms':'~sharedPrograms.LPrec.P2'(U,F1),'SharedPrograms':'~sharedPrograms.RPrec.P2'(A,G1),'SharedPrograms':'~sharedPrograms.BindsTighter.P2'(F1,G1)),true->K=W,'SharedPrograms':'sharedPrograms.SpaceIfNeeded.P4'(Z,V,E1,X),M=Y;K='sharedPrograms.Bounded.C0','SharedPrograms':'sharedPrograms.CharDL.P3'('"(',E1,X),'SharedPrograms':'sharedPrograms.CharDL.P3'('")',Y,M)))))).
'~sharedPrograms.BinaryInfixToIntDL.P12'(A, 'MetaDefs.Name.F4'(B,C,_,_), D, E, F, G, H, I, J, K, L, M) :-
        user:goedel_freeze(ground([D,B,E,C]), if(((B='"Rationals',C='"//',D='MetaDefs.Int.F1'(N),E='MetaDefs.Int.F1'(O)),true),'SharedPrograms':'~sharedPrograms.RationalToIntDL.P9'(N,O,F,G,I,J,K,L,M),(I=A,'SharedPrograms':'~sharedPrograms.TermToIntDL.P9'(D,F,G,H,P,Q,R,S,T),'SharedPrograms':'~sharedPrograms.TermToIntDL.P9'(E,F,G,H,U,V,W,X,Y),'SharedPrograms':'~sharedPrograms.ClassifyToken.P2'(C,Z),user:goedel_freeze(ground([A,P]),(('SharedPrograms':'~sharedPrograms.RPrec.P2'(P,A1),'SharedPrograms':'~sharedPrograms.LPrec.P2'(A,B1),'SharedPrograms':'~sharedPrograms.BindsTighter.P2'(A1,B1)),true->J=Q,L=S,'SharedPrograms':'~sharedPrograms.SpaceIfNeeded.P4'(R,Z,T,C1);J='sharedPrograms.Bounded.C0','SharedPrograms':'~sharedPrograms.CharDL.P3'('"(',L,S),'SharedPrograms':'~sharedPrograms.CharDL.P3'('")',T,C1))),'Strings':'~Strings.StringInts.P2'(C,D1),'Lists':'~Lists.Append.P3'(D1,E1,C1),user:goedel_freeze(ground([A,U]),(('SharedPrograms':'~sharedPrograms.LPrec.P2'(U,F1),'SharedPrograms':'~sharedPrograms.RPrec.P2'(A,G1),'SharedPrograms':'~sharedPrograms.BindsTighter.P2'(F1,G1)),true->K=W,'SharedPrograms':'~sharedPrograms.SpaceIfNeeded.P4'(Z,V,E1,X),M=Y;K='sharedPrograms.Bounded.C0','SharedPrograms':'~sharedPrograms.CharDL.P3'('"(',E1,X),'SharedPrograms':'~sharedPrograms.CharDL.P3'('")',Y,M)))))).
'sharedPrograms.BinaryFormulaToIntDL.P6'(A, B, C, D, E, F) :-
        'sharedPrograms.BinaryConnective.P3'(A, G, H),
        'sharedPrograms.FormulaToIntDL.P6'(G, B, C, D, I, J),
        'sharedPrograms.FormulaToIntDL.P6'(H, B, C, D, K, L),
        user:goedel_freeze(ground([A,G]), (('SharedPrograms':'~sharedPrograms.CRPrec.P2'(G,M),'SharedPrograms':'~sharedPrograms.CLPrec.P2'(A,N),'SharedPrograms':'~sharedPrograms.BindsTighter.P2'(M,N)),true->E=I,O=J;'SharedPrograms':'sharedPrograms.CharDL.P3'('"(',E,I),'SharedPrograms':'sharedPrograms.CharDL.P3'('")',J,O))),
        'sharedPrograms.BinConnectiveChars.P3'(A, O, P),
        user:goedel_freeze(ground([A,H]), (('SharedPrograms':'~sharedPrograms.CLPrec.P2'(H,Q),'SharedPrograms':'~sharedPrograms.CRPrec.P2'(A,R),'SharedPrograms':'~sharedPrograms.BindsTighter.P2'(Q,R)),true->P=K,F=L;'SharedPrograms':'sharedPrograms.CharDL.P3'('"(',P,K),'SharedPrograms':'sharedPrograms.CharDL.P3'('")',L,F))).
'~sharedPrograms.BinaryFormulaToIntDL.P6'(A, B, C, D, E, F) :-
        '~sharedPrograms.BinaryConnective.P3'(A, G, H),
        '~sharedPrograms.FormulaToIntDL.P6'(G, B, C, D, I, J),
        '~sharedPrograms.FormulaToIntDL.P6'(H, B, C, D, K, L),
        user:goedel_freeze(ground([A,G]), (('SharedPrograms':'~sharedPrograms.CRPrec.P2'(G,M),'SharedPrograms':'~sharedPrograms.CLPrec.P2'(A,N),'SharedPrograms':'~sharedPrograms.BindsTighter.P2'(M,N)),true->E=I,O=J;'SharedPrograms':'~sharedPrograms.CharDL.P3'('"(',E,I),'SharedPrograms':'~sharedPrograms.CharDL.P3'('")',J,O))),
        '~sharedPrograms.BinConnectiveChars.P3'(A, O, P),
        user:goedel_freeze(ground([A,H]), (('SharedPrograms':'~sharedPrograms.CLPrec.P2'(H,Q),'SharedPrograms':'~sharedPrograms.CRPrec.P2'(A,R),'SharedPrograms':'~sharedPrograms.BindsTighter.P2'(Q,R)),true->P=K,F=L;'SharedPrograms':'~sharedPrograms.CharDL.P3'('"(',P,K),'SharedPrograms':'~sharedPrograms.CharDL.P3'('")',L,F))).
'sharedPrograms.CLPrec.P2'('MetaDefs.Empty.C0', 'sharedPrograms.Infinity.C0').
'~sharedPrograms.CLPrec.P2'('MetaDefs.Empty.C0', 'sharedPrograms.Infinity.C0').
'sharedPrograms.CLPrec.P2'('MetaDefs.PAtom.F1'(_), 'sharedPrograms.Infinity.C0').
'~sharedPrograms.CLPrec.P2'('MetaDefs.PAtom.F1'(_), 'sharedPrograms.Infinity.C0').
'sharedPrograms.CLPrec.P2'('MetaDefs.Atom.F2'(_,_), 'sharedPrograms.Infinity.C0').
'~sharedPrograms.CLPrec.P2'('MetaDefs.Atom.F2'(_,_), 'sharedPrograms.Infinity.C0').
'sharedPrograms.CLPrec.P2'('MetaDefs.~''.F1'(_), 'sharedPrograms.Prec.F2'(120,'sharedPrograms.X.C0')).
'~sharedPrograms.CLPrec.P2'('MetaDefs.~''.F1'(_), 'sharedPrograms.Prec.F2'(120,'sharedPrograms.X.C0')).
'sharedPrograms.CLPrec.P2'('MetaDefs.&''.F2'(_,_), 'sharedPrograms.Prec.F2'(100,'sharedPrograms.X.C0')).
'~sharedPrograms.CLPrec.P2'('MetaDefs.&''.F2'(_,_), 'sharedPrograms.Prec.F2'(100,'sharedPrograms.X.C0')).
'sharedPrograms.CLPrec.P2'('MetaDefs.\\/''.F2'(_,_), 'sharedPrograms.Prec.F2'(90,'sharedPrograms.X.C0')). % added \ djd
'~sharedPrograms.CLPrec.P2'('MetaDefs.\\/''.F2'(_,_), 'sharedPrograms.Prec.F2'(90,'sharedPrograms.X.C0')).  % added \ djd
'sharedPrograms.CLPrec.P2'('MetaDefs.->''.F2'(_,_), 'sharedPrograms.Prec.F2'(80,'sharedPrograms.X.C0')).
'~sharedPrograms.CLPrec.P2'('MetaDefs.->''.F2'(_,_), 'sharedPrograms.Prec.F2'(80,'sharedPrograms.X.C0')).
'sharedPrograms.CLPrec.P2'('MetaDefs.<-''.F2'(_,_), 'sharedPrograms.Prec.F2'(80,'sharedPrograms.X.C0')).
'~sharedPrograms.CLPrec.P2'('MetaDefs.<-''.F2'(_,_), 'sharedPrograms.Prec.F2'(80,'sharedPrograms.X.C0')).
'sharedPrograms.CLPrec.P2'('MetaDefs.<->''.F2'(_,_), 'sharedPrograms.Prec.F2'(80,'sharedPrograms.X.C0')).
'~sharedPrograms.CLPrec.P2'('MetaDefs.<->''.F2'(_,_), 'sharedPrograms.Prec.F2'(80,'sharedPrograms.X.C0')).
'sharedPrograms.CLPrec.P2'('MetaDefs.Some.F2'(_,_), 'sharedPrograms.Prec.F2'(120,'sharedPrograms.X.C0')).
'~sharedPrograms.CLPrec.P2'('MetaDefs.Some.F2'(_,_), 'sharedPrograms.Prec.F2'(120,'sharedPrograms.X.C0')).
'sharedPrograms.CLPrec.P2'('MetaDefs.All.F2'(_,_), 'sharedPrograms.Prec.F2'(120,'sharedPrograms.X.C0')).
'~sharedPrograms.CLPrec.P2'('MetaDefs.All.F2'(_,_), 'sharedPrograms.Prec.F2'(120,'sharedPrograms.X.C0')).
'sharedPrograms.CLPrec.P2'('MetaDefs.Commit.F2'(_,_), 'sharedPrograms.Infinity.C0').
'~sharedPrograms.CLPrec.P2'('MetaDefs.Commit.F2'(_,_), 'sharedPrograms.Infinity.C0').
'sharedPrograms.CLPrec.P2'('MetaDefs.ISTE.F4'(_,_,_,_), 'sharedPrograms.Infinity.C0').
'~sharedPrograms.CLPrec.P2'('MetaDefs.ISTE.F4'(_,_,_,_), 'sharedPrograms.Infinity.C0').
'sharedPrograms.CLPrec.P2'('MetaDefs.IST.F3'(_,_,_), 'sharedPrograms.Infinity.C0').
'~sharedPrograms.CLPrec.P2'('MetaDefs.IST.F3'(_,_,_), 'sharedPrograms.Infinity.C0').
'sharedPrograms.CLPrec.P2'('MetaDefs.ITE.F3'(_,_,_), 'sharedPrograms.Infinity.C0').
'~sharedPrograms.CLPrec.P2'('MetaDefs.ITE.F3'(_,_,_), 'sharedPrograms.Infinity.C0').
'sharedPrograms.CLPrec.P2'('MetaDefs.IT.F2'(_,_), 'sharedPrograms.Infinity.C0').
'~sharedPrograms.CLPrec.P2'('MetaDefs.IT.F2'(_,_), 'sharedPrograms.Infinity.C0').
'sharedPrograms.BindsTighter.P2'('sharedPrograms.Infinity.C0', _).
'~sharedPrograms.BindsTighter.P2'('sharedPrograms.Infinity.C0', _).
'sharedPrograms.BindsTighter.P2'('sharedPrograms.Prec.F2'(A,B), 'sharedPrograms.Prec.F2'(C,D)) :-
        call_residue(A=C, E),
        (   E=[] ->
            !
        ;   user:release_suspended(E)
        ),
        B='sharedPrograms.X.C0',
        D='sharedPrograms.Y.C0'.
'~sharedPrograms.BindsTighter.P2'('sharedPrograms.Prec.F2'(A,B), 'sharedPrograms.Prec.F2'(C,D)) :-
        A=C,
        B='sharedPrograms.X.C0',
        D='sharedPrograms.Y.C0'.
'sharedPrograms.BindsTighter.P2'('sharedPrograms.Prec.F2'(A,_), 'sharedPrograms.Prec.F2'(B,_)) :-
        call_residue('Integers':'Integers.>.P2'(A,B), C),
        (   C=[] ->
            !
        ;   user:release_suspended(C)
        ).
'~sharedPrograms.BindsTighter.P2'('sharedPrograms.Prec.F2'(A,_), 'sharedPrograms.Prec.F2'(B,_)) :-
        'Integers':'~Integers.>.P2'(A, B).
'sharedPrograms.CRPrec.P2'('MetaDefs.Empty.C0', 'sharedPrograms.Infinity.C0').
'~sharedPrograms.CRPrec.P2'('MetaDefs.Empty.C0', 'sharedPrograms.Infinity.C0').
'sharedPrograms.CRPrec.P2'('MetaDefs.PAtom.F1'(_), 'sharedPrograms.Infinity.C0').
'~sharedPrograms.CRPrec.P2'('MetaDefs.PAtom.F1'(_), 'sharedPrograms.Infinity.C0').
'sharedPrograms.CRPrec.P2'('MetaDefs.Atom.F2'(_,_), 'sharedPrograms.Infinity.C0').
'~sharedPrograms.CRPrec.P2'('MetaDefs.Atom.F2'(_,_), 'sharedPrograms.Infinity.C0').
'sharedPrograms.CRPrec.P2'('MetaDefs.~''.F1'(_), 'sharedPrograms.Prec.F2'(120,'sharedPrograms.Y.C0')).
'~sharedPrograms.CRPrec.P2'('MetaDefs.~''.F1'(_), 'sharedPrograms.Prec.F2'(120,'sharedPrograms.Y.C0')).
'sharedPrograms.CRPrec.P2'('MetaDefs.&''.F2'(_,_), 'sharedPrograms.Prec.F2'(100,'sharedPrograms.Y.C0')).
'~sharedPrograms.CRPrec.P2'('MetaDefs.&''.F2'(_,_), 'sharedPrograms.Prec.F2'(100,'sharedPrograms.Y.C0')).
'sharedPrograms.CRPrec.P2'('MetaDefs.\\/''.F2'(_,_), 'sharedPrograms.Prec.F2'(90,'sharedPrograms.Y.C0')).  % added \ djd
'~sharedPrograms.CRPrec.P2'('MetaDefs.\\/''.F2'(_,_), 'sharedPrograms.Prec.F2'(90,'sharedPrograms.Y.C0')).  % added \ djd
'sharedPrograms.CRPrec.P2'('MetaDefs.->''.F2'(_,_), 'sharedPrograms.Prec.F2'(80,'sharedPrograms.Y.C0')).
'~sharedPrograms.CRPrec.P2'('MetaDefs.->''.F2'(_,_), 'sharedPrograms.Prec.F2'(80,'sharedPrograms.Y.C0')).
'sharedPrograms.CRPrec.P2'('MetaDefs.<-''.F2'(_,_), 'sharedPrograms.Prec.F2'(80,'sharedPrograms.Y.C0')).
'~sharedPrograms.CRPrec.P2'('MetaDefs.<-''.F2'(_,_), 'sharedPrograms.Prec.F2'(80,'sharedPrograms.Y.C0')).
'sharedPrograms.CRPrec.P2'('MetaDefs.<->''.F2'(_,_), 'sharedPrograms.Prec.F2'(80,'sharedPrograms.X.C0')).
'~sharedPrograms.CRPrec.P2'('MetaDefs.<->''.F2'(_,_), 'sharedPrograms.Prec.F2'(80,'sharedPrograms.X.C0')).
'sharedPrograms.CRPrec.P2'('MetaDefs.Some.F2'(_,_), 'sharedPrograms.Prec.F2'(120,'sharedPrograms.Y.C0')).
'~sharedPrograms.CRPrec.P2'('MetaDefs.Some.F2'(_,_), 'sharedPrograms.Prec.F2'(120,'sharedPrograms.Y.C0')).
'sharedPrograms.CRPrec.P2'('MetaDefs.All.F2'(_,_), 'sharedPrograms.Prec.F2'(120,'sharedPrograms.Y.C0')).
'~sharedPrograms.CRPrec.P2'('MetaDefs.All.F2'(_,_), 'sharedPrograms.Prec.F2'(120,'sharedPrograms.Y.C0')).
'sharedPrograms.CRPrec.P2'('MetaDefs.Commit.F2'(_,_), 'sharedPrograms.Infinity.C0').
'~sharedPrograms.CRPrec.P2'('MetaDefs.Commit.F2'(_,_), 'sharedPrograms.Infinity.C0').
'sharedPrograms.CRPrec.P2'('MetaDefs.ISTE.F4'(_,_,_,_), 'sharedPrograms.Prec.F2'(70,'sharedPrograms.Y.C0')).
'~sharedPrograms.CRPrec.P2'('MetaDefs.ISTE.F4'(_,_,_,_), 'sharedPrograms.Prec.F2'(70,'sharedPrograms.Y.C0')).
'sharedPrograms.CRPrec.P2'('MetaDefs.IST.F3'(_,_,_), 'sharedPrograms.Prec.F2'(70,'sharedPrograms.Y.C0')).
'~sharedPrograms.CRPrec.P2'('MetaDefs.IST.F3'(_,_,_), 'sharedPrograms.Prec.F2'(70,'sharedPrograms.Y.C0')).
'sharedPrograms.CRPrec.P2'('MetaDefs.ITE.F3'(_,_,_), 'sharedPrograms.Prec.F2'(70,'sharedPrograms.Y.C0')).
'~sharedPrograms.CRPrec.P2'('MetaDefs.ITE.F3'(_,_,_), 'sharedPrograms.Prec.F2'(70,'sharedPrograms.Y.C0')).
'sharedPrograms.CRPrec.P2'('MetaDefs.IT.F2'(_,_), 'sharedPrograms.Prec.F2'(70,'sharedPrograms.Y.C0')).
'~sharedPrograms.CRPrec.P2'('MetaDefs.IT.F2'(_,_), 'sharedPrograms.Prec.F2'(70,'sharedPrograms.Y.C0')).
'sharedPrograms.EmptyCategoryTable.P1'('ProgDefs.Categories.F2'(A,A)) :-
        'AVLTrees':'AVLTrees.AVLIsEmpty.P1'(A).
'~sharedPrograms.EmptyCategoryTable.P1'('ProgDefs.Categories.F2'(A,A)) :-
        'AVLTrees':'~AVLTrees.AVLIsEmpty.P1'(A).
'sharedPrograms.ConstantInLanguage.P3'(A, B, C) :-
        'sharedPrograms.SymbolInLanguage.P3'(A, B, 'ProgDefs.ConstantDecl.F1'(C)).
'~sharedPrograms.ConstantInLanguage.P3'(A, B, C) :-
        '~sharedPrograms.SymbolInLanguage.P3'(A, B, 'ProgDefs.ConstantDecl.F1'(C)).
'sharedPrograms.CheckHeadArgs1.P4'([], _, _, []).
'~sharedPrograms.CheckHeadArgs1.P4'([], _, _, []).
'sharedPrograms.CheckHeadArgs1.P4'([A|B], [C|D], [E|F], G) :-
        'sharedPrograms.VariantTypes.P4'(A, C, E, H),
        'Lists':'Lists.Append.P3'(H, I, G),
        'sharedPrograms.CheckHeadArgs1.P4'(B, D, F, I).
'~sharedPrograms.CheckHeadArgs1.P4'([A|B], [C|D], [E|F], G) :-
        '~sharedPrograms.VariantTypes.P4'(A, C, E, H),
        'Lists':'~Lists.Append.P3'(H, I, G),
        '~sharedPrograms.CheckHeadArgs1.P4'(B, D, F, I).
'sharedPrograms.CheckHeadArgs.P4'('MetaDefs.PAtom.F1'(_), _, _, []).
'~sharedPrograms.CheckHeadArgs.P4'('MetaDefs.PAtom.F1'(_), _, _, []).
'sharedPrograms.CheckHeadArgs.P4'('MetaDefs.Atom.F2'(A,B), C, D, E) :-
        'sharedPrograms.PredicateInLanguage.P4'(A, D, _, F),
        'sharedPrograms.MeltTypeList.P4'(F, [], _, G),
        'sharedPrograms.CheckHeadArgs1.P4'(G, C, B, E).
'~sharedPrograms.CheckHeadArgs.P4'('MetaDefs.Atom.F2'(A,B), C, D, E) :-
        '~sharedPrograms.PredicateInLanguage.P4'(A, D, _, F),
        '~sharedPrograms.MeltTypeList.P4'(F, [], _, G),
        '~sharedPrograms.CheckHeadArgs1.P4'(G, C, B, E).
'sharedPrograms.ConditionToIntDL.P3'(A, B, C) :-
        user:goedel_freeze(ground([A]), (A='ProgDefs.And.F2'(_,_),true->'SharedPrograms':'sharedPrograms.AndSeqToIntDL.P3'(A,B,C);user:goedel_freeze(ground([A]),(A='ProgDefs.Or.F2'(_,_),true->'SharedPrograms':'sharedPrograms.OrSeqToIntDL.P3'(A,B,C);'SharedPrograms':'sharedPrograms.SimpleCondToIntDL.P3'(A,B,C))))).
'~sharedPrograms.ConditionToIntDL.P3'(A, B, C) :-
        user:goedel_freeze(ground([A]), (A='ProgDefs.And.F2'(_,_),true->'SharedPrograms':'~sharedPrograms.AndSeqToIntDL.P3'(A,B,C);user:goedel_freeze(ground([A]),(A='ProgDefs.Or.F2'(_,_),true->'SharedPrograms':'~sharedPrograms.OrSeqToIntDL.P3'(A,B,C);'SharedPrograms':'~sharedPrograms.SimpleCondToIntDL.P3'(A,B,C))))).
'sharedPrograms.CookRationalTerm.P2'(A, B) :-
        user:goedel_freeze(ground([A]), ('Integers':'~Integers.<.P2'(A,0),true->('Integers':negative(A,D),C=D),B='MetaDefs.Term.F2'('MetaDefs.Name.F4'('"Rationals','"-','MetaDefs.Function.C0',1),['MetaDefs.Int.F1'(C)]);B='MetaDefs.Int.F1'(A))).
'~sharedPrograms.CookRationalTerm.P2'(A, B) :-
        user:goedel_freeze(ground([A]), ('Integers':'~Integers.<.P2'(A,0),true->('Integers':negative(A,D),C=D),B='MetaDefs.Term.F2'('MetaDefs.Name.F4'('"Rationals','"-','MetaDefs.Function.C0',1),['MetaDefs.Int.F1'(C)]);B='MetaDefs.Int.F1'(A))).
'sharedPrograms.ConstructorInLanguage.P3'(A, B, C) :-
        'sharedPrograms.TypeSymbolInLanguage.P3'(A, B, 'ProgDefs.ConstructorDecl.F1'(C)).
'~sharedPrograms.ConstructorInLanguage.P3'(A, B, C) :-
        '~sharedPrograms.TypeSymbolInLanguage.P3'(A, B, 'ProgDefs.ConstructorDecl.F1'(C)).
'sharedPrograms.ConstantToIntDL.P4'('MetaDefs.Name.F4'(A,B,C,_), D, E, F) :-
        user:goedel_freeze(ground([C,A,B]), ((A='"Lists',B='"Nil',C='MetaDefs.Constant.C0'),true->D='sharedPrograms.Bounded.C0','SharedPrograms':'sharedPrograms.CharDL.P3'('"[',E,G),'SharedPrograms':'sharedPrograms.CharDL.P3'('"]',G,F);user:goedel_freeze(ground([C,A,B]),((A='"Sets',B='"Null',C='MetaDefs.Constant.C0'),true->D='sharedPrograms.Bounded.C0','SharedPrograms':'sharedPrograms.CharDL.P3'('"{',E,G),'SharedPrograms':'sharedPrograms.CharDL.P3'('"}',G,F);'SharedPrograms':'sharedPrograms.ClassifyToken.P2'(B,D),'Strings':'Strings.StringInts.P2'(B,H),'Lists':'Lists.Append.P3'(H,F,E))))).
'~sharedPrograms.ConstantToIntDL.P4'('MetaDefs.Name.F4'(A,B,C,_), D, E, F) :-
        user:goedel_freeze(ground([C,A,B]), ((A='"Lists',B='"Nil',C='MetaDefs.Constant.C0'),true->D='sharedPrograms.Bounded.C0','SharedPrograms':'~sharedPrograms.CharDL.P3'('"[',E,G),'SharedPrograms':'~sharedPrograms.CharDL.P3'('"]',G,F);user:goedel_freeze(ground([C,A,B]),((A='"Sets',B='"Null',C='MetaDefs.Constant.C0'),true->D='sharedPrograms.Bounded.C0','SharedPrograms':'~sharedPrograms.CharDL.P3'('"{',E,G),'SharedPrograms':'~sharedPrograms.CharDL.P3'('"}',G,F);'SharedPrograms':'~sharedPrograms.ClassifyToken.P2'(B,D),'Strings':'~Strings.StringInts.P2'(B,H),'Lists':'~Lists.Append.P3'(H,F,E))))).
'sharedPrograms.ContainsConditional.P1'('MetaDefs.ISTE.F4'(_,_,_,_)).
'~sharedPrograms.ContainsConditional.P1'('MetaDefs.ISTE.F4'(_,_,_,_)).
'sharedPrograms.ContainsConditional.P1'('MetaDefs.IST.F3'(_,_,_)).
'~sharedPrograms.ContainsConditional.P1'('MetaDefs.IST.F3'(_,_,_)).
'sharedPrograms.ContainsConditional.P1'('MetaDefs.ITE.F3'(_,_,_)).
'~sharedPrograms.ContainsConditional.P1'('MetaDefs.ITE.F3'(_,_,_)).
'sharedPrograms.ContainsConditional.P1'('MetaDefs.IT.F2'(_,_)).
'~sharedPrograms.ContainsConditional.P1'('MetaDefs.IT.F2'(_,_)).
'sharedPrograms.ContainsConditional.P1'('MetaDefs.&''.F2'(A,B)) :-
        user:one_solution(('SharedPrograms':'sharedPrograms.ContainsConditional.P1'(A);'SharedPrograms':'sharedPrograms.ContainsConditional.P1'(B))).
'~sharedPrograms.ContainsConditional.P1'('MetaDefs.&''.F2'(A,B)) :-
        (   '~sharedPrograms.ContainsConditional.P1'(A)
        ;   '~sharedPrograms.ContainsConditional.P1'(B)
        ).
'sharedPrograms.DivideBindings.P4'([], A, A, []).
'~sharedPrograms.DivideBindings.P4'([], A, A, []).
'sharedPrograms.DivideBindings.P4'([A|B], C, D, E) :-
        'sharedPrograms.IsVariable.P1'(A),
        'sharedPrograms.DivideBindingsAux.P5'(C, A, F, E, G),
        'sharedPrograms.DivideBindings.P4'(B, F, D, G).
'~sharedPrograms.DivideBindings.P4'([A|B], C, D, E) :-
        '~sharedPrograms.IsVariable.P1'(A),
        '~sharedPrograms.DivideBindingsAux.P5'(C, A, F, E, G),
        '~sharedPrograms.DivideBindings.P4'(B, F, D, G).
'sharedPrograms.DeleteUnderscores.P2'([], []).
'~sharedPrograms.DeleteUnderscores.P2'([], []).
'sharedPrograms.DeleteUnderscores.P2'([A|B], C) :-
        user:goedel_freeze(ground([A]), (('Strings':concat('"_',_,D),A='MetaDefs.Var.F2'(D,_)),true->C=E;C=[A|E])),
        'sharedPrograms.DeleteUnderscores.P2'(B, E).
'~sharedPrograms.DeleteUnderscores.P2'([A|B], C) :-
        user:goedel_freeze(ground([A]), (('Strings':concat('"_',_,D),A='MetaDefs.Var.F2'(D,_)),true->C=E;C=[A|E])),
        '~sharedPrograms.DeleteUnderscores.P2'(B, E).
'sharedPrograms.DivideBindingsAux.P5'([], _, [], A, A).
'~sharedPrograms.DivideBindingsAux.P5'([], _, [], A, A).
'sharedPrograms.DivideBindingsAux.P5'(['MetaDefs.@.F2'(B,C)|A], D, E, F, G) :-
        user:goedel_freeze(ground([B,D]), (D=B,true->F=['MetaDefs.@.F2'(B,C)|G],E=A;E=['MetaDefs.@.F2'(B,C)|H],'SharedPrograms':'sharedPrograms.DivideBindingsAux.P5'(A,D,H,F,G))).
'~sharedPrograms.DivideBindingsAux.P5'(['MetaDefs.@.F2'(B,C)|A], D, E, F, G) :-
        user:goedel_freeze(ground([B,D]), (D=B,true->F=['MetaDefs.@.F2'(B,C)|G],E=A;E=['MetaDefs.@.F2'(B,C)|H],'SharedPrograms':'~sharedPrograms.DivideBindingsAux.P5'(A,D,H,F,G))).
'sharedPrograms.FormulaInLanguage.P4'(A, B, 'MetaDefs.VarTyping.F1'(C), 'MetaDefs.VarTyping.F1'(D)) :-
        'sharedPrograms.MeltVariableTyping.P4'(C, B, [], E),
        'sharedPrograms.MeltedFormulaTyping.P8'(A, B, E, D, _, [], [], []),
        'sharedPrograms.FixVariableTyping.P2'(D, 0).
'~sharedPrograms.FormulaInLanguage.P4'(A, B, 'MetaDefs.VarTyping.F1'(C), 'MetaDefs.VarTyping.F1'(D)) :-
        '~sharedPrograms.MeltVariableTyping.P4'(C, B, [], E),
        '~sharedPrograms.MeltedFormulaTyping.P8'(A, B, E, D, _, [], [], []),
        '~sharedPrograms.FixVariableTyping.P2'(D, 0).
'sharedPrograms.ExportLanguage.P3'('ProgDefs.Program.F4'(_,A,'ProgDefs.Language.F1'(B),_), C, 'ProgDefs.Language.F1'(D)) :-
        'sharedPrograms.EmptyLanguage.P1'('ProgDefs.Language.F1'(E)),
        'sharedPrograms.ImportedLanguage.P6'([C], A, B, [], E, D).
'~sharedPrograms.ExportLanguage.P3'('ProgDefs.Program.F4'(_,A,'ProgDefs.Language.F1'(B),_), C, 'ProgDefs.Language.F1'(D)) :-
        '~sharedPrograms.EmptyLanguage.P1'('ProgDefs.Language.F1'(E)),
        '~sharedPrograms.ImportedLanguage.P6'([C], A, B, [], E, D).
'sharedPrograms.ExpandString.P3'(A, B, C) :-
        'sharedPrograms.CharDL.P3'('""', B, D),
        'sharedPrograms.ExpandStringAux.P3'(A, D, C).
'~sharedPrograms.ExpandString.P3'(A, B, C) :-
        '~sharedPrograms.CharDL.P3'('""', B, D),
        '~sharedPrograms.ExpandStringAux.P3'(A, D, C).
'sharedPrograms.EmptyLanguage.P1'(A) :-
        'AVLTrees':'AVLTrees.AVLIsEmpty.P1'(B),
        'sharedPrograms.InitialiseLanguage.P2'('ProgDefs.Language.F1'(B), A).
'~sharedPrograms.EmptyLanguage.P1'(A) :-
        'AVLTrees':'~AVLTrees.AVLIsEmpty.P1'(B),
        '~sharedPrograms.InitialiseLanguage.P2'('ProgDefs.Language.F1'(B), A).
'sharedPrograms.ExpandStringAux.P3'([], A, B) :-
        'sharedPrograms.CharDL.P3'('""', A, B).
'~sharedPrograms.ExpandStringAux.P3'([], A, B) :-
        '~sharedPrograms.CharDL.P3'('""', A, B).
'sharedPrograms.ExpandStringAux.P3'([A|B], C, D) :-
        user:goedel_freeze(ground([A]), (A=34,true->'SharedPrograms':'sharedPrograms.CharDL.P3'('"\\',C,E),'SharedPrograms':'sharedPrograms.CharDL.P3'('""',E,F);user:goedel_freeze(ground([A]),(A=92,true->'SharedPrograms':'sharedPrograms.CharDL.P3'('"\\',C,E),'SharedPrograms':'sharedPrograms.CharDL.P3'('"\\',E,F);C=[A|F])))), %% added 3 \ djd
        'sharedPrograms.ExpandStringAux.P3'(B, F, D).
'~sharedPrograms.ExpandStringAux.P3'([A|B], C, D) :-
        user:goedel_freeze(ground([A]), (A=34,true->'SharedPrograms':'~sharedPrograms.CharDL.P3'('"\\',C,E),'SharedPrograms':'~sharedPrograms.CharDL.P3'('""',E,F);user:goedel_freeze(ground([A]),(A=92,true->'SharedPrograms':'~sharedPrograms.CharDL.P3'('"\\',C,E),'SharedPrograms':'~sharedPrograms.CharDL.P3'('"\\',E,F);C=[A|F])))),  %% added 3 \ djd
        '~sharedPrograms.ExpandStringAux.P3'(B, F, D).
'sharedPrograms.FixVariableTyping.P2'([], _).
'~sharedPrograms.FixVariableTyping.P2'([], _).
'sharedPrograms.FixVariableTyping.P2'(['MetaDefs.@.F2'(_,B)|A], C) :-
        'sharedPrograms.FixType.P3'(B, C, D),
        'sharedPrograms.FixVariableTyping.P2'(A, D).
'~sharedPrograms.FixVariableTyping.P2'(['MetaDefs.@.F2'(_,B)|A], C) :-
        '~sharedPrograms.FixType.P3'(B, C, D),
        '~sharedPrograms.FixVariableTyping.P2'(A, D).
'sharedPrograms.FunctionInLanguage.P5'(A, B, C, D, E) :-
        'sharedPrograms.SymbolInLanguage.P3'(A, B, 'ProgDefs.FunctionDecl.F4'(_,C,D,E)).
'~sharedPrograms.FunctionInLanguage.P5'(A, B, C, D, E) :-
        '~sharedPrograms.SymbolInLanguage.P3'(A, B, 'ProgDefs.FunctionDecl.F4'(_,C,D,E)).
'sharedPrograms.FormulaToIntList.P4'(A, B, C, D) :-
        'sharedPrograms.ProgramLanguage.P2'(A, E),
        'sharedPrograms.ModuleLanguage.P3'(A, B, F),
        'sharedPrograms.FormulaInLanguage.P4'(C, E, 'MetaDefs.VarTyping.F1'([]), 'MetaDefs.VarTyping.F1'(G)),
        'sharedPrograms.FormulaToIntDL.P6'(C, F, E, G, D, []).
'~sharedPrograms.FormulaToIntList.P4'(A, B, C, D) :-
        '~sharedPrograms.ProgramLanguage.P2'(A, E),
        '~sharedPrograms.ModuleLanguage.P3'(A, B, F),
        '~sharedPrograms.FormulaInLanguage.P4'(C, E, 'MetaDefs.VarTyping.F1'([]), 'MetaDefs.VarTyping.F1'(G)),
        '~sharedPrograms.FormulaToIntDL.P6'(C, F, E, G, D, []).
'sharedPrograms.FormulaToIntDL.P6'('MetaDefs.Empty.C0', _, _, _, A, A).
'~sharedPrograms.FormulaToIntDL.P6'('MetaDefs.Empty.C0', _, _, _, A, A).
'sharedPrograms.FormulaToIntDL.P6'('MetaDefs.PAtom.F1'(A), B, _, _, C, D) :-
        'sharedPrograms.PropositionInLanguage.P2'(A, B),
        A='MetaDefs.Name.F4'(_,E,_,_),
        'Strings':'Strings.StringInts.P2'(E, F),
        'Lists':'Lists.Append.P3'(F, D, C).
'~sharedPrograms.FormulaToIntDL.P6'('MetaDefs.PAtom.F1'(A), B, _, _, C, D) :-
        '~sharedPrograms.PropositionInLanguage.P2'(A, B),
        A='MetaDefs.Name.F4'(_,E,_,_),
        'Strings':'~Strings.StringInts.P2'(E, F),
        'Lists':'~Lists.Append.P3'(F, D, C).
'sharedPrograms.FormulaToIntDL.P6'('MetaDefs.Atom.F2'(A,B), C, D, E, F, G) :-
        'sharedPrograms.PredicateInLanguage.P4'(A, C, H, _),
        'sharedPrograms.AtomToIntDL.P8'(H, A, B, C, D, E, F, G).
'~sharedPrograms.FormulaToIntDL.P6'('MetaDefs.Atom.F2'(A,B), C, D, E, F, G) :-
        '~sharedPrograms.PredicateInLanguage.P4'(A, C, H, _),
        '~sharedPrograms.AtomToIntDL.P8'(H, A, B, C, D, E, F, G).
'sharedPrograms.FormulaToIntDL.P6'('MetaDefs.~''.F1'(A), B, C, D, E, F) :-
        'sharedPrograms.CharDL.P3'('"~', E, G),
        'sharedPrograms.FormulaToIntDL.P6'(A, B, C, D, H, I),
        user:goedel_freeze(ground([A]), (('SharedPrograms':'~sharedPrograms.CLPrec.P2'(A,J),'SharedPrograms':'~sharedPrograms.CRPrec.P2'('MetaDefs.~''.F1'(_),K),'SharedPrograms':'~sharedPrograms.BindsTighter.P2'(J,K)),true->G=H,F=I;'SharedPrograms':'sharedPrograms.CharDL.P3'('"(',G,H),'SharedPrograms':'sharedPrograms.CharDL.P3'('")',I,F))).
'~sharedPrograms.FormulaToIntDL.P6'('MetaDefs.~''.F1'(A), B, C, D, E, F) :-
        '~sharedPrograms.CharDL.P3'('"~', E, G),
        '~sharedPrograms.FormulaToIntDL.P6'(A, B, C, D, H, I),
        user:goedel_freeze(ground([A]), (('SharedPrograms':'~sharedPrograms.CLPrec.P2'(A,J),'SharedPrograms':'~sharedPrograms.CRPrec.P2'('MetaDefs.~''.F1'(_),K),'SharedPrograms':'~sharedPrograms.BindsTighter.P2'(J,K)),true->G=H,F=I;'SharedPrograms':'~sharedPrograms.CharDL.P3'('"(',G,H),'SharedPrograms':'~sharedPrograms.CharDL.P3'('")',I,F))).
'sharedPrograms.FormulaToIntDL.P6'('MetaDefs.&''.F2'(A,B), C, D, E, F, G) :-
        'sharedPrograms.BinaryFormulaToIntDL.P6'('MetaDefs.&''.F2'(A,B), C, D, E, F, G).
'~sharedPrograms.FormulaToIntDL.P6'('MetaDefs.&''.F2'(A,B), C, D, E, F, G) :-
        '~sharedPrograms.BinaryFormulaToIntDL.P6'('MetaDefs.&''.F2'(A,B), C, D, E, F, G).
'sharedPrograms.FormulaToIntDL.P6'('MetaDefs.\\/''.F2'(A,B), C, D, E, F, G) :- % added \ djd
        'sharedPrograms.BinaryFormulaToIntDL.P6'('MetaDefs.\\/''.F2'(A,B), C, D, E, F, G). % added \ djd
'~sharedPrograms.FormulaToIntDL.P6'('MetaDefs.\\/''.F2'(A,B), C, D, E, F, G) :- % added \ djd
        '~sharedPrograms.BinaryFormulaToIntDL.P6'('MetaDefs.\\/''.F2'(A,B), C, D, E, F, G). % added \ djd
'sharedPrograms.FormulaToIntDL.P6'('MetaDefs.->''.F2'(A,B), C, D, E, F, G) :-
        'sharedPrograms.BinaryFormulaToIntDL.P6'('MetaDefs.->''.F2'(A,B), C, D, E, F, G).
'~sharedPrograms.FormulaToIntDL.P6'('MetaDefs.->''.F2'(A,B), C, D, E, F, G) :-
        '~sharedPrograms.BinaryFormulaToIntDL.P6'('MetaDefs.->''.F2'(A,B), C, D, E, F, G).
'sharedPrograms.FormulaToIntDL.P6'('MetaDefs.<-''.F2'(A,B), C, D, E, F, G) :-
        'sharedPrograms.BinaryFormulaToIntDL.P6'('MetaDefs.<-''.F2'(A,B), C, D, E, F, G).
'~sharedPrograms.FormulaToIntDL.P6'('MetaDefs.<-''.F2'(A,B), C, D, E, F, G) :-
        '~sharedPrograms.BinaryFormulaToIntDL.P6'('MetaDefs.<-''.F2'(A,B), C, D, E, F, G).
'sharedPrograms.FormulaToIntDL.P6'('MetaDefs.<->''.F2'(A,B), C, D, E, F, G) :-
        'sharedPrograms.BinaryFormulaToIntDL.P6'('MetaDefs.<->''.F2'(A,B), C, D, E, F, G).
'~sharedPrograms.FormulaToIntDL.P6'('MetaDefs.<->''.F2'(A,B), C, D, E, F, G) :-
        '~sharedPrograms.BinaryFormulaToIntDL.P6'('MetaDefs.<->''.F2'(A,B), C, D, E, F, G).
'sharedPrograms.FormulaToIntDL.P6'('MetaDefs.All.F2'(A,B), C, D, E, F, G) :-
        'sharedPrograms.QuantifiedFormulaToIntDL.P6'('MetaDefs.All.F2'(A,B), C, D, E, F, G).
'~sharedPrograms.FormulaToIntDL.P6'('MetaDefs.All.F2'(A,B), C, D, E, F, G) :-
        '~sharedPrograms.QuantifiedFormulaToIntDL.P6'('MetaDefs.All.F2'(A,B), C, D, E, F, G).
'sharedPrograms.FormulaToIntDL.P6'('MetaDefs.Some.F2'(A,B), C, D, E, F, G) :-
        'sharedPrograms.QuantifiedFormulaToIntDL.P6'('MetaDefs.Some.F2'(A,B), C, D, E, F, G).
'~sharedPrograms.FormulaToIntDL.P6'('MetaDefs.Some.F2'(A,B), C, D, E, F, G) :-
        '~sharedPrograms.QuantifiedFormulaToIntDL.P6'('MetaDefs.Some.F2'(A,B), C, D, E, F, G).
'sharedPrograms.FormulaToIntDL.P6'('MetaDefs.ISTE.F4'(A,B,C,D), E, F, G, H, I) :-
        'Strings':'Strings.StringInts.P2'('"IF ', J),
        'Lists':'Lists.Append.P3'(J, K, H),
        'sharedPrograms.FormulaToIntDL.P6'('MetaDefs.Some.F2'(A,B), E, F, G, K, L),
        'Strings':'Strings.StringInts.P2'('" THEN ', M),
        'Lists':'Lists.Append.P3'(M, N, L),
        'sharedPrograms.ThenPartToIntDL.P6'(C, E, F, G, N, O),
        'Strings':'Strings.StringInts.P2'('" ELSE ', P),
        'Lists':'Lists.Append.P3'(P, Q, O),
        'sharedPrograms.FormulaToIntDL.P6'(D, E, F, G, Q, I).
'~sharedPrograms.FormulaToIntDL.P6'('MetaDefs.ISTE.F4'(A,B,C,D), E, F, G, H, I) :-
        'Strings':'~Strings.StringInts.P2'('"IF ', J),
        'Lists':'~Lists.Append.P3'(J, K, H),
        '~sharedPrograms.FormulaToIntDL.P6'('MetaDefs.Some.F2'(A,B), E, F, G, K, L),
        'Strings':'~Strings.StringInts.P2'('" THEN ', M),
        'Lists':'~Lists.Append.P3'(M, N, L),
        '~sharedPrograms.ThenPartToIntDL.P6'(C, E, F, G, N, O),
        'Strings':'~Strings.StringInts.P2'('" ELSE ', P),
        'Lists':'~Lists.Append.P3'(P, Q, O),
        '~sharedPrograms.FormulaToIntDL.P6'(D, E, F, G, Q, I).
'sharedPrograms.FormulaToIntDL.P6'('MetaDefs.ITE.F3'(A,B,C), D, E, F, G, H) :-
        'Strings':'Strings.StringInts.P2'('"IF ', I),
        'Lists':'Lists.Append.P3'(I, J, G),
        'sharedPrograms.FormulaToIntDL.P6'(A, D, E, F, K, L),
        user:goedel_freeze(ground([A]), (A='MetaDefs.Some.F2'(_,_),true->'SharedPrograms':'sharedPrograms.CharDL.P3'('"(',J,K),'SharedPrograms':'sharedPrograms.CharDL.P3'('")',L,M);J=K,M=L)),
        'Strings':'Strings.StringInts.P2'('" THEN ', N),
        'Lists':'Lists.Append.P3'(N, O, M),
        'sharedPrograms.ThenPartToIntDL.P6'(B, D, E, F, O, P),
        'Strings':'Strings.StringInts.P2'('" ELSE ', Q),
        'Lists':'Lists.Append.P3'(Q, R, P),
        'sharedPrograms.FormulaToIntDL.P6'(C, D, E, F, R, H).
'~sharedPrograms.FormulaToIntDL.P6'('MetaDefs.ITE.F3'(A,B,C), D, E, F, G, H) :-
        'Strings':'~Strings.StringInts.P2'('"IF ', I),
        'Lists':'~Lists.Append.P3'(I, J, G),
        '~sharedPrograms.FormulaToIntDL.P6'(A, D, E, F, K, L),
        user:goedel_freeze(ground([A]), (A='MetaDefs.Some.F2'(_,_),true->'SharedPrograms':'~sharedPrograms.CharDL.P3'('"(',J,K),'SharedPrograms':'~sharedPrograms.CharDL.P3'('")',L,M);J=K,M=L)),
        'Strings':'~Strings.StringInts.P2'('" THEN ', N),
        'Lists':'~Lists.Append.P3'(N, O, M),
        '~sharedPrograms.ThenPartToIntDL.P6'(B, D, E, F, O, P),
        'Strings':'~Strings.StringInts.P2'('" ELSE ', Q),
        'Lists':'~Lists.Append.P3'(Q, R, P),
        '~sharedPrograms.FormulaToIntDL.P6'(C, D, E, F, R, H).
'sharedPrograms.FormulaToIntDL.P6'('MetaDefs.IST.F3'(A,B,C), D, E, F, G, H) :-
        'Strings':'Strings.StringInts.P2'('"IF ', I),
        'Lists':'Lists.Append.P3'(I, J, G),
        'sharedPrograms.FormulaToIntDL.P6'('MetaDefs.Some.F2'(A,B), D, E, F, J, K),
        'Strings':'Strings.StringInts.P2'('" THEN ', L),
        'Lists':'Lists.Append.P3'(L, M, K),
        'sharedPrograms.ThenPartToIntDL.P6'(C, D, E, F, M, H).
'~sharedPrograms.FormulaToIntDL.P6'('MetaDefs.IST.F3'(A,B,C), D, E, F, G, H) :-
        'Strings':'~Strings.StringInts.P2'('"IF ', I),
        'Lists':'~Lists.Append.P3'(I, J, G),
        '~sharedPrograms.FormulaToIntDL.P6'('MetaDefs.Some.F2'(A,B), D, E, F, J, K),
        'Strings':'~Strings.StringInts.P2'('" THEN ', L),
        'Lists':'~Lists.Append.P3'(L, M, K),
        '~sharedPrograms.ThenPartToIntDL.P6'(C, D, E, F, M, H).
'sharedPrograms.FormulaToIntDL.P6'('MetaDefs.IT.F2'(A,B), C, D, E, F, G) :-
        'Strings':'Strings.StringInts.P2'('"IF ', H),
        'Lists':'Lists.Append.P3'(H, I, F),
        'sharedPrograms.FormulaToIntDL.P6'(A, C, D, E, J, K),
        user:goedel_freeze(ground([A]), (A='MetaDefs.Some.F2'(_,_),true->'SharedPrograms':'sharedPrograms.CharDL.P3'('"(',I,J),'SharedPrograms':'sharedPrograms.CharDL.P3'('")',K,L);I=J,L=K)),
        'Strings':'Strings.StringInts.P2'('" THEN ', M),
        'Lists':'Lists.Append.P3'(M, N, L),
        'sharedPrograms.ThenPartToIntDL.P6'(B, C, D, E, N, G).
'~sharedPrograms.FormulaToIntDL.P6'('MetaDefs.IT.F2'(A,B), C, D, E, F, G) :-
        'Strings':'~Strings.StringInts.P2'('"IF ', H),
        'Lists':'~Lists.Append.P3'(H, I, F),
        '~sharedPrograms.FormulaToIntDL.P6'(A, C, D, E, J, K),
        user:goedel_freeze(ground([A]), (A='MetaDefs.Some.F2'(_,_),true->'SharedPrograms':'~sharedPrograms.CharDL.P3'('"(',I,J),'SharedPrograms':'~sharedPrograms.CharDL.P3'('")',K,L);I=J,L=K)),
        'Strings':'~Strings.StringInts.P2'('" THEN ', M),
        'Lists':'~Lists.Append.P3'(M, N, L),
        '~sharedPrograms.ThenPartToIntDL.P6'(B, C, D, E, N, G).
'sharedPrograms.FormulaToIntDL.P6'('MetaDefs.Commit.F2'(A,B), C, D, E, F, G) :-
        'sharedPrograms.CharDL.P3'('"{', F, H),
        'sharedPrograms.FormulaToIntDL.P6'(B, C, D, E, H, I),
        'sharedPrograms.CharDL.P3'('"}', I, J),
        'sharedPrograms.CharDL.P3'('"_', J, K),
        'SharedSyntax':'SharedSyntax.IntegerToCharDL.P3'(A, K, G).
'~sharedPrograms.FormulaToIntDL.P6'('MetaDefs.Commit.F2'(A,B), C, D, E, F, G) :-
        '~sharedPrograms.CharDL.P3'('"{', F, H),
        '~sharedPrograms.FormulaToIntDL.P6'(B, C, D, E, H, I),
        '~sharedPrograms.CharDL.P3'('"}', I, J),
        '~sharedPrograms.CharDL.P3'('"_', J, K),
        'SharedSyntax':'~SharedSyntax.IntegerToCharDL.P3'(A, K, G).
'sharedPrograms.ImportedLanguage.P6'([], _, _, _, A, A).
'~sharedPrograms.ImportedLanguage.P6'([], _, _, _, A, A).
'sharedPrograms.ImportedLanguage.P6'([A|B], C, D, E, F, G) :-
        user:goedel_freeze(ground([A,E]), ('Lists':'~Lists.Member.P2'(A,E),true->H=F,I=E,J=B;I=[A|E],user:goedel_freeze(ground([D,A]),if(('AVLTrees':'~AVLTrees.AVLSearch.P3'(D,A,'ProgDefs.Module.F3'(_,K,L)),true),('AVLTrees':'AVLTrees.AVLAmend.P6'(F,A,'ProgDefs.Module.F3'('ProgDefs.Exported.C0',K,[]),_,M,_),'SharedPrograms':'sharedPrograms.AddLiftedLanguage.P4'(L,I,M,H)),('SharedPrograms':'sharedPrograms.EmptyCategoryTable.P1'(N),'AVLTrees':'AVLTrees.AVLAmend.P6'(F,A,'ProgDefs.Module.F3'('ProgDefs.Exported.C0',N,[]),_,H,_)))),'AVLTrees':'AVLTrees.AVLSearch.P3'(C,A,'ProgDefs.ModDef.F4'(_,O,_,_)),'Lists':'Lists.Append.P3'(O,B,J))),
        'sharedPrograms.ImportedLanguage.P6'(J, C, D, I, H, G).
'~sharedPrograms.ImportedLanguage.P6'([A|B], C, D, E, F, G) :-
        user:goedel_freeze(ground([A,E]), ('Lists':'~Lists.Member.P2'(A,E),true->H=F,I=E,J=B;I=[A|E],user:goedel_freeze(ground([D,A]),if(('AVLTrees':'~AVLTrees.AVLSearch.P3'(D,A,'ProgDefs.Module.F3'(_,K,L)),true),('AVLTrees':'~AVLTrees.AVLAmend.P6'(F,A,'ProgDefs.Module.F3'('ProgDefs.Exported.C0',K,[]),_,M,_),'SharedPrograms':'~sharedPrograms.AddLiftedLanguage.P4'(L,I,M,H)),('SharedPrograms':'~sharedPrograms.EmptyCategoryTable.P1'(N),'AVLTrees':'~AVLTrees.AVLAmend.P6'(F,A,'ProgDefs.Module.F3'('ProgDefs.Exported.C0',N,[]),_,H,_)))),'AVLTrees':'~AVLTrees.AVLSearch.P3'(C,A,'ProgDefs.ModDef.F4'(_,O,_,_)),'Lists':'~Lists.Append.P3'(O,B,J))),
        '~sharedPrograms.ImportedLanguage.P6'(J, C, D, I, H, G).
'sharedPrograms.HeadAtom.P9'('MetaDefs.PAtom.F1'(A), B, C, C, 'MetaDefs.PAtom.F1'(A), D, D, [], []) :-
        'sharedPrograms.PropositionInLanguage.P2'(A, B).
'~sharedPrograms.HeadAtom.P9'('MetaDefs.PAtom.F1'(A), B, C, C, 'MetaDefs.PAtom.F1'(A), D, D, [], []) :-
        '~sharedPrograms.PropositionInLanguage.P2'(A, B).
'sharedPrograms.HeadAtom.P9'('MetaDefs.Atom.F2'(A,B), C, D, E, 'MetaDefs.Atom.F2'(A,F), G, H, I, J) :-
        'sharedPrograms.PredicateInLanguage.P4'(A, C, _, K),
        'sharedPrograms.MeltTypeList.P4'(K, [], _, I),
        'sharedPrograms.MeltedArgumentTyping.P9'(I, B, C, D, E, F, G, H, J).
'~sharedPrograms.HeadAtom.P9'('MetaDefs.Atom.F2'(A,B), C, D, E, 'MetaDefs.Atom.F2'(A,F), G, H, I, J) :-
        '~sharedPrograms.PredicateInLanguage.P4'(A, C, _, K),
        '~sharedPrograms.MeltTypeList.P4'(K, [], _, I),
        '~sharedPrograms.MeltedArgumentTyping.P9'(I, B, C, D, E, F, G, H, J).
'sharedPrograms.MatchingDescriptor.P5'('ProgDefs.Symbol.F2'(A,B), C, D, E, B) :-
        'sharedPrograms.Accessible.P2'(C, A),
        'sharedPrograms.MatchingName.P3'(B, D, E).
'~sharedPrograms.MatchingDescriptor.P5'('ProgDefs.Symbol.F2'(A,B), C, D, E, B) :-
        '~sharedPrograms.Accessible.P2'(C, A),
        '~sharedPrograms.MatchingName.P3'(B, D, E).
'sharedPrograms.KindHasPart.P2'('ProgDefs.ModuleKind.C0', 'ProgDefs.Module.C0').
'~sharedPrograms.KindHasPart.P2'('ProgDefs.ModuleKind.C0', 'ProgDefs.Module.C0').
'sharedPrograms.KindHasPart.P2'('ProgDefs.NormalKind.C0', A) :-
        'sharedPrograms.FindMember.P2'(A, ['ProgDefs.Export.C0','ProgDefs.Local.C0']).
'~sharedPrograms.KindHasPart.P2'('ProgDefs.NormalKind.C0', A) :-
        '~sharedPrograms.FindMember.P2'(A, ['ProgDefs.Export.C0','ProgDefs.Local.C0']).
'sharedPrograms.KindHasPart.P2'('ProgDefs.ClosedKind.C0', 'ProgDefs.Closed.C0').
'~sharedPrograms.KindHasPart.P2'('ProgDefs.ClosedKind.C0', 'ProgDefs.Closed.C0').
'sharedPrograms.InsertTypeSymbol.P5'('MetaDefs.Name.F4'(A,B,C,D), 'ProgDefs.Language.F1'(E), F, G, 'ProgDefs.Language.F1'(H)) :-
        'AVLTrees':'AVLTrees.AVLIsEmpty.P1'(I),
        'AVLTrees':'AVLTrees.AVLIsEmpty.P1'(J),
        'AVLTrees':'AVLTrees.AVLAmend.P6'(E, A, 'ProgDefs.Module.F3'(K,'ProgDefs.Categories.F2'(L,M),N), 'ProgDefs.Module.F3'('ProgDefs.Hidden.C0','ProgDefs.Categories.F2'(I,J),[]), H, 'ProgDefs.Module.F3'(K,'ProgDefs.Categories.F2'(O,M),N)),
        'AVLTrees':'AVLTrees.AVLAmend.P6'(O, B, P, [], L, Q),
        'sharedPrograms.MatchingName.P3'(G, C, D),
        'sharedPrograms.AddToDescriptorList.P6'(Q, K, C, D, 'ProgDefs.Symbol.F2'(F,G), P).
'~sharedPrograms.InsertTypeSymbol.P5'('MetaDefs.Name.F4'(A,B,C,D), 'ProgDefs.Language.F1'(E), F, G, 'ProgDefs.Language.F1'(H)) :-
        'AVLTrees':'~AVLTrees.AVLIsEmpty.P1'(I),
        'AVLTrees':'~AVLTrees.AVLIsEmpty.P1'(J),
        'AVLTrees':'~AVLTrees.AVLAmend.P6'(E, A, 'ProgDefs.Module.F3'(K,'ProgDefs.Categories.F2'(L,M),N), 'ProgDefs.Module.F3'('ProgDefs.Hidden.C0','ProgDefs.Categories.F2'(I,J),[]), H, 'ProgDefs.Module.F3'(K,'ProgDefs.Categories.F2'(O,M),N)),
        'AVLTrees':'~AVLTrees.AVLAmend.P6'(O, B, P, [], L, Q),
        '~sharedPrograms.MatchingName.P3'(G, C, D),
        '~sharedPrograms.AddToDescriptorList.P6'(Q, K, C, D, 'ProgDefs.Symbol.F2'(F,G), P).
'sharedPrograms.InsertSymbol.P5'('MetaDefs.Name.F4'(A,B,C,D), 'ProgDefs.Language.F1'(E), F, G, 'ProgDefs.Language.F1'(H)) :-
        'AVLTrees':'AVLTrees.AVLIsEmpty.P1'(I),
        'AVLTrees':'AVLTrees.AVLIsEmpty.P1'(J),
        'AVLTrees':'AVLTrees.AVLAmend.P6'(E, A, 'ProgDefs.Module.F3'(K,'ProgDefs.Categories.F2'(L,M),N), 'ProgDefs.Module.F3'('ProgDefs.Hidden.C0','ProgDefs.Categories.F2'(I,J),[]), H, 'ProgDefs.Module.F3'(K,'ProgDefs.Categories.F2'(L,O),N)),
        'AVLTrees':'AVLTrees.AVLAmend.P6'(O, B, P, [], M, Q),
        'sharedPrograms.MatchingName.P3'(G, C, D),
        'sharedPrograms.AddToDescriptorList.P6'(Q, K, C, D, 'ProgDefs.Symbol.F2'(F,G), P).
'~sharedPrograms.InsertSymbol.P5'('MetaDefs.Name.F4'(A,B,C,D), 'ProgDefs.Language.F1'(E), F, G, 'ProgDefs.Language.F1'(H)) :-
        'AVLTrees':'~AVLTrees.AVLIsEmpty.P1'(I),
        'AVLTrees':'~AVLTrees.AVLIsEmpty.P1'(J),
        'AVLTrees':'~AVLTrees.AVLAmend.P6'(E, A, 'ProgDefs.Module.F3'(K,'ProgDefs.Categories.F2'(L,M),N), 'ProgDefs.Module.F3'('ProgDefs.Hidden.C0','ProgDefs.Categories.F2'(I,J),[]), H, 'ProgDefs.Module.F3'(K,'ProgDefs.Categories.F2'(L,O),N)),
        'AVLTrees':'~AVLTrees.AVLAmend.P6'(O, B, P, [], M, Q),
        '~sharedPrograms.MatchingName.P3'(G, C, D),
        '~sharedPrograms.AddToDescriptorList.P6'(Q, K, C, D, 'ProgDefs.Symbol.F2'(F,G), P).
'sharedPrograms.IsVariable.P1'('MetaDefs.Var.F2'(_,_)).
'~sharedPrograms.IsVariable.P1'('MetaDefs.Var.F2'(_,_)).
'sharedPrograms.IsVariable.P1'('MetaDefs.Var.F1'(_)).
'~sharedPrograms.IsVariable.P1'('MetaDefs.Var.F1'(_)).
'sharedPrograms.LookupParDict.P4'(A, B, C, D) :-
        'sharedPrograms.LookupParDictAux.P5'(A, B, A, C, D).
'~sharedPrograms.LookupParDict.P4'(A, B, C, D) :-
        '~sharedPrograms.LookupParDictAux.P5'(A, B, A, C, D).
'sharedPrograms.ListExprToIntDL.P6'([A,B], C, D, E, F, G) :-
        'sharedPrograms.CharDL.P3'('"[', F, H),
        'sharedPrograms.TermToIntDL.P9'(A, C, D, E, _, _, _, H, I),
        'sharedPrograms.ChainExprToIntDL.P6'(B, C, D, E, I, J),
        'sharedPrograms.CharDL.P3'('"]', J, G).
'~sharedPrograms.ListExprToIntDL.P6'([A,B], C, D, E, F, G) :-
        '~sharedPrograms.CharDL.P3'('"[', F, H),
        '~sharedPrograms.TermToIntDL.P9'(A, C, D, E, _, _, _, H, I),
        '~sharedPrograms.ChainExprToIntDL.P6'(B, C, D, E, I, J),
        '~sharedPrograms.CharDL.P3'('"]', J, G).
'sharedPrograms.LPrec.P2'('Syntax.NoFunctInd.C0', 'sharedPrograms.Infinity.C0').
'~sharedPrograms.LPrec.P2'('Syntax.NoFunctInd.C0', 'sharedPrograms.Infinity.C0').
'sharedPrograms.LPrec.P2'('Syntax.XFX.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'~sharedPrograms.LPrec.P2'('Syntax.XFX.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'sharedPrograms.LPrec.P2'('Syntax.XFY.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'~sharedPrograms.LPrec.P2'('Syntax.XFY.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'sharedPrograms.LPrec.P2'('Syntax.YFX.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.Y.C0')).
'~sharedPrograms.LPrec.P2'('Syntax.YFX.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.Y.C0')).
'sharedPrograms.LPrec.P2'('Syntax.FX.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'~sharedPrograms.LPrec.P2'('Syntax.FX.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'sharedPrograms.LPrec.P2'('Syntax.FY.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'~sharedPrograms.LPrec.P2'('Syntax.FY.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'sharedPrograms.LPrec.P2'('Syntax.XF.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'~sharedPrograms.LPrec.P2'('Syntax.XF.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'sharedPrograms.LPrec.P2'('Syntax.YF.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.Y.C0')).
'~sharedPrograms.LPrec.P2'('Syntax.YF.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.Y.C0')).
'sharedPrograms.ListTypesInLanguage.P2'([], _).
'~sharedPrograms.ListTypesInLanguage.P2'([], _).
'sharedPrograms.ListTypesInLanguage.P2'([A|B], C) :-
        'sharedPrograms.TypeInLanguage.P2'(A, C),
        'sharedPrograms.ListTypesInLanguage.P2'(B, C).
'~sharedPrograms.ListTypesInLanguage.P2'([A|B], C) :-
        '~sharedPrograms.TypeInLanguage.P2'(A, C),
        '~sharedPrograms.ListTypesInLanguage.P2'(B, C).
'sharedPrograms.LookupVarTyping.P4'(A, B, C, D) :-
        'sharedPrograms.LookupVarTypingAux.P5'(A, B, A, C, D).
'~sharedPrograms.LookupVarTyping.P4'(A, B, C, D) :-
        '~sharedPrograms.LookupVarTypingAux.P5'(A, B, A, C, D).
'sharedPrograms.LookupParDictAux.P5'([], A, B, ['MetaDefs.!.F2'(A,C)|B], C).
'~sharedPrograms.LookupParDictAux.P5'([], A, B, ['MetaDefs.!.F2'(A,C)|B], C).
'sharedPrograms.LookupParDictAux.P5'(['MetaDefs.!.F2'(B,C)|A], D, E, F, G) :-
        user:goedel_freeze(ground([B,D]), (D=B,true->G=C,F=E;'SharedPrograms':'sharedPrograms.LookupParDictAux.P5'(A,D,E,F,G))).
'~sharedPrograms.LookupParDictAux.P5'(['MetaDefs.!.F2'(B,C)|A], D, E, F, G) :-
        user:goedel_freeze(ground([B,D]), (D=B,true->G=C,F=E;'SharedPrograms':'~sharedPrograms.LookupParDictAux.P5'(A,D,E,F,G))).
'sharedPrograms.LookupVarTypingAux.P5'([], A, B, ['MetaDefs.@.F2'(A,C)|B], C).
'~sharedPrograms.LookupVarTypingAux.P5'([], A, B, ['MetaDefs.@.F2'(A,C)|B], C).
'sharedPrograms.LookupVarTypingAux.P5'(['MetaDefs.@.F2'(B,C)|A], D, E, F, G) :-
        user:goedel_freeze(ground([B,D]), (D=B,true->G=C,F=E;'SharedPrograms':'sharedPrograms.LookupVarTypingAux.P5'(A,D,E,F,G))).
'~sharedPrograms.LookupVarTypingAux.P5'(['MetaDefs.@.F2'(B,C)|A], D, E, F, G) :-
        user:goedel_freeze(ground([B,D]), (D=B,true->G=C,F=E;'SharedPrograms':'~sharedPrograms.LookupVarTypingAux.P5'(A,D,E,F,G))).
'sharedPrograms.MeltedFormulaTyping.P8'(A, B, C, D, E, F, G, H) :-
        user:goedel_freeze(ground([A]), if((A='MetaDefs.<-''.F2'(I,J),true),('SharedPrograms':'sharedPrograms.MeltedBodyTyping.P8'(I,B,C,K,L,F,M,N),user:goedel_freeze(ground([N]),(N=[],true->'SharedPrograms':'sharedPrograms.MeltedBodyTyping.P8'(J,B,K,D,O,M,G,H),E='MetaDefs.<-''.F2'(L,O);H=N))),'SharedPrograms':'sharedPrograms.MeltedBodyTyping.P8'(A,B,C,D,E,F,G,H))).
'~sharedPrograms.MeltedFormulaTyping.P8'(A, B, C, D, E, F, G, H) :-
        user:goedel_freeze(ground([A]), if((A='MetaDefs.<-''.F2'(I,J),true),('SharedPrograms':'~sharedPrograms.MeltedBodyTyping.P8'(I,B,C,K,L,F,M,N),user:goedel_freeze(ground([N]),(N=[],true->'SharedPrograms':'~sharedPrograms.MeltedBodyTyping.P8'(J,B,K,D,O,M,G,H),E='MetaDefs.<-''.F2'(L,O);H=N))),'SharedPrograms':'~sharedPrograms.MeltedBodyTyping.P8'(A,B,C,D,E,F,G,H))).
'sharedPrograms.MeltVariableTyping.P4'([], _, _, []).
'~sharedPrograms.MeltVariableTyping.P4'([], _, _, []).
'sharedPrograms.MeltVariableTyping.P4'(['MetaDefs.@.F2'(B,C)|A], D, E, ['MetaDefs.@.F2'(B,G)|F]) :-
        'sharedPrograms.IsVariable.P1'(B),
        'sharedPrograms.TypeInLanguage.P2'(C, D),
        'sharedPrograms.MeltType.P4'(C, E, H, G),
        'sharedPrograms.MeltVariableTyping.P4'(A, D, H, F).
'~sharedPrograms.MeltVariableTyping.P4'(['MetaDefs.@.F2'(B,C)|A], D, E, ['MetaDefs.@.F2'(B,G)|F]) :-
        '~sharedPrograms.IsVariable.P1'(B),
        '~sharedPrograms.TypeInLanguage.P2'(C, D),
        '~sharedPrograms.MeltType.P4'(C, E, H, G),
        '~sharedPrograms.MeltVariableTyping.P4'(A, D, H, F).
'sharedPrograms.MeltType.P4'('MetaDefs.Par.F2'(A,B), C, D, E) :-
        'sharedPrograms.LookupParDict.P4'(C, 'MetaDefs.Par.F2'(A,B), D, E).
'~sharedPrograms.MeltType.P4'('MetaDefs.Par.F2'(A,B), C, D, E) :-
        '~sharedPrograms.LookupParDict.P4'(C, 'MetaDefs.Par.F2'(A,B), D, E).
'sharedPrograms.MeltType.P4'('MetaDefs.Par.F1'(A), B, C, D) :-
        'sharedPrograms.LookupParDict.P4'(B, 'MetaDefs.Par.F1'(A), C, D).
'~sharedPrograms.MeltType.P4'('MetaDefs.Par.F1'(A), B, C, D) :-
        '~sharedPrograms.LookupParDict.P4'(B, 'MetaDefs.Par.F1'(A), C, D).
'sharedPrograms.MeltType.P4'('MetaDefs.BType.F1'(A), B, B, 'MetaDefs.BType.F1'(A)).
'~sharedPrograms.MeltType.P4'('MetaDefs.BType.F1'(A), B, B, 'MetaDefs.BType.F1'(A)).
'sharedPrograms.MeltType.P4'('MetaDefs.XBType.F1'(A), B, B, 'MetaDefs.XBType.F1'(A)).
'~sharedPrograms.MeltType.P4'('MetaDefs.XBType.F1'(A), B, B, 'MetaDefs.XBType.F1'(A)).
'sharedPrograms.MeltType.P4'('MetaDefs.Type.F2'(A,B), C, D, 'MetaDefs.Type.F2'(A,E)) :-
        'sharedPrograms.MeltTypeList.P4'(B, C, D, E).
'~sharedPrograms.MeltType.P4'('MetaDefs.Type.F2'(A,B), C, D, 'MetaDefs.Type.F2'(A,E)) :-
        '~sharedPrograms.MeltTypeList.P4'(B, C, D, E).
'sharedPrograms.MeltType.P4'('MetaDefs.XType.F2'(A,B), C, D, 'MetaDefs.XType.F2'(A,E)) :-
        'sharedPrograms.MeltTypeList.P4'(B, C, D, E).
'~sharedPrograms.MeltType.P4'('MetaDefs.XType.F2'(A,B), C, D, 'MetaDefs.XType.F2'(A,E)) :-
        '~sharedPrograms.MeltTypeList.P4'(B, C, D, E).
'sharedPrograms.MatchingName.P3'('ProgDefs.BaseDecl.C0', 'MetaDefs.Base.C0', 0).
'~sharedPrograms.MatchingName.P3'('ProgDefs.BaseDecl.C0', 'MetaDefs.Base.C0', 0).
'sharedPrograms.MatchingName.P3'('ProgDefs.ConstructorDecl.F1'(A), 'MetaDefs.Constructor.C0', A).
'~sharedPrograms.MatchingName.P3'('ProgDefs.ConstructorDecl.F1'(A), 'MetaDefs.Constructor.C0', A).
'sharedPrograms.MatchingName.P3'('ProgDefs.ConstantDecl.F1'(_), 'MetaDefs.Constant.C0', 0).
'~sharedPrograms.MatchingName.P3'('ProgDefs.ConstantDecl.F1'(_), 'MetaDefs.Constant.C0', 0).
'sharedPrograms.MatchingName.P3'('ProgDefs.FunctionDecl.F4'(A,_,_,_), 'MetaDefs.Function.C0', A).
'~sharedPrograms.MatchingName.P3'('ProgDefs.FunctionDecl.F4'(A,_,_,_), 'MetaDefs.Function.C0', A).
'sharedPrograms.MatchingName.P3'('ProgDefs.PropositionDecl.C0', 'MetaDefs.Proposition.C0', 0).
'~sharedPrograms.MatchingName.P3'('ProgDefs.PropositionDecl.C0', 'MetaDefs.Proposition.C0', 0).
'sharedPrograms.MatchingName.P3'('ProgDefs.PredicateDecl.F3'(A,_,_), 'MetaDefs.Predicate.C0', A).
'~sharedPrograms.MatchingName.P3'('ProgDefs.PredicateDecl.F3'(A,_,_), 'MetaDefs.Predicate.C0', A).
'sharedPrograms.MeltTypeList.P4'([], A, A, []).
'~sharedPrograms.MeltTypeList.P4'([], A, A, []).
'sharedPrograms.MeltTypeList.P4'([A|B], C, D, [E|F]) :-
        'sharedPrograms.MeltType.P4'(A, C, G, E),
        'sharedPrograms.MeltTypeList.P4'(B, G, D, F).
'~sharedPrograms.MeltTypeList.P4'([A|B], C, D, [E|F]) :-
        '~sharedPrograms.MeltType.P4'(A, C, G, E),
        '~sharedPrograms.MeltTypeList.P4'(B, G, D, F).
'sharedPrograms.MeltedAtomTyping.P8'('MetaDefs.PAtom.F1'(A), B, C, C, 'MetaDefs.PAtom.F1'(A), D, D, []) :-
        'sharedPrograms.PropositionInLanguage.P2'(A, B).
'~sharedPrograms.MeltedAtomTyping.P8'('MetaDefs.PAtom.F1'(A), B, C, C, 'MetaDefs.PAtom.F1'(A), D, D, []) :-
        '~sharedPrograms.PropositionInLanguage.P2'(A, B).
'sharedPrograms.MeltedAtomTyping.P8'('MetaDefs.XPAtom.F1'(A), B, C, C, 'MetaDefs.XPAtom.F1'(A), D, D, []) :-
        'sharedPrograms.PropositionInLanguage.P2'(A, B).
'~sharedPrograms.MeltedAtomTyping.P8'('MetaDefs.XPAtom.F1'(A), B, C, C, 'MetaDefs.XPAtom.F1'(A), D, D, []) :-
        '~sharedPrograms.PropositionInLanguage.P2'(A, B).
'sharedPrograms.MeltedAtomTyping.P8'('MetaDefs.Atom.F2'(A,B), C, D, E, 'MetaDefs.Atom.F2'(A,F), G, H, I) :-
        'sharedPrograms.PredicateInLanguage.P4'(A, C, _, J),
        'sharedPrograms.MeltTypeList.P4'(J, [], _, K),
        'sharedPrograms.MeltedArgumentTyping.P9'(K, B, C, D, E, F, G, H, I).
'~sharedPrograms.MeltedAtomTyping.P8'('MetaDefs.Atom.F2'(A,B), C, D, E, 'MetaDefs.Atom.F2'(A,F), G, H, I) :-
        '~sharedPrograms.PredicateInLanguage.P4'(A, C, _, J),
        '~sharedPrograms.MeltTypeList.P4'(J, [], _, K),
        '~sharedPrograms.MeltedArgumentTyping.P9'(K, B, C, D, E, F, G, H, I).
'sharedPrograms.MeltedAtomTyping.P8'('MetaDefs.XAtom.F2'(A,B), C, D, E, 'MetaDefs.XAtom.F2'(A,F), G, H, I) :-
        'sharedPrograms.PredicateInLanguage.P4'(A, C, _, J),
        'sharedPrograms.MeltTypeList.P4'(J, [], _, K),
        'sharedPrograms.MeltedArgumentTyping.P9'(K, B, C, D, E, F, G, H, I).
'~sharedPrograms.MeltedAtomTyping.P8'('MetaDefs.XAtom.F2'(A,B), C, D, E, 'MetaDefs.XAtom.F2'(A,F), G, H, I) :-
        '~sharedPrograms.PredicateInLanguage.P4'(A, C, _, J),
        '~sharedPrograms.MeltTypeList.P4'(J, [], _, K),
        '~sharedPrograms.MeltedArgumentTyping.P9'(K, B, C, D, E, F, G, H, I).
'sharedPrograms.MeltedArgumentTyping.P9'([], [], _, A, A, [], B, B, []).
'~sharedPrograms.MeltedArgumentTyping.P9'([], [], _, A, A, [], B, B, []).
'sharedPrograms.MeltedArgumentTyping.P9'([A|B], [C|D], E, F, G, [H|I], J, K, L) :-
        'sharedPrograms.MeltedTermType.P9'(C, A, E, F, M, H, J, N, O),
        user:goedel_freeze(ground([O]), (O=[],true->'SharedPrograms':'sharedPrograms.MeltedArgumentTyping.P9'(B,D,E,M,G,I,N,K,L);L=O)).
'~sharedPrograms.MeltedArgumentTyping.P9'([A|B], [C|D], E, F, G, [H|I], J, K, L) :-
        '~sharedPrograms.MeltedTermType.P9'(C, A, E, F, M, H, J, N, O),
        user:goedel_freeze(ground([O]), (O=[],true->'SharedPrograms':'~sharedPrograms.MeltedArgumentTyping.P9'(B,D,E,M,G,I,N,K,L);L=O)).
'sharedPrograms.MeltedBodyTyping.P8'(A, B, C, D, E, F, G, H) :-
        user:goedel_freeze(ground([A]), (A='MetaDefs.Empty.C0',true->D=C,F=G,H=[],E='MetaDefs.Empty.C0';user:goedel_freeze(ground([A]),if((A='MetaDefs.&''.F2'(I,J),true),('SharedPrograms':'sharedPrograms.MeltedBodyTyping.P8'(I,B,C,K,L,F,M,N),user:goedel_freeze(ground([N]),(N=[],true->'SharedPrograms':'sharedPrograms.MeltedBodyTyping.P8'(J,B,K,D,O,M,G,H),E='MetaDefs.&''.F2'(L,O);H=N))),user:goedel_freeze(ground([A]),if((A='MetaDefs.Commit.F2'(P,Q),true),('SharedPrograms':'sharedPrograms.MeltedBodyTyping.P8'(Q,B,C,D,L,F,G,H),E='MetaDefs.Commit.F2'(P,L)),'SharedPrograms':'sharedPrograms.MeltedStandardTyping.P8'(A,B,C,D,E,F,G,H))))))).
'~sharedPrograms.MeltedBodyTyping.P8'(A, B, C, D, E, F, G, H) :-
        user:goedel_freeze(ground([A]), (A='MetaDefs.Empty.C0',true->D=C,F=G,H=[],E='MetaDefs.Empty.C0';user:goedel_freeze(ground([A]),if((A='MetaDefs.&''.F2'(I,J),true),('SharedPrograms':'~sharedPrograms.MeltedBodyTyping.P8'(I,B,C,K,L,F,M,N),user:goedel_freeze(ground([N]),(N=[],true->'SharedPrograms':'~sharedPrograms.MeltedBodyTyping.P8'(J,B,K,D,O,M,G,H),E='MetaDefs.&''.F2'(L,O);H=N))),user:goedel_freeze(ground([A]),if((A='MetaDefs.Commit.F2'(P,Q),true),('SharedPrograms':'~sharedPrograms.MeltedBodyTyping.P8'(Q,B,C,D,L,F,G,H),E='MetaDefs.Commit.F2'(P,L)),'SharedPrograms':'~sharedPrograms.MeltedStandardTyping.P8'(A,B,C,D,E,F,G,H))))))).
'sharedPrograms.MeltedTermType.P9'('MetaDefs.Var.F2'(A,B), C, _, D, E, 'MetaDefs.Var.F2'(A,B), F, F, G) :-
        'sharedPrograms.LookupVarTyping.P4'(D, 'MetaDefs.Var.F2'(A,B), E, H),
        'sharedPrograms.UnifyMeltedTypes.P4'(C, H, 'MetaDefs.Var.F2'(A,B), G).
'~sharedPrograms.MeltedTermType.P9'('MetaDefs.Var.F2'(A,B), C, _, D, E, 'MetaDefs.Var.F2'(A,B), F, F, G) :-
        '~sharedPrograms.LookupVarTyping.P4'(D, 'MetaDefs.Var.F2'(A,B), E, H),
        '~sharedPrograms.UnifyMeltedTypes.P4'(C, H, 'MetaDefs.Var.F2'(A,B), G).
'sharedPrograms.MeltedTermType.P9'('MetaDefs.Var.F1'(A), B, _, C, D, 'MetaDefs.Var.F1'(A), E, E, F) :-
        'sharedPrograms.LookupVarTyping.P4'(C, 'MetaDefs.Var.F1'(A), D, G),
        'sharedPrograms.UnifyMeltedTypes.P4'(B, G, 'MetaDefs.Var.F1'(A), F).
'~sharedPrograms.MeltedTermType.P9'('MetaDefs.Var.F1'(A), B, _, C, D, 'MetaDefs.Var.F1'(A), E, E, F) :-
        '~sharedPrograms.LookupVarTyping.P4'(C, 'MetaDefs.Var.F1'(A), D, G),
        '~sharedPrograms.UnifyMeltedTypes.P4'(B, G, 'MetaDefs.Var.F1'(A), F).
'sharedPrograms.MeltedTermType.P9'('MetaDefs.CTerm.F1'(A), B, C, D, D, 'MetaDefs.CTerm.F1'(A), E, E, F) :-
        'sharedPrograms.ConstantInLanguage.P3'(A, C, G),
        'sharedPrograms.MeltType.P4'(G, [], _, H),
        'sharedPrograms.UnifyMeltedTypes.P4'(B, H, 'MetaDefs.CTerm.F1'(A), F).
'~sharedPrograms.MeltedTermType.P9'('MetaDefs.CTerm.F1'(A), B, C, D, D, 'MetaDefs.CTerm.F1'(A), E, E, F) :-
        '~sharedPrograms.ConstantInLanguage.P3'(A, C, G),
        '~sharedPrograms.MeltType.P4'(G, [], _, H),
        '~sharedPrograms.UnifyMeltedTypes.P4'(B, H, 'MetaDefs.CTerm.F1'(A), F).
'sharedPrograms.MeltedTermType.P9'('MetaDefs.XCTerm.F2'(A,_), B, C, D, D, 'MetaDefs.XCTerm.F2'(A,E), F, F, G) :-
        'sharedPrograms.ConstantInLanguage.P3'(A, C, H),
        'sharedPrograms.MeltType.P4'(H, [], _, E),
        'sharedPrograms.UnifyMeltedTypes.P4'(B, E, 'MetaDefs.CTerm.F1'(A), G).
'~sharedPrograms.MeltedTermType.P9'('MetaDefs.XCTerm.F2'(A,_), B, C, D, D, 'MetaDefs.XCTerm.F2'(A,E), F, F, G) :-
        '~sharedPrograms.ConstantInLanguage.P3'(A, C, H),
        '~sharedPrograms.MeltType.P4'(H, [], _, E),
        '~sharedPrograms.UnifyMeltedTypes.P4'(B, E, 'MetaDefs.CTerm.F1'(A), G).
'sharedPrograms.MeltedTermType.P9'('MetaDefs.Term.F2'(A,B), C, D, E, F, 'MetaDefs.Term.F2'(A,G), H, I, J) :-
        'sharedPrograms.FunctionInLanguage.P5'(A, D, _, K, L),
        'sharedPrograms.MeltType.P4'(L, [], M, N),
        'sharedPrograms.MeltTypeList.P4'(K, M, _, O),
        'sharedPrograms.UnifyMeltedTypes.P4'(C, N, 'MetaDefs.Term.F2'(A,B), P),
        user:goedel_freeze(ground([P]), (P=[],true->'SharedPrograms':'sharedPrograms.MeltedArgumentTyping.P9'(O,B,D,E,F,G,H,I,J);J=P)).
'~sharedPrograms.MeltedTermType.P9'('MetaDefs.Term.F2'(A,B), C, D, E, F, 'MetaDefs.Term.F2'(A,G), H, I, J) :-
        '~sharedPrograms.FunctionInLanguage.P5'(A, D, _, K, L),
        '~sharedPrograms.MeltType.P4'(L, [], M, N),
        '~sharedPrograms.MeltTypeList.P4'(K, M, _, O),
        '~sharedPrograms.UnifyMeltedTypes.P4'(C, N, 'MetaDefs.Term.F2'(A,B), P),
        user:goedel_freeze(ground([P]), (P=[],true->'SharedPrograms':'~sharedPrograms.MeltedArgumentTyping.P9'(O,B,D,E,F,G,H,I,J);J=P)).
'sharedPrograms.MeltedTermType.P9'('MetaDefs.XTerm.F3'(A,B,_), C, D, E, F, 'MetaDefs.XTerm.F3'(A,G,H), I, J, K) :-
        'sharedPrograms.FunctionInLanguage.P5'(A, D, _, L, M),
        'sharedPrograms.MeltType.P4'(M, [], N, H),
        'sharedPrograms.MeltTypeList.P4'(L, N, _, O),
        'sharedPrograms.UnifyMeltedTypes.P4'(C, H, 'MetaDefs.Term.F2'(A,B), P),
        user:goedel_freeze(ground([P]), (P=[],true->'SharedPrograms':'sharedPrograms.MeltedArgumentTyping.P9'(O,B,D,E,F,G,I,J,K);K=P)).
'~sharedPrograms.MeltedTermType.P9'('MetaDefs.XTerm.F3'(A,B,_), C, D, E, F, 'MetaDefs.XTerm.F3'(A,G,H), I, J, K) :-
        '~sharedPrograms.FunctionInLanguage.P5'(A, D, _, L, M),
        '~sharedPrograms.MeltType.P4'(M, [], N, H),
        '~sharedPrograms.MeltTypeList.P4'(L, N, _, O),
        '~sharedPrograms.UnifyMeltedTypes.P4'(C, H, 'MetaDefs.Term.F2'(A,B), P),
        user:goedel_freeze(ground([P]), (P=[],true->'SharedPrograms':'~sharedPrograms.MeltedArgumentTyping.P9'(O,B,D,E,F,G,I,J,K);K=P)).
'sharedPrograms.MeltedTermType.P9'('MetaDefs.Int.F1'(A), B, C, D, D, 'MetaDefs.Int.F1'(A), E, E, F) :-
        G='MetaDefs.Name.F4'('"Integers','"Integer','MetaDefs.Base.C0',0),
        'sharedPrograms.BaseInLanguage.P2'(G, C),
        'sharedPrograms.UnifyMeltedTypes.P4'(B, 'MetaDefs.BType.F1'(G), 'MetaDefs.Int.F1'(A), F).
'~sharedPrograms.MeltedTermType.P9'('MetaDefs.Int.F1'(A), B, C, D, D, 'MetaDefs.Int.F1'(A), E, E, F) :-
        G='MetaDefs.Name.F4'('"Integers','"Integer','MetaDefs.Base.C0',0),
        '~sharedPrograms.BaseInLanguage.P2'(G, C),
        '~sharedPrograms.UnifyMeltedTypes.P4'(B, 'MetaDefs.BType.F1'(G), 'MetaDefs.Int.F1'(A), F).
'sharedPrograms.MeltedTermType.P9'('MetaDefs.Str.F1'(A), B, C, D, D, 'MetaDefs.Str.F1'(A), E, E, F) :-
        G='MetaDefs.Name.F4'('"Strings','"String','MetaDefs.Base.C0',0),
        'sharedPrograms.BaseInLanguage.P2'(G, C),
        'sharedPrograms.UnifyMeltedTypes.P4'(B, 'MetaDefs.BType.F1'(G), 'MetaDefs.Str.F1'(A), F).
'~sharedPrograms.MeltedTermType.P9'('MetaDefs.Str.F1'(A), B, C, D, D, 'MetaDefs.Str.F1'(A), E, E, F) :-
        G='MetaDefs.Name.F4'('"Strings','"String','MetaDefs.Base.C0',0),
        '~sharedPrograms.BaseInLanguage.P2'(G, C),
        '~sharedPrograms.UnifyMeltedTypes.P4'(B, 'MetaDefs.BType.F1'(G), 'MetaDefs.Str.F1'(A), F).
'sharedPrograms.MeltedTermType.P9'('MetaDefs.Prm.F1'(A), B, C, D, D, 'MetaDefs.Prm.F1'(A), E, E, F) :-
        G='MetaDefs.Name.F4'('"ProgDefs','"Program','MetaDefs.Base.C0',0),
        'sharedPrograms.BaseInLanguage.P2'(G, C),
        'sharedPrograms.UnifyMeltedTypes.P4'(B, 'MetaDefs.BType.F1'(G), 'MetaDefs.Prm.F1'(A), F).
'~sharedPrograms.MeltedTermType.P9'('MetaDefs.Prm.F1'(A), B, C, D, D, 'MetaDefs.Prm.F1'(A), E, E, F) :-
        G='MetaDefs.Name.F4'('"ProgDefs','"Program','MetaDefs.Base.C0',0),
        '~sharedPrograms.BaseInLanguage.P2'(G, C),
        '~sharedPrograms.UnifyMeltedTypes.P4'(B, 'MetaDefs.BType.F1'(G), 'MetaDefs.Prm.F1'(A), F).
'sharedPrograms.MeltedTermType.P9'('MetaDefs.SuchThat.F2'(A,B), C, D, E, F, 'MetaDefs.SuchThat.F2'(G,H), I, J, K) :-
        L='MetaDefs.Name.F4'('"Sets','"Set','MetaDefs.Constructor.C0',1),
        'sharedPrograms.ConstructorInLanguage.P3'(L, D, _),
        'sharedPrograms.UnifyMeltedTypes.P4'(C, 'MetaDefs.Type.F2'(L,[M]), 'MetaDefs.SuchThat.F2'(A,B), N),
        user:goedel_freeze(ground([N]), (N=[],true->'SharedSyntax':'SharedSyntax.STermFreeVars.P2'(A,O),'SharedPrograms':'sharedPrograms.DivideBindings.P4'(O,E,P,Q),'SharedPrograms':'sharedPrograms.MeltedStandardTyping.P8'(B,D,P,R,H,I,S,T),user:goedel_freeze(ground([T]),(T=[],true->'SharedPrograms':'sharedPrograms.MeltedTermType.P9'(A,M,D,R,U,G,S,J,K),user:goedel_freeze(ground([K]),(K=[],true->'SharedPrograms':'sharedPrograms.DivideBindings.P4'(O,U,V,_),'Lists':'Lists.Append.P3'(Q,V,F);true));K=T));K=N)).
'~sharedPrograms.MeltedTermType.P9'('MetaDefs.SuchThat.F2'(A,B), C, D, E, F, 'MetaDefs.SuchThat.F2'(G,H), I, J, K) :-
        L='MetaDefs.Name.F4'('"Sets','"Set','MetaDefs.Constructor.C0',1),
        '~sharedPrograms.ConstructorInLanguage.P3'(L, D, _),
        '~sharedPrograms.UnifyMeltedTypes.P4'(C, 'MetaDefs.Type.F2'(L,[M]), 'MetaDefs.SuchThat.F2'(A,B), N),
        user:goedel_freeze(ground([N]), (N=[],true->'SharedSyntax':'~SharedSyntax.STermFreeVars.P2'(A,O),'SharedPrograms':'~sharedPrograms.DivideBindings.P4'(O,E,P,Q),'SharedPrograms':'~sharedPrograms.MeltedStandardTyping.P8'(B,D,P,R,H,I,S,T),user:goedel_freeze(ground([T]),(T=[],true->'SharedPrograms':'~sharedPrograms.MeltedTermType.P9'(A,M,D,R,U,G,S,J,K),user:goedel_freeze(ground([K]),(K=[],true->'SharedPrograms':'~sharedPrograms.DivideBindings.P4'(O,U,V,_),'Lists':'~Lists.Append.P3'(Q,V,F);true));K=T));K=N)).
'sharedPrograms.MeltedTermType.P9'('MetaDefs.Num.F1'(A), B, C, D, D, E, F, G, H) :-
        user:goedel_freeze(ground([C]), ('SharedPrograms':'~sharedPrograms.BaseInLanguage.P2'('MetaDefs.Name.F4'('"Rationals','"Rational','MetaDefs.Base.C0',0),C),true->F=['sharedPrograms.NumType.F3'(A,'MetaDefs.BType.F1'(I),E)|G],'SharedPrograms':'sharedPrograms.UnifyMeltedTypes.P4'(B,'MetaDefs.BType.F1'(I),'MetaDefs.Num.F1'(A),H);'SharedPrograms':'sharedPrograms.MeltedTermType.P9'('MetaDefs.Int.F1'(A),B,C,D,_,E,F,G,H))).
'~sharedPrograms.MeltedTermType.P9'('MetaDefs.Num.F1'(A), B, C, D, D, E, F, G, H) :-
        user:goedel_freeze(ground([C]), ('SharedPrograms':'~sharedPrograms.BaseInLanguage.P2'('MetaDefs.Name.F4'('"Rationals','"Rational','MetaDefs.Base.C0',0),C),true->F=['sharedPrograms.NumType.F3'(A,'MetaDefs.BType.F1'(I),E)|G],'SharedPrograms':'~sharedPrograms.UnifyMeltedTypes.P4'(B,'MetaDefs.BType.F1'(I),'MetaDefs.Num.F1'(A),H);'SharedPrograms':'~sharedPrograms.MeltedTermType.P9'('MetaDefs.Int.F1'(A),B,C,D,_,E,F,G,H))).
'sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.ISTE.F4'(A,B,C,D), E, F, G, 'MetaDefs.ISTE.F4'(A,H,I,J), K, L, M) :-
        'sharedPrograms.DivideBindings.P4'(A, F, N, O),
        'sharedPrograms.MeltedStandardTyping.P8'(B, E, N, P, H, K, Q, R),
        user:goedel_freeze(ground([R]), (R=[],true->'SharedPrograms':'sharedPrograms.MeltedStandardTyping.P8'(C,E,P,S,I,Q,T,U),user:goedel_freeze(ground([U]),(U=[],true->'SharedPrograms':'sharedPrograms.DivideBindings.P4'(A,S,V,_),'Lists':'Lists.Append.P3'(O,V,W),'SharedPrograms':'sharedPrograms.MeltedStandardTyping.P8'(D,E,W,G,J,T,L,M);M=U));M=R)).
'~sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.ISTE.F4'(A,B,C,D), E, F, G, 'MetaDefs.ISTE.F4'(A,H,I,J), K, L, M) :-
        '~sharedPrograms.DivideBindings.P4'(A, F, N, O),
        '~sharedPrograms.MeltedStandardTyping.P8'(B, E, N, P, H, K, Q, R),
        user:goedel_freeze(ground([R]), (R=[],true->'SharedPrograms':'~sharedPrograms.MeltedStandardTyping.P8'(C,E,P,S,I,Q,T,U),user:goedel_freeze(ground([U]),(U=[],true->'SharedPrograms':'~sharedPrograms.DivideBindings.P4'(A,S,V,_),'Lists':'~Lists.Append.P3'(O,V,W),'SharedPrograms':'~sharedPrograms.MeltedStandardTyping.P8'(D,E,W,G,J,T,L,M);M=U));M=R)).
'sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.IST.F3'(A,B,C), D, E, F, 'MetaDefs.IST.F3'(A,G,H), I, J, K) :-
        'sharedPrograms.DivideBindings.P4'(A, E, L, M),
        'sharedPrograms.MeltedStandardTyping.P8'(B, D, L, N, G, I, O, P),
        user:goedel_freeze(ground([P]), (P=[],true->'SharedPrograms':'sharedPrograms.MeltedStandardTyping.P8'(C,D,N,Q,H,O,J,K),user:goedel_freeze(ground([K]),(K=[],true->'SharedPrograms':'sharedPrograms.DivideBindings.P4'(A,Q,R,_),'Lists':'Lists.Append.P3'(M,R,F);true));K=P)).
'~sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.IST.F3'(A,B,C), D, E, F, 'MetaDefs.IST.F3'(A,G,H), I, J, K) :-
        '~sharedPrograms.DivideBindings.P4'(A, E, L, M),
        '~sharedPrograms.MeltedStandardTyping.P8'(B, D, L, N, G, I, O, P),
        user:goedel_freeze(ground([P]), (P=[],true->'SharedPrograms':'~sharedPrograms.MeltedStandardTyping.P8'(C,D,N,Q,H,O,J,K),user:goedel_freeze(ground([K]),(K=[],true->'SharedPrograms':'~sharedPrograms.DivideBindings.P4'(A,Q,R,_),'Lists':'~Lists.Append.P3'(M,R,F);true));K=P)).
'sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.ITE.F3'(A,B,C), D, E, F, 'MetaDefs.ITE.F3'(G,H,I), J, K, L) :-
        'sharedPrograms.MeltedStandardTyping.P8'(A, D, E, M, G, J, N, O),
        user:goedel_freeze(ground([O]), (O=[],true->'SharedPrograms':'sharedPrograms.MeltedStandardTyping.P8'(B,D,M,P,H,N,Q,R),user:goedel_freeze(ground([R]),(R=[],true->'SharedPrograms':'sharedPrograms.MeltedStandardTyping.P8'(C,D,P,F,I,Q,K,L);L=R));L=O)).
'~sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.ITE.F3'(A,B,C), D, E, F, 'MetaDefs.ITE.F3'(G,H,I), J, K, L) :-
        '~sharedPrograms.MeltedStandardTyping.P8'(A, D, E, M, G, J, N, O),
        user:goedel_freeze(ground([O]), (O=[],true->'SharedPrograms':'~sharedPrograms.MeltedStandardTyping.P8'(B,D,M,P,H,N,Q,R),user:goedel_freeze(ground([R]),(R=[],true->'SharedPrograms':'~sharedPrograms.MeltedStandardTyping.P8'(C,D,P,F,I,Q,K,L);L=R));L=O)).
'sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.IT.F2'(A,B), C, D, E, 'MetaDefs.IT.F2'(F,G), H, I, J) :-
        'sharedPrograms.MeltedStandardTyping.P8'(A, C, D, K, F, H, L, M),
        user:goedel_freeze(ground([M]), (M=[],true->'SharedPrograms':'sharedPrograms.MeltedStandardTyping.P8'(B,C,K,E,G,L,I,J);J=M)).
'~sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.IT.F2'(A,B), C, D, E, 'MetaDefs.IT.F2'(F,G), H, I, J) :-
        '~sharedPrograms.MeltedStandardTyping.P8'(A, C, D, K, F, H, L, M),
        user:goedel_freeze(ground([M]), (M=[],true->'SharedPrograms':'~sharedPrograms.MeltedStandardTyping.P8'(B,C,K,E,G,L,I,J);J=M)).
'sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.&''.F2'(A,B), C, D, E, 'MetaDefs.&''.F2'(F,G), H, I, J) :-
        'sharedPrograms.MeltedStandardTyping.P8'(A, C, D, K, F, H, L, M),
        user:goedel_freeze(ground([M]), (M=[],true->'SharedPrograms':'sharedPrograms.MeltedStandardTyping.P8'(B,C,K,E,G,L,I,J);J=M)).
'~sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.&''.F2'(A,B), C, D, E, 'MetaDefs.&''.F2'(F,G), H, I, J) :-
        '~sharedPrograms.MeltedStandardTyping.P8'(A, C, D, K, F, H, L, M),
        user:goedel_freeze(ground([M]), (M=[],true->'SharedPrograms':'~sharedPrograms.MeltedStandardTyping.P8'(B,C,K,E,G,L,I,J);J=M)).
'sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.\\/''.F2'(A,B), C, D, E, 'MetaDefs.\\/''.F2'(F,G), H, I, J) :- % added 2 \ djd
        'sharedPrograms.MeltedStandardTyping.P8'(A, C, D, K, F, H, L, M),
        user:goedel_freeze(ground([M]), (M=[],true->'SharedPrograms':'sharedPrograms.MeltedStandardTyping.P8'(B,C,K,E,G,L,I,J);J=M)).
'~sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.\\/''.F2'(A,B), C, D, E, 'MetaDefs.\\/''.F2'(F,G), H, I, J) :- % added 2 \ djd
        '~sharedPrograms.MeltedStandardTyping.P8'(A, C, D, K, F, H, L, M),
        user:goedel_freeze(ground([M]), (M=[],true->'SharedPrograms':'~sharedPrograms.MeltedStandardTyping.P8'(B,C,K,E,G,L,I,J);J=M)).
'sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.->''.F2'(A,B), C, D, E, 'MetaDefs.->''.F2'(F,G), H, I, J) :-
        'sharedPrograms.MeltedStandardTyping.P8'(A, C, D, K, F, H, L, M),
        user:goedel_freeze(ground([M]), (M=[],true->'SharedPrograms':'sharedPrograms.MeltedStandardTyping.P8'(B,C,K,E,G,L,I,J);J=M)).
'~sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.->''.F2'(A,B), C, D, E, 'MetaDefs.->''.F2'(F,G), H, I, J) :-
        '~sharedPrograms.MeltedStandardTyping.P8'(A, C, D, K, F, H, L, M),
        user:goedel_freeze(ground([M]), (M=[],true->'SharedPrograms':'~sharedPrograms.MeltedStandardTyping.P8'(B,C,K,E,G,L,I,J);J=M)).
'sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.<-''.F2'(A,B), C, D, E, 'MetaDefs.<-''.F2'(F,G), H, I, J) :-
        'sharedPrograms.MeltedStandardTyping.P8'(A, C, D, K, F, H, L, M),
        user:goedel_freeze(ground([M]), (M=[],true->'SharedPrograms':'sharedPrograms.MeltedStandardTyping.P8'(B,C,K,E,G,L,I,J);J=M)).
'~sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.<-''.F2'(A,B), C, D, E, 'MetaDefs.<-''.F2'(F,G), H, I, J) :-
        '~sharedPrograms.MeltedStandardTyping.P8'(A, C, D, K, F, H, L, M),
        user:goedel_freeze(ground([M]), (M=[],true->'SharedPrograms':'~sharedPrograms.MeltedStandardTyping.P8'(B,C,K,E,G,L,I,J);J=M)).
'sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.<->''.F2'(A,B), C, D, E, 'MetaDefs.<->''.F2'(F,G), H, I, J) :-
        'sharedPrograms.MeltedStandardTyping.P8'(A, C, D, K, F, H, L, M),
        user:goedel_freeze(ground([M]), (M=[],true->'SharedPrograms':'sharedPrograms.MeltedStandardTyping.P8'(B,C,K,E,G,L,I,J);J=M)).
'~sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.<->''.F2'(A,B), C, D, E, 'MetaDefs.<->''.F2'(F,G), H, I, J) :-
        '~sharedPrograms.MeltedStandardTyping.P8'(A, C, D, K, F, H, L, M),
        user:goedel_freeze(ground([M]), (M=[],true->'SharedPrograms':'~sharedPrograms.MeltedStandardTyping.P8'(B,C,K,E,G,L,I,J);J=M)).
'sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.~''.F1'(A), B, C, D, 'MetaDefs.~''.F1'(E), F, G, H) :-
        'sharedPrograms.MeltedStandardTyping.P8'(A, B, C, D, E, F, G, H).
'~sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.~''.F1'(A), B, C, D, 'MetaDefs.~''.F1'(E), F, G, H) :-
        '~sharedPrograms.MeltedStandardTyping.P8'(A, B, C, D, E, F, G, H).
'sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.All.F2'(A,B), C, D, E, 'MetaDefs.All.F2'(A,F), G, H, I) :-
        'sharedPrograms.DivideBindings.P4'(A, D, J, K),
        'sharedPrograms.MeltedStandardTyping.P8'(B, C, J, L, F, G, H, I),
        'sharedPrograms.DivideBindings.P4'(A, L, M, _),
        'Lists':'Lists.Append.P3'(K, M, E).
'~sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.All.F2'(A,B), C, D, E, 'MetaDefs.All.F2'(A,F), G, H, I) :-
        '~sharedPrograms.DivideBindings.P4'(A, D, J, K),
        '~sharedPrograms.MeltedStandardTyping.P8'(B, C, J, L, F, G, H, I),
        '~sharedPrograms.DivideBindings.P4'(A, L, M, _),
        'Lists':'~Lists.Append.P3'(K, M, E).
'sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.Some.F2'(A,B), C, D, E, 'MetaDefs.Some.F2'(A,F), G, H, I) :-
        'sharedPrograms.DivideBindings.P4'(A, D, J, K),
        'sharedPrograms.MeltedStandardTyping.P8'(B, C, J, L, F, G, H, I),
        'sharedPrograms.DivideBindings.P4'(A, L, M, _),
        'Lists':'Lists.Append.P3'(K, M, E).
'~sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.Some.F2'(A,B), C, D, E, 'MetaDefs.Some.F2'(A,F), G, H, I) :-
        '~sharedPrograms.DivideBindings.P4'(A, D, J, K),
        '~sharedPrograms.MeltedStandardTyping.P8'(B, C, J, L, F, G, H, I),
        '~sharedPrograms.DivideBindings.P4'(A, L, M, _),
        'Lists':'~Lists.Append.P3'(K, M, E).
'sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.PAtom.F1'(A), B, C, D, E, F, G, H) :-
        'sharedPrograms.MeltedAtomTyping.P8'('MetaDefs.PAtom.F1'(A), B, C, D, E, F, G, H).
'~sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.PAtom.F1'(A), B, C, D, E, F, G, H) :-
        '~sharedPrograms.MeltedAtomTyping.P8'('MetaDefs.PAtom.F1'(A), B, C, D, E, F, G, H).
'sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.Atom.F2'(A,B), C, D, E, F, G, H, I) :-
        'sharedPrograms.MeltedAtomTyping.P8'('MetaDefs.Atom.F2'(A,B), C, D, E, F, G, H, I).
'~sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.Atom.F2'(A,B), C, D, E, F, G, H, I) :-
        '~sharedPrograms.MeltedAtomTyping.P8'('MetaDefs.Atom.F2'(A,B), C, D, E, F, G, H, I).
'sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.XPAtom.F1'(A), B, C, D, E, F, G, H) :-
        'sharedPrograms.MeltedAtomTyping.P8'('MetaDefs.XPAtom.F1'(A), B, C, D, E, F, G, H).
'~sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.XPAtom.F1'(A), B, C, D, E, F, G, H) :-
        '~sharedPrograms.MeltedAtomTyping.P8'('MetaDefs.XPAtom.F1'(A), B, C, D, E, F, G, H).
'sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.XAtom.F2'(A,B), C, D, E, F, G, H, I) :-
        'sharedPrograms.MeltedAtomTyping.P8'('MetaDefs.XAtom.F2'(A,B), C, D, E, F, G, H, I).
'~sharedPrograms.MeltedStandardTyping.P8'('MetaDefs.XAtom.F2'(A,B), C, D, E, F, G, H, I) :-
        '~sharedPrograms.MeltedAtomTyping.P8'('MetaDefs.XAtom.F2'(A,B), C, D, E, F, G, H, I).
'sharedPrograms.ModuleLanguage.P3'('ProgDefs.Program.F4'(_,A,'ProgDefs.Language.F1'(B),_), C, 'ProgDefs.Language.F1'(D)) :-
        'sharedPrograms.EmptyLanguage.P1'('ProgDefs.Language.F1'(E)),
        'AVLTrees':'AVLTrees.AVLSearch.P3'(A, C, 'ProgDefs.ModDef.F4'(F,G,H,I)),
        user:goedel_freeze(ground([F]), (F='ProgDefs.ClosedKind.C0',true->'SharedPrograms':'sharedPrograms.ImportedLanguage.P6'([C],A,B,[],E,D);user:goedel_freeze(ground([B,C]),if(('AVLTrees':'~AVLTrees.AVLSearch.P3'(B,C,J),true),'AVLTrees':'AVLTrees.AVLInsert.P4'(E,C,J,K),K=E)),'Lists':'Lists.Append.P3'(G,H,L),'Lists':'Lists.Append.P3'(I,L,M),'SharedPrograms':'sharedPrograms.ImportedLanguage.P6'(M,A,B,[C],K,D))).
'~sharedPrograms.ModuleLanguage.P3'('ProgDefs.Program.F4'(_,A,'ProgDefs.Language.F1'(B),_), C, 'ProgDefs.Language.F1'(D)) :-
        '~sharedPrograms.EmptyLanguage.P1'('ProgDefs.Language.F1'(E)),
        'AVLTrees':'~AVLTrees.AVLSearch.P3'(A, C, 'ProgDefs.ModDef.F4'(F,G,H,I)),
        user:goedel_freeze(ground([F]), (F='ProgDefs.ClosedKind.C0',true->'SharedPrograms':'~sharedPrograms.ImportedLanguage.P6'([C],A,B,[],E,D);user:goedel_freeze(ground([B,C]),if(('AVLTrees':'~AVLTrees.AVLSearch.P3'(B,C,J),true),'AVLTrees':'~AVLTrees.AVLInsert.P4'(E,C,J,K),K=E)),'Lists':'~Lists.Append.P3'(G,H,L),'Lists':'~Lists.Append.P3'(I,L,M),'SharedPrograms':'~sharedPrograms.ImportedLanguage.P6'(M,A,B,[C],K,D))).
'sharedPrograms.SymbolInLanguage.P3'('MetaDefs.Name.F4'(A,B,C,D), 'ProgDefs.Language.F1'(E), F) :-
        'sharedPrograms.AVLFind.P3'(E, A, 'ProgDefs.Module.F3'(G,'ProgDefs.Categories.F2'(_,H),_)),
        'sharedPrograms.AVLFind.P3'(H, B, I),
        'sharedPrograms.FindDescriptor.P5'(I, G, C, D, F).
'~sharedPrograms.SymbolInLanguage.P3'('MetaDefs.Name.F4'(A,B,C,D), 'ProgDefs.Language.F1'(E), F) :-
        '~sharedPrograms.AVLFind.P3'(E, A, 'ProgDefs.Module.F3'(G,'ProgDefs.Categories.F2'(_,H),_)),
        '~sharedPrograms.AVLFind.P3'(H, B, I),
        '~sharedPrograms.FindDescriptor.P5'(I, G, C, D, F).
'sharedPrograms.SControlInProgram.P5'('ProgDefs.Program.F4'(_,A,'ProgDefs.Language.F1'(B),C), D, E, F, G) :-
        E='MetaDefs.Name.F4'(D,H,_,I),
        'sharedPrograms.AVLFind.P3'(B, D, 'ProgDefs.Module.F3'(_,'ProgDefs.Categories.F2'(_,J),_)),
        'sharedPrograms.AVLFind.P3'(J, H, K),
        user:goedel_freeze(ground([D]), (D='"',true->L='ProgDefs.ClosedKind.C0',M='ProgDefs.Exported.C0';'AVLTrees':'AVLTrees.AVLSearch.P3'(A,D,'ProgDefs.ModDef.F4'(L,_,_,_)),user:goedel_freeze(ground([L]),(L='ProgDefs.ClosedKind.C0',true->M='ProgDefs.Exported.C0';M='ProgDefs.Hidden.C0')))),
        'sharedPrograms.FindDescriptor.P5'(K, M, _, I, 'ProgDefs.PredicateDecl.F3'(_,_,_)),
        user:goedel_freeze(ground([I,C,D,H]), if((('AVLTrees':'~AVLTrees.AVLSearch.P3'(C,D,'ProgDefs.Code.F2'(_,N)),'AVLTrees':'~AVLTrees.AVLSearch.P3'(N,H,O),'SharedPrograms':'~sharedPrograms.FindPredDef.P3'(I,O,'ProgDefs.PredDef.F4'(I,_,P,Q))),true),(user:goedel_freeze(ground([L]),(L='ProgDefs.ClosedKind.C0',true->R=P;'Lists':'Lists.Append.P3'(P,Q,R))),'SharedPrograms':'sharedPrograms.ReformatDelays.P3'(R,F,G)),(F=[],G=[]))).
'~sharedPrograms.SControlInProgram.P5'('ProgDefs.Program.F4'(_,A,'ProgDefs.Language.F1'(B),C), D, E, F, G) :-
        E='MetaDefs.Name.F4'(D,H,_,I),
        '~sharedPrograms.AVLFind.P3'(B, D, 'ProgDefs.Module.F3'(_,'ProgDefs.Categories.F2'(_,J),_)),
        '~sharedPrograms.AVLFind.P3'(J, H, K),
        user:goedel_freeze(ground([D]), (D='"',true->L='ProgDefs.ClosedKind.C0',M='ProgDefs.Exported.C0';'AVLTrees':'~AVLTrees.AVLSearch.P3'(A,D,'ProgDefs.ModDef.F4'(L,_,_,_)),user:goedel_freeze(ground([L]),(L='ProgDefs.ClosedKind.C0',true->M='ProgDefs.Exported.C0';M='ProgDefs.Hidden.C0')))),
        '~sharedPrograms.FindDescriptor.P5'(K, M, _, I, 'ProgDefs.PredicateDecl.F3'(_,_,_)),
        user:goedel_freeze(ground([I,C,D,H]), if((('AVLTrees':'~AVLTrees.AVLSearch.P3'(C,D,'ProgDefs.Code.F2'(_,N)),'AVLTrees':'~AVLTrees.AVLSearch.P3'(N,H,O),'SharedPrograms':'~sharedPrograms.FindPredDef.P3'(I,O,'ProgDefs.PredDef.F4'(I,_,P,Q))),true),(user:goedel_freeze(ground([L]),(L='ProgDefs.ClosedKind.C0',true->R=P;'Lists':'~Lists.Append.P3'(P,Q,R))),'SharedPrograms':'~sharedPrograms.ReformatDelays.P3'(R,F,G)),(F=[],G=[]))).
'sharedPrograms.ProgramSkeleton.P4'(A, B, C, 'ProgDefs.Program.F4'(A,D,E,F)) :-
        'AVLTrees':'AVLTrees.AVLIsEmpty.P1'(G),
        'AVLTrees':'AVLTrees.AVLIsEmpty.P1'(H),
        'AVLTrees':'AVLTrees.AVLIsEmpty.P1'(I),
        'AVLTrees':'AVLTrees.AVLInsert.P4'(G, A, 'ProgDefs.ModDef.F4'(B,[],[],[]), D),
        'AVLTrees':'AVLTrees.AVLInsert.P4'(H, A, 'ProgDefs.Code.F2'(C,I), F),
        'sharedPrograms.EmptyLanguage.P1'(E).
'~sharedPrograms.ProgramSkeleton.P4'(A, B, C, 'ProgDefs.Program.F4'(A,D,E,F)) :-
        'AVLTrees':'~AVLTrees.AVLIsEmpty.P1'(G),
        'AVLTrees':'~AVLTrees.AVLIsEmpty.P1'(H),
        'AVLTrees':'~AVLTrees.AVLIsEmpty.P1'(I),
        'AVLTrees':'~AVLTrees.AVLInsert.P4'(G, A, 'ProgDefs.ModDef.F4'(B,[],[],[]), D),
        'AVLTrees':'~AVLTrees.AVLInsert.P4'(H, A, 'ProgDefs.Code.F2'(C,I), F),
        '~sharedPrograms.EmptyLanguage.P1'(E).
'sharedPrograms.OpenModuleAux.P2'(A, B) :-
        'sharedPrograms.AVLFind.P3'(A, B, 'ProgDefs.ModDef.F4'(C,_,_,_)),
        'sharedPrograms.OpenKind.P1'(C).
'~sharedPrograms.OpenModuleAux.P2'(A, B) :-
        '~sharedPrograms.AVLFind.P3'(A, B, 'ProgDefs.ModDef.F4'(C,_,_,_)),
        '~sharedPrograms.OpenKind.P1'(C).
'sharedPrograms.OpenKind.P1'('ProgDefs.NormalKind.C0').
'~sharedPrograms.OpenKind.P1'('ProgDefs.NormalKind.C0').
'sharedPrograms.OpenKind.P1'('ProgDefs.ModuleKind.C0').
'~sharedPrograms.OpenKind.P1'('ProgDefs.ModuleKind.C0').
'sharedPrograms.MustBracketThen.P1'('MetaDefs.ITE.F3'(_,_,_)).
'~sharedPrograms.MustBracketThen.P1'('MetaDefs.ITE.F3'(_,_,_)).
'sharedPrograms.MustBracketThen.P1'('MetaDefs.ISTE.F4'(_,_,_,_)).
'~sharedPrograms.MustBracketThen.P1'('MetaDefs.ISTE.F4'(_,_,_,_)).
'sharedPrograms.MustBracketThen.P1'('MetaDefs.&''.F2'(A,B)) :-
        'sharedPrograms.ContainsConditional.P1'('MetaDefs.&''.F2'(A,B)).
'~sharedPrograms.MustBracketThen.P1'('MetaDefs.&''.F2'(A,B)) :-
        '~sharedPrograms.ContainsConditional.P1'('MetaDefs.&''.F2'(A,B)).
'sharedPrograms.PredicateInLanguage.P4'(A, B, C, D) :-
        'sharedPrograms.SymbolInLanguage.P3'(A, B, 'ProgDefs.PredicateDecl.F3'(_,C,D)).
'~sharedPrograms.PredicateInLanguage.P4'(A, B, C, D) :-
        '~sharedPrograms.SymbolInLanguage.P3'(A, B, 'ProgDefs.PredicateDecl.F3'(_,C,D)).
'sharedPrograms.OrSeqToIntDL.P3'('ProgDefs.Or.F2'(A,B), C, D) :-
        'sharedPrograms.SimpleCondToIntDL.P3'(A, C, E),
        'Strings':'Strings.StringInts.P2'('" \\/ ', F), % added \ djd
        'Lists':'Lists.Append.P3'(F, G, E),
        user:goedel_freeze(ground([B]), (B='ProgDefs.Or.F2'(_,_),true->'SharedPrograms':'sharedPrograms.OrSeqToIntDL.P3'(B,G,D);'SharedPrograms':'sharedPrograms.SimpleCondToIntDL.P3'(B,G,D))).
'~sharedPrograms.OrSeqToIntDL.P3'('ProgDefs.Or.F2'(A,B), C, D) :-
        '~sharedPrograms.SimpleCondToIntDL.P3'(A, C, E),
        'Strings':'~Strings.StringInts.P2'('" \\/ ', F),  % added \ djd
        'Lists':'~Lists.Append.P3'(F, G, E),
        user:goedel_freeze(ground([B]), (B='ProgDefs.Or.F2'(_,_),true->'SharedPrograms':'~sharedPrograms.OrSeqToIntDL.P3'(B,G,D);'SharedPrograms':'~sharedPrograms.SimpleCondToIntDL.P3'(B,G,D))).
'sharedPrograms.ProgramLanguage.P2'('ProgDefs.Program.F4'(_,_,A,_), A).
'~sharedPrograms.ProgramLanguage.P2'('ProgDefs.Program.F4'(_,_,A,_), A).
'sharedPrograms.RationalTerm.P2'(A, 'MetaDefs.Term.F2'('MetaDefs.Name.F4'('"Rationals','"//','MetaDefs.Function.C0',2),['MetaDefs.Int.F1'(A),'MetaDefs.Int.F1'(1)])).
'~sharedPrograms.RationalTerm.P2'(A, 'MetaDefs.Term.F2'('MetaDefs.Name.F4'('"Rationals','"//','MetaDefs.Function.C0',2),['MetaDefs.Int.F1'(A),'MetaDefs.Int.F1'(1)])).
'sharedPrograms.QuantifiedFormulaToIntDL.P6'(A, B, C, D, E, F) :-
        'sharedPrograms.QuantifiedFormula.P3'(A, G, H),
        'sharedPrograms.DeleteUnderscores.P2'(G, I),
        user:goedel_freeze(ground([I]), (I=[],true->'SharedPrograms':'sharedPrograms.FormulaToIntDL.P6'(H,B,C,D,E,F);'SharedPrograms':'sharedPrograms.QuantifierChars.P3'(A,E,J),'SharedPrograms':'sharedPrograms.VarListToIntDL.P6'(G,B,C,D,J,K),'SharedPrograms':'sharedPrograms.CharDL.P3'('" ',K,L),'SharedPrograms':'sharedPrograms.FormulaToIntDL.P6'(H,B,C,D,M,N),user:goedel_freeze(ground([A,H]),(('SharedPrograms':'~sharedPrograms.CLPrec.P2'(H,O),'SharedPrograms':'~sharedPrograms.CRPrec.P2'(A,P),'SharedPrograms':'~sharedPrograms.BindsTighter.P2'(O,P)),true->L=M,F=N;'SharedPrograms':'sharedPrograms.CharDL.P3'('"(',L,M),'SharedPrograms':'sharedPrograms.CharDL.P3'('")',N,F))))).
'~sharedPrograms.QuantifiedFormulaToIntDL.P6'(A, B, C, D, E, F) :-
        '~sharedPrograms.QuantifiedFormula.P3'(A, G, H),
        '~sharedPrograms.DeleteUnderscores.P2'(G, I),
        user:goedel_freeze(ground([I]), (I=[],true->'SharedPrograms':'~sharedPrograms.FormulaToIntDL.P6'(H,B,C,D,E,F);'SharedPrograms':'~sharedPrograms.QuantifierChars.P3'(A,E,J),'SharedPrograms':'~sharedPrograms.VarListToIntDL.P6'(G,B,C,D,J,K),'SharedPrograms':'~sharedPrograms.CharDL.P3'('" ',K,L),'SharedPrograms':'~sharedPrograms.FormulaToIntDL.P6'(H,B,C,D,M,N),user:goedel_freeze(ground([A,H]),(('SharedPrograms':'~sharedPrograms.CLPrec.P2'(H,O),'SharedPrograms':'~sharedPrograms.CRPrec.P2'(A,P),'SharedPrograms':'~sharedPrograms.BindsTighter.P2'(O,P)),true->L=M,F=N;'SharedPrograms':'~sharedPrograms.CharDL.P3'('"(',L,M),'SharedPrograms':'~sharedPrograms.CharDL.P3'('")',N,F))))).
'sharedPrograms.PropositionInLanguage.P2'(A, B) :-
        'sharedPrograms.SymbolInLanguage.P3'(A, B, 'ProgDefs.PropositionDecl.C0').
'~sharedPrograms.PropositionInLanguage.P2'(A, B) :-
        '~sharedPrograms.SymbolInLanguage.P3'(A, B, 'ProgDefs.PropositionDecl.C0').
'sharedPrograms.QuantifiedFormula.P3'('MetaDefs.Some.F2'(A,B), A, B).
'~sharedPrograms.QuantifiedFormula.P3'('MetaDefs.Some.F2'(A,B), A, B).
'sharedPrograms.QuantifiedFormula.P3'('MetaDefs.All.F2'(A,B), A, B).
'~sharedPrograms.QuantifiedFormula.P3'('MetaDefs.All.F2'(A,B), A, B).
'sharedPrograms.RPrec.P2'('Syntax.NoFunctInd.C0', 'sharedPrograms.Infinity.C0').
'~sharedPrograms.RPrec.P2'('Syntax.NoFunctInd.C0', 'sharedPrograms.Infinity.C0').
'sharedPrograms.RPrec.P2'('Syntax.XFX.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'~sharedPrograms.RPrec.P2'('Syntax.XFX.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'sharedPrograms.RPrec.P2'('Syntax.XFY.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.Y.C0')).
'~sharedPrograms.RPrec.P2'('Syntax.XFY.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.Y.C0')).
'sharedPrograms.RPrec.P2'('Syntax.YFX.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'~sharedPrograms.RPrec.P2'('Syntax.YFX.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'sharedPrograms.RPrec.P2'('Syntax.FX.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'~sharedPrograms.RPrec.P2'('Syntax.FX.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'sharedPrograms.RPrec.P2'('Syntax.FY.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.Y.C0')).
'~sharedPrograms.RPrec.P2'('Syntax.FY.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.Y.C0')).
'sharedPrograms.RPrec.P2'('Syntax.XF.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'~sharedPrograms.RPrec.P2'('Syntax.XF.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'sharedPrograms.RPrec.P2'('Syntax.YF.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'~sharedPrograms.RPrec.P2'('Syntax.YF.F1'(A), 'sharedPrograms.Prec.F2'(A,'sharedPrograms.X.C0')).
'sharedPrograms.QuantifierChars.P3'('MetaDefs.Some.F2'(_,_), A, B) :-
        'Strings':'Strings.StringInts.P2'('"SOME ', C),
        'Lists':'Lists.Append.P3'(C, B, A).
'~sharedPrograms.QuantifierChars.P3'('MetaDefs.Some.F2'(_,_), A, B) :-
        'Strings':'~Strings.StringInts.P2'('"SOME ', C),
        'Lists':'~Lists.Append.P3'(C, B, A).
'sharedPrograms.QuantifierChars.P3'('MetaDefs.All.F2'(_,_), A, B) :-
        'Strings':'Strings.StringInts.P2'('"ALL ', C),
        'Lists':'Lists.Append.P3'(C, B, A).
'~sharedPrograms.QuantifierChars.P3'('MetaDefs.All.F2'(_,_), A, B) :-
        'Strings':'~Strings.StringInts.P2'('"ALL ', C),
        'Lists':'~Lists.Append.P3'(C, B, A).
'sharedPrograms.ReformatDelays.P3'([], [], []).
'~sharedPrograms.ReformatDelays.P3'([], [], []).
'sharedPrograms.ReformatDelays.P3'(['ProgDefs.Delay.F2'(B,C)|A], [B|D], [C|E]) :-
        'sharedPrograms.ReformatDelays.P3'(A, D, E).
'~sharedPrograms.ReformatDelays.P3'(['ProgDefs.Delay.F2'(B,C)|A], [B|D], [C|E]) :-
        '~sharedPrograms.ReformatDelays.P3'(A, D, E).
'sharedPrograms.RationalToIntDL.P9'(A, B, C, D, E, F, G, H, I) :-
        'sharedPrograms.CookRationalTerm.P2'(A, J),
        user:goedel_freeze(ground([B]), (B=1,true->'SharedPrograms':'sharedPrograms.TermToIntDL.P9'(J,C,D,[],E,F,G,H,I);'SharedPrograms':'sharedPrograms.CookRationalTerm.P2'(B,K),'SharedPrograms':'sharedPrograms.TermToIntDL.P9'('MetaDefs.Term.F2'('MetaDefs.Name.F4'('"Rationals','"/','MetaDefs.Function.C0',2),[J,K]),C,D,[],E,F,G,H,I))).
'~sharedPrograms.RationalToIntDL.P9'(A, B, C, D, E, F, G, H, I) :-
        '~sharedPrograms.CookRationalTerm.P2'(A, J),
        user:goedel_freeze(ground([B]), (B=1,true->'SharedPrograms':'~sharedPrograms.TermToIntDL.P9'(J,C,D,[],E,F,G,H,I);'SharedPrograms':'~sharedPrograms.CookRationalTerm.P2'(B,K),'SharedPrograms':'~sharedPrograms.TermToIntDL.P9'('MetaDefs.Term.F2'('MetaDefs.Name.F4'('"Rationals','"/','MetaDefs.Function.C0',2),[J,K]),C,D,[],E,F,G,H,I))).
'sharedPrograms.RestVarListToIntDL.P6'([], _, _, _, A, A).
'~sharedPrograms.RestVarListToIntDL.P6'([], _, _, _, A, A).
'sharedPrograms.RestVarListToIntDL.P6'([A|B], C, D, E, F, G) :-
        'sharedPrograms.CharDL.P3'('",', F, H),
        'sharedPrograms.TermToIntDL.P9'(A, C, D, E, _, _, _, H, I),
        'sharedPrograms.RestVarListToIntDL.P6'(B, C, D, E, I, G).
'~sharedPrograms.RestVarListToIntDL.P6'([A|B], C, D, E, F, G) :-
        '~sharedPrograms.CharDL.P3'('",', F, H),
        '~sharedPrograms.TermToIntDL.P9'(A, C, D, E, _, _, _, H, I),
        '~sharedPrograms.RestVarListToIntDL.P6'(B, C, D, E, I, G).
'sharedPrograms.SConditionToString.P2'(A, B) :-
        'sharedPrograms.ConditionToIntDL.P3'(A, C, []),
        'Strings':'Strings.StringInts.P2'(B, C).
'~sharedPrograms.SConditionToString.P2'(A, B) :-
        '~sharedPrograms.ConditionToIntDL.P3'(A, C, []),
        'Strings':'~Strings.StringInts.P2'(B, C).
'sharedPrograms.SProgramTypeToString.P4'(A, B, C, D) :-
        'sharedPrograms.ModuleLanguage.P3'(A, B, E),
        'sharedPrograms.TypeToIntDL.P4'(C, E, F, []),
        'Strings':'Strings.StringInts.P2'(D, F).
'~sharedPrograms.SProgramTypeToString.P4'(A, B, C, D) :-
        '~sharedPrograms.ModuleLanguage.P3'(A, B, E),
        '~sharedPrograms.TypeToIntDL.P4'(C, E, F, []),
        'Strings':'~Strings.StringInts.P2'(D, F).
'sharedPrograms.SOpenModule.P2'('ProgDefs.Program.F4'(_,A,_,_), B) :-
        'sharedPrograms.OpenModuleAux.P2'(A, B).
'~sharedPrograms.SOpenModule.P2'('ProgDefs.Program.F4'(_,A,_,_), B) :-
        '~sharedPrograms.OpenModuleAux.P2'(A, B).
'sharedPrograms.SMainModuleInProgram.P2'('ProgDefs.Program.F4'(A,_,_,_), A).
'~sharedPrograms.SMainModuleInProgram.P2'('ProgDefs.Program.F4'(A,_,_,_), A).
'sharedPrograms.SProgramTermToString.P4'(A, B, C, D) :-
        'sharedPrograms.TermToIntList.P4'(A, B, C, E),
        'Strings':'Strings.StringInts.P2'(D, E).
'~sharedPrograms.SProgramTermToString.P4'(A, B, C, D) :-
        '~sharedPrograms.TermToIntList.P4'(A, B, C, E),
        'Strings':'~Strings.StringInts.P2'(D, E).
'sharedPrograms.SProgramFormulaToString.P4'(A, B, C, D) :-
        'sharedPrograms.FormulaToIntList.P4'(A, B, C, E),
        'Strings':'Strings.StringInts.P2'(D, E).
'~sharedPrograms.SProgramFormulaToString.P4'(A, B, C, D) :-
        '~sharedPrograms.FormulaToIntList.P4'(A, B, C, E),
        'Strings':'~Strings.StringInts.P2'(D, E).
'sharedPrograms.SpaceIfNeeded.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B]), ((A=B,user:not_equal([],[A],A,'sharedPrograms.Bounded.C0')),true->'SharedPrograms':'sharedPrograms.CharDL.P3'('" ',C,D);C=D)).
'~sharedPrograms.SpaceIfNeeded.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B]), ((A=B,user:not_equal([],[A],A,'sharedPrograms.Bounded.C0')),true->'SharedPrograms':'~sharedPrograms.CharDL.P3'('" ',C,D);C=D)).
'sharedPrograms.SetExprToIntDL.P6'([A,B], C, D, E, F, G) :-
        'sharedPrograms.CharDL.P3'('"{', F, H),
        'sharedPrograms.TermToIntDL.P9'(A, C, D, E, _, _, _, H, I),
        'sharedPrograms.ChainExprToIntDL.P6'(B, C, D, E, I, J),
        'sharedPrograms.CharDL.P3'('"}', J, G).
'~sharedPrograms.SetExprToIntDL.P6'([A,B], C, D, E, F, G) :-
        '~sharedPrograms.CharDL.P3'('"{', F, H),
        '~sharedPrograms.TermToIntDL.P9'(A, C, D, E, _, _, _, H, I),
        '~sharedPrograms.ChainExprToIntDL.P6'(B, C, D, E, I, J),
        '~sharedPrograms.CharDL.P3'('"}', J, G).
'sharedPrograms.SimpleCondToIntDL.P3'('ProgDefs.Nonvar.F1'(A), B, C) :-
        'Strings':'Strings.StringInts.P2'('"NONVAR(', D),
        'Lists':'Lists.Append.P3'(D, E, B),
        'sharedPrograms.TermToIntDL.P9'(A, _, _, _, _, _, _, E, F),
        'sharedPrograms.CharDL.P3'('")', F, C).
'~sharedPrograms.SimpleCondToIntDL.P3'('ProgDefs.Nonvar.F1'(A), B, C) :-
        'Strings':'~Strings.StringInts.P2'('"NONVAR(', D),
        'Lists':'~Lists.Append.P3'(D, E, B),
        '~sharedPrograms.TermToIntDL.P9'(A, _, _, _, _, _, _, E, F),
        '~sharedPrograms.CharDL.P3'('")', F, C).
'sharedPrograms.SimpleCondToIntDL.P3'('ProgDefs.Ground.F1'(A), B, C) :-
        'Strings':'Strings.StringInts.P2'('"GROUND(', D),
        'Lists':'Lists.Append.P3'(D, E, B),
        'sharedPrograms.TermToIntDL.P9'(A, _, _, _, _, _, _, E, F),
        'sharedPrograms.CharDL.P3'('")', F, C).
'~sharedPrograms.SimpleCondToIntDL.P3'('ProgDefs.Ground.F1'(A), B, C) :-
        'Strings':'~Strings.StringInts.P2'('"GROUND(', D),
        'Lists':'~Lists.Append.P3'(D, E, B),
        '~sharedPrograms.TermToIntDL.P9'(A, _, _, _, _, _, _, E, F),
        '~sharedPrograms.CharDL.P3'('")', F, C).
'sharedPrograms.SimpleCondToIntDL.P3'('ProgDefs.And.F2'(A,B), C, D) :-
        'sharedPrograms.CharDL.P3'('"(', C, E),
        'sharedPrograms.AndSeqToIntDL.P3'('ProgDefs.And.F2'(A,B), E, F),
        'sharedPrograms.CharDL.P3'('")', F, D).
'~sharedPrograms.SimpleCondToIntDL.P3'('ProgDefs.And.F2'(A,B), C, D) :-
        '~sharedPrograms.CharDL.P3'('"(', C, E),
        '~sharedPrograms.AndSeqToIntDL.P3'('ProgDefs.And.F2'(A,B), E, F),
        '~sharedPrograms.CharDL.P3'('")', F, D).
'sharedPrograms.SimpleCondToIntDL.P3'('ProgDefs.Or.F2'(A,B), C, D) :-
        'sharedPrograms.CharDL.P3'('"(', C, E),
        'sharedPrograms.OrSeqToIntDL.P3'('ProgDefs.Or.F2'(A,B), E, F),
        'sharedPrograms.CharDL.P3'('")', F, D).
'~sharedPrograms.SimpleCondToIntDL.P3'('ProgDefs.Or.F2'(A,B), C, D) :-
        '~sharedPrograms.CharDL.P3'('"(', C, E),
        '~sharedPrograms.OrSeqToIntDL.P3'('ProgDefs.Or.F2'(A,B), E, F),
        '~sharedPrograms.CharDL.P3'('")', F, D).
'sharedPrograms.StatementInLanguage.P5'('MetaDefs.<-''.F2'(A,B), C, 'MetaDefs.<-''.F2'(D,E), F, G) :-
        'sharedPrograms.MeltedBodyTyping.P8'(B, C, [], H, E, I, J, K),
        user:goedel_freeze(ground([K]), (K=[],true->'SharedPrograms':'sharedPrograms.HeadAtom.P9'(A,C,H,_,D,J,[],L,M),user:goedel_freeze(ground([M]),(M=[],true->'SharedPrograms':'sharedPrograms.FixRationals.P2'(I,F),'SharedPrograms':'sharedPrograms.CheckHeadArgs.P4'(D,L,C,G);G=M));G=K)).
'~sharedPrograms.StatementInLanguage.P5'('MetaDefs.<-''.F2'(A,B), C, 'MetaDefs.<-''.F2'(D,E), F, G) :-
        '~sharedPrograms.MeltedBodyTyping.P8'(B, C, [], H, E, I, J, K),
        user:goedel_freeze(ground([K]), (K=[],true->'SharedPrograms':'~sharedPrograms.HeadAtom.P9'(A,C,H,_,D,J,[],L,M),user:goedel_freeze(ground([M]),(M=[],true->'SharedPrograms':'~sharedPrograms.FixRationals.P2'(I,F),'SharedPrograms':'~sharedPrograms.CheckHeadArgs.P4'(D,L,C,G);G=M));G=K)).
'sharedPrograms.TypeInLanguage.P2'('MetaDefs.Par.F2'(_,_), _).
'~sharedPrograms.TypeInLanguage.P2'('MetaDefs.Par.F2'(_,_), _).
'sharedPrograms.TypeInLanguage.P2'('MetaDefs.Par.F1'(_), _).
'~sharedPrograms.TypeInLanguage.P2'('MetaDefs.Par.F1'(_), _).
'sharedPrograms.TypeInLanguage.P2'('MetaDefs.BType.F1'(A), B) :-
        'sharedPrograms.BaseInLanguage.P2'(A, B).
'~sharedPrograms.TypeInLanguage.P2'('MetaDefs.BType.F1'(A), B) :-
        '~sharedPrograms.BaseInLanguage.P2'(A, B).
'sharedPrograms.TypeInLanguage.P2'('MetaDefs.XBType.F1'(A), B) :-
        'sharedPrograms.BaseInLanguage.P2'(A, B).
'~sharedPrograms.TypeInLanguage.P2'('MetaDefs.XBType.F1'(A), B) :-
        '~sharedPrograms.BaseInLanguage.P2'(A, B).
'sharedPrograms.TypeInLanguage.P2'('MetaDefs.Type.F2'(A,B), C) :-
        'sharedPrograms.ConstructorInLanguage.P3'(A, C, D),
        'Lists':'Lists.Length.P2'(B, D),
        'sharedPrograms.ListTypesInLanguage.P2'(B, C).
'~sharedPrograms.TypeInLanguage.P2'('MetaDefs.Type.F2'(A,B), C) :-
        '~sharedPrograms.ConstructorInLanguage.P3'(A, C, D),
        'Lists':'~Lists.Length.P2'(B, D),
        '~sharedPrograms.ListTypesInLanguage.P2'(B, C).
'sharedPrograms.TypeInLanguage.P2'('MetaDefs.XType.F2'(A,B), C) :-
        'sharedPrograms.ConstructorInLanguage.P3'(A, C, D),
        'Lists':'Lists.Length.P2'(B, D),
        'sharedPrograms.ListTypesInLanguage.P2'(B, C).
'~sharedPrograms.TypeInLanguage.P2'('MetaDefs.XType.F2'(A,B), C) :-
        '~sharedPrograms.ConstructorInLanguage.P3'(A, C, D),
        'Lists':'~Lists.Length.P2'(B, D),
        '~sharedPrograms.ListTypesInLanguage.P2'(B, C).
'sharedPrograms.TermToIntDL.P9'('MetaDefs.Term.F2'(A,B), C, D, E, F, G, H, I, J) :-
        user:goedel_freeze(ground([A,C]), if(('SharedPrograms':'~sharedPrograms.FunctionInLanguage.P5'(A,C,K,_,_),true),('SharedPrograms':'sharedPrograms.TermToIntDLAux.P11'(K,A,B,C,D,E,L,G,H,I,J),F=L),(F='Syntax.NoFunctInd.C0',G='sharedPrograms.Bounded.C0',H='sharedPrograms.Bounded.C0','SharedPrograms':'sharedPrograms.TermInLanguage.P5'('MetaDefs.Term.F2'(A,B),D,'MetaDefs.VarTyping.F1'(E),_,M),'SharedPrograms':'sharedPrograms.CharDL.P3'('"<',I,N),'SharedPrograms':'sharedPrograms.TypeToIntDL.P4'(M,C,N,O),'SharedPrograms':'sharedPrograms.CharDL.P3'('">',O,J)))).
'~sharedPrograms.TermToIntDL.P9'('MetaDefs.Term.F2'(A,B), C, D, E, F, G, H, I, J) :-
        user:goedel_freeze(ground([A,C]), if(('SharedPrograms':'~sharedPrograms.FunctionInLanguage.P5'(A,C,K,_,_),true),('SharedPrograms':'~sharedPrograms.TermToIntDLAux.P11'(K,A,B,C,D,E,L,G,H,I,J),F=L),(F='Syntax.NoFunctInd.C0',G='sharedPrograms.Bounded.C0',H='sharedPrograms.Bounded.C0','SharedPrograms':'~sharedPrograms.TermInLanguage.P5'('MetaDefs.Term.F2'(A,B),D,'MetaDefs.VarTyping.F1'(E),_,M),'SharedPrograms':'~sharedPrograms.CharDL.P3'('"<',I,N),'SharedPrograms':'~sharedPrograms.TypeToIntDL.P4'(M,C,N,O),'SharedPrograms':'~sharedPrograms.CharDL.P3'('">',O,J)))).
'sharedPrograms.TermToIntDL.P9'('MetaDefs.XTerm.F3'(_,_,A), B, _, _, 'Syntax.NoFunctInd.C0', 'sharedPrograms.Bounded.C0', 'sharedPrograms.Bounded.C0', C, D) :-
        'sharedPrograms.CharDL.P3'('"<', C, E),
        'sharedPrograms.TypeToIntDL.P4'(A, B, E, F),
        'sharedPrograms.CharDL.P3'('">', F, D).
'~sharedPrograms.TermToIntDL.P9'('MetaDefs.XTerm.F3'(_,_,A), B, _, _, 'Syntax.NoFunctInd.C0', 'sharedPrograms.Bounded.C0', 'sharedPrograms.Bounded.C0', C, D) :-
        '~sharedPrograms.CharDL.P3'('"<', C, E),
        '~sharedPrograms.TypeToIntDL.P4'(A, B, E, F),
        '~sharedPrograms.CharDL.P3'('">', F, D).
'sharedPrograms.TermToIntDL.P9'('MetaDefs.CTerm.F1'(A), B, C, D, 'Syntax.NoFunctInd.C0', E, E, F, G) :-
        user:goedel_freeze(ground([A,B]), ('SharedPrograms':'~sharedPrograms.ConstantInLanguage.P3'(A,B,_),true->'SharedPrograms':'sharedPrograms.ConstantToIntDL.P4'(A,E,F,G);E='sharedPrograms.Bounded.C0','SharedPrograms':'sharedPrograms.TermInLanguage.P5'('MetaDefs.CTerm.F1'(A),C,'MetaDefs.VarTyping.F1'(D),_,H),'SharedPrograms':'sharedPrograms.CharDL.P3'('"<',F,I),'SharedPrograms':'sharedPrograms.TypeToIntDL.P4'(H,B,I,J),'SharedPrograms':'sharedPrograms.CharDL.P3'('">',J,G))).
'~sharedPrograms.TermToIntDL.P9'('MetaDefs.CTerm.F1'(A), B, C, D, 'Syntax.NoFunctInd.C0', E, E, F, G) :-
        user:goedel_freeze(ground([A,B]), ('SharedPrograms':'~sharedPrograms.ConstantInLanguage.P3'(A,B,_),true->'SharedPrograms':'~sharedPrograms.ConstantToIntDL.P4'(A,E,F,G);E='sharedPrograms.Bounded.C0','SharedPrograms':'~sharedPrograms.TermInLanguage.P5'('MetaDefs.CTerm.F1'(A),C,'MetaDefs.VarTyping.F1'(D),_,H),'SharedPrograms':'~sharedPrograms.CharDL.P3'('"<',F,I),'SharedPrograms':'~sharedPrograms.TypeToIntDL.P4'(H,B,I,J),'SharedPrograms':'~sharedPrograms.CharDL.P3'('">',J,G))).
'sharedPrograms.TermToIntDL.P9'('MetaDefs.XCTerm.F2'(_,A), B, _, _, 'Syntax.NoFunctInd.C0', 'sharedPrograms.Bounded.C0', 'sharedPrograms.Bounded.C0', C, D) :-
        'sharedPrograms.CharDL.P3'('"<', C, E),
        'sharedPrograms.TypeToIntDL.P4'(A, B, E, F),
        'sharedPrograms.CharDL.P3'('">', F, D).
'~sharedPrograms.TermToIntDL.P9'('MetaDefs.XCTerm.F2'(_,A), B, _, _, 'Syntax.NoFunctInd.C0', 'sharedPrograms.Bounded.C0', 'sharedPrograms.Bounded.C0', C, D) :-
        '~sharedPrograms.CharDL.P3'('"<', C, E),
        '~sharedPrograms.TypeToIntDL.P4'(A, B, E, F),
        '~sharedPrograms.CharDL.P3'('">', F, D).
'sharedPrograms.TermToIntDL.P9'('MetaDefs.Var.F2'(A,B), _, _, _, 'Syntax.NoFunctInd.C0', 'sharedPrograms.AlphaNum.C0', 'sharedPrograms.AlphaNum.C0', C, D) :-
        'Strings':'Strings.StringInts.P2'(A, E),
        'Lists':'Lists.Append.P3'(E, F, C),
        user:goedel_freeze(ground([B,A]), ((B=0;'Strings':concat('"_',_,G),A=G),true->D=F;'SharedPrograms':'sharedPrograms.CharDL.P3'('"_',F,H),'SharedSyntax':'SharedSyntax.IntegerToCharDL.P3'(B,H,D))).
'~sharedPrograms.TermToIntDL.P9'('MetaDefs.Var.F2'(A,B), _, _, _, 'Syntax.NoFunctInd.C0', 'sharedPrograms.AlphaNum.C0', 'sharedPrograms.AlphaNum.C0', C, D) :-
        'Strings':'~Strings.StringInts.P2'(A, E),
        'Lists':'~Lists.Append.P3'(E, F, C),
        user:goedel_freeze(ground([B,A]), ((B=0;'Strings':concat('"_',_,G),A=G),true->D=F;'SharedPrograms':'~sharedPrograms.CharDL.P3'('"_',F,H),'SharedSyntax':'~SharedSyntax.IntegerToCharDL.P3'(B,H,D))).
'sharedPrograms.TermToIntDL.P9'('MetaDefs.Var.F1'(A), _, _, _, 'Syntax.NoFunctInd.C0', 'sharedPrograms.AlphaNum.C0', 'sharedPrograms.AlphaNum.C0', B, C) :-
        'Strings':'Strings.StringInts.P2'('"v', D),
        'Lists':'Lists.Append.P3'(D, E, B),
        user:goedel_freeze(ground([A]), (A=0,true->C=E;'SharedPrograms':'sharedPrograms.CharDL.P3'('"_',E,F),'SharedSyntax':'SharedSyntax.IntegerToCharDL.P3'(A,F,C))).
'~sharedPrograms.TermToIntDL.P9'('MetaDefs.Var.F1'(A), _, _, _, 'Syntax.NoFunctInd.C0', 'sharedPrograms.AlphaNum.C0', 'sharedPrograms.AlphaNum.C0', B, C) :-
        'Strings':'~Strings.StringInts.P2'('"v', D),
        'Lists':'~Lists.Append.P3'(D, E, B),
        user:goedel_freeze(ground([A]), (A=0,true->C=E;'SharedPrograms':'~sharedPrograms.CharDL.P3'('"_',E,F),'SharedSyntax':'~SharedSyntax.IntegerToCharDL.P3'(A,F,C))).
'sharedPrograms.TermToIntDL.P9'('MetaDefs.Str.F1'(A), B, _, _, 'Syntax.NoFunctInd.C0', 'sharedPrograms.Bounded.C0', 'sharedPrograms.Bounded.C0', C, D) :-
        'sharedPrograms.BaseInLanguage.P2'('MetaDefs.Name.F4'('"Strings','"String','MetaDefs.Base.C0',0), B),
        'Strings':'Strings.StringInts.P2'(A, E),
        'sharedPrograms.ExpandString.P3'(E, C, D).
'~sharedPrograms.TermToIntDL.P9'('MetaDefs.Str.F1'(A), B, _, _, 'Syntax.NoFunctInd.C0', 'sharedPrograms.Bounded.C0', 'sharedPrograms.Bounded.C0', C, D) :-
        '~sharedPrograms.BaseInLanguage.P2'('MetaDefs.Name.F4'('"Strings','"String','MetaDefs.Base.C0',0), B),
        'Strings':'~Strings.StringInts.P2'(A, E),
        '~sharedPrograms.ExpandString.P3'(E, C, D).
'sharedPrograms.TermToIntDL.P9'('MetaDefs.Int.F1'(A), B, _, _, C, D, 'sharedPrograms.AlphaNum.C0', E, F) :-
        'sharedPrograms.BaseInLanguage.P2'('MetaDefs.Name.F4'('"Integers','"Integer','MetaDefs.Base.C0',0), B),
        'SharedSyntax':'SharedSyntax.IntegerToCharDL.P3'(A, E, F),
        user:goedel_freeze(ground([A]), ('Integers':'~Integers.<.P2'(A,0),true->'SharedPrograms':'sharedPrograms.FunctionInLanguage.P5'('MetaDefs.Name.F4'('"Integers','"-','MetaDefs.Function.C0',1),B,C,_,_),D='sharedPrograms.Graphic.C0';C='Syntax.NoFunctInd.C0',D='sharedPrograms.AlphaNum.C0')).
'~sharedPrograms.TermToIntDL.P9'('MetaDefs.Int.F1'(A), B, _, _, C, D, 'sharedPrograms.AlphaNum.C0', E, F) :-
        '~sharedPrograms.BaseInLanguage.P2'('MetaDefs.Name.F4'('"Integers','"Integer','MetaDefs.Base.C0',0), B),
        'SharedSyntax':'~SharedSyntax.IntegerToCharDL.P3'(A, E, F),
        user:goedel_freeze(ground([A]), ('Integers':'~Integers.<.P2'(A,0),true->'SharedPrograms':'~sharedPrograms.FunctionInLanguage.P5'('MetaDefs.Name.F4'('"Integers','"-','MetaDefs.Function.C0',1),B,C,_,_),D='sharedPrograms.Graphic.C0';C='Syntax.NoFunctInd.C0',D='sharedPrograms.AlphaNum.C0')).
'sharedPrograms.TermToIntDL.P9'('MetaDefs.Prm.F1'(A), B, C, D, 'Syntax.NoFunctInd.C0', 'sharedPrograms.Bounded.C0', 'sharedPrograms.Bounded.C0', E, F) :-
        'sharedPrograms.TermInLanguage.P5'('MetaDefs.Prm.F1'(A), C, 'MetaDefs.VarTyping.F1'(D), _, G),
        'sharedPrograms.CharDL.P3'('"<', E, H),
        'sharedPrograms.TypeToIntDL.P4'(G, B, H, I),
        'sharedPrograms.CharDL.P3'('">', I, F).
'~sharedPrograms.TermToIntDL.P9'('MetaDefs.Prm.F1'(A), B, C, D, 'Syntax.NoFunctInd.C0', 'sharedPrograms.Bounded.C0', 'sharedPrograms.Bounded.C0', E, F) :-
        '~sharedPrograms.TermInLanguage.P5'('MetaDefs.Prm.F1'(A), C, 'MetaDefs.VarTyping.F1'(D), _, G),
        '~sharedPrograms.CharDL.P3'('"<', E, H),
        '~sharedPrograms.TypeToIntDL.P4'(G, B, H, I),
        '~sharedPrograms.CharDL.P3'('">', I, F).
'sharedPrograms.TermToIntDL.P9'('MetaDefs.SuchThat.F2'(A,B), C, D, E, 'Syntax.NoFunctInd.C0', 'sharedPrograms.Bounded.C0', 'sharedPrograms.Bounded.C0', F, G) :-
        'sharedPrograms.CharDL.P3'('"{', F, H),
        'sharedPrograms.TermToIntDL.P9'(A, C, D, E, _, _, _, H, I),
        'Strings':'Strings.StringInts.P2'('" : ', J),
        'Lists':'Lists.Append.P3'(J, K, I),
        'sharedPrograms.FormulaToIntDL.P6'(B, C, D, E, K, L),
        'sharedPrograms.CharDL.P3'('"}', L, G).
'~sharedPrograms.TermToIntDL.P9'('MetaDefs.SuchThat.F2'(A,B), C, D, E, 'Syntax.NoFunctInd.C0', 'sharedPrograms.Bounded.C0', 'sharedPrograms.Bounded.C0', F, G) :-
        '~sharedPrograms.CharDL.P3'('"{', F, H),
        '~sharedPrograms.TermToIntDL.P9'(A, C, D, E, _, _, _, H, I),
        'Strings':'~Strings.StringInts.P2'('" : ', J),
        'Lists':'~Lists.Append.P3'(J, K, I),
        '~sharedPrograms.FormulaToIntDL.P6'(B, C, D, E, K, L),
        '~sharedPrograms.CharDL.P3'('"}', L, G).
'sharedPrograms.TermListToIntDL.P6'([A|B], C, D, E, F, G) :-
        'sharedPrograms.TermToIntDL.P9'(A, C, D, E, _, _, _, F, H),
        'sharedPrograms.TermListToIntDLAux.P6'(B, C, D, E, H, G).
'~sharedPrograms.TermListToIntDL.P6'([A|B], C, D, E, F, G) :-
        '~sharedPrograms.TermToIntDL.P9'(A, C, D, E, _, _, _, F, H),
        '~sharedPrograms.TermListToIntDLAux.P6'(B, C, D, E, H, G).
'sharedPrograms.TermInLanguage.P5'(A, B, 'MetaDefs.VarTyping.F1'(C), 'MetaDefs.VarTyping.F1'(D), E) :-
        'sharedPrograms.MeltVariableTyping.P4'(C, B, [], F),
        'sharedPrograms.MeltedTermType.P9'(A, E, B, F, D, _, [], [], []),
        'sharedPrograms.FixType.P3'(E, 0, G),
        'sharedPrograms.FixVariableTyping.P2'(D, G).
'~sharedPrograms.TermInLanguage.P5'(A, B, 'MetaDefs.VarTyping.F1'(C), 'MetaDefs.VarTyping.F1'(D), E) :-
        '~sharedPrograms.MeltVariableTyping.P4'(C, B, [], F),
        '~sharedPrograms.MeltedTermType.P9'(A, E, B, F, D, _, [], [], []),
        '~sharedPrograms.FixType.P3'(E, 0, G),
        '~sharedPrograms.FixVariableTyping.P2'(D, G).
'sharedPrograms.TermListToIntDLAux.P6'([], _, _, _, A, A).
'~sharedPrograms.TermListToIntDLAux.P6'([], _, _, _, A, A).
'sharedPrograms.TermListToIntDLAux.P6'([A|B], C, D, E, F, G) :-
        'sharedPrograms.CharDL.P3'('",', F, H),
        'sharedPrograms.TermToIntDL.P9'(A, C, D, E, _, _, _, H, I),
        'sharedPrograms.TermListToIntDLAux.P6'(B, C, D, E, I, G).
'~sharedPrograms.TermListToIntDLAux.P6'([A|B], C, D, E, F, G) :-
        '~sharedPrograms.CharDL.P3'('",', F, H),
        '~sharedPrograms.TermToIntDL.P9'(A, C, D, E, _, _, _, H, I),
        '~sharedPrograms.TermListToIntDLAux.P6'(B, C, D, E, I, G).
'sharedPrograms.TermToIntList.P4'(A, B, C, D) :-
        'sharedPrograms.ProgramLanguage.P2'(A, E),
        'sharedPrograms.ModuleLanguage.P3'(A, B, F),
        'sharedPrograms.TermInLanguage.P5'(C, E, 'MetaDefs.VarTyping.F1'([]), 'MetaDefs.VarTyping.F1'(G), _),
        'sharedPrograms.TermToIntDL.P9'(C, F, E, G, _, _, _, D, []).
'~sharedPrograms.TermToIntList.P4'(A, B, C, D) :-
        '~sharedPrograms.ProgramLanguage.P2'(A, E),
        '~sharedPrograms.ModuleLanguage.P3'(A, B, F),
        '~sharedPrograms.TermInLanguage.P5'(C, E, 'MetaDefs.VarTyping.F1'([]), 'MetaDefs.VarTyping.F1'(G), _),
        '~sharedPrograms.TermToIntDL.P9'(C, F, E, G, _, _, _, D, []).
'sharedPrograms.TermToIntDLAux.P11'('Syntax.NoFunctInd.C0', 'MetaDefs.Name.F4'(A,B,C,D), E, F, G, H, 'Syntax.NoFunctInd.C0', I, 'sharedPrograms.Bounded.C0', J, K) :-
        user:goedel_freeze(ground([D,C,A,B]), ((A='"Lists',B='"Cons',C='MetaDefs.Function.C0',D=2),true->I='sharedPrograms.Bounded.C0','SharedPrograms':'sharedPrograms.ListExprToIntDL.P6'(E,F,G,H,J,K);user:goedel_freeze(ground([D,C,A,B]),((A='"Sets',B='"Inc',C='MetaDefs.Function.C0',D=2),true->I='sharedPrograms.Bounded.C0','SharedPrograms':'sharedPrograms.SetExprToIntDL.P6'(E,F,G,H,J,K);'SharedPrograms':'sharedPrograms.ClassifyToken.P2'(B,I),'Strings':'Strings.StringInts.P2'(B,L),'Lists':'Lists.Append.P3'(L,M,J),'SharedPrograms':'sharedPrograms.CharDL.P3'('"(',M,N),'SharedPrograms':'sharedPrograms.TermListToIntDL.P6'(E,F,G,H,N,O),'SharedPrograms':'sharedPrograms.CharDL.P3'('")',O,K))))).
'~sharedPrograms.TermToIntDLAux.P11'('Syntax.NoFunctInd.C0', 'MetaDefs.Name.F4'(A,B,C,D), E, F, G, H, 'Syntax.NoFunctInd.C0', I, 'sharedPrograms.Bounded.C0', J, K) :-
        user:goedel_freeze(ground([D,C,A,B]), ((A='"Lists',B='"Cons',C='MetaDefs.Function.C0',D=2),true->I='sharedPrograms.Bounded.C0','SharedPrograms':'~sharedPrograms.ListExprToIntDL.P6'(E,F,G,H,J,K);user:goedel_freeze(ground([D,C,A,B]),((A='"Sets',B='"Inc',C='MetaDefs.Function.C0',D=2),true->I='sharedPrograms.Bounded.C0','SharedPrograms':'~sharedPrograms.SetExprToIntDL.P6'(E,F,G,H,J,K);'SharedPrograms':'~sharedPrograms.ClassifyToken.P2'(B,I),'Strings':'~Strings.StringInts.P2'(B,L),'Lists':'~Lists.Append.P3'(L,M,J),'SharedPrograms':'~sharedPrograms.CharDL.P3'('"(',M,N),'SharedPrograms':'~sharedPrograms.TermListToIntDL.P6'(E,F,G,H,N,O),'SharedPrograms':'~sharedPrograms.CharDL.P3'('")',O,K))))).
'sharedPrograms.TermToIntDLAux.P11'('Syntax.XFX.F1'(A), B, [C,D], E, F, G, H, I, J, K, L) :-
        'sharedPrograms.BinaryInfixToIntDL.P12'('Syntax.XFX.F1'(A), B, C, D, E, F, G, H, I, J, K, L).
'~sharedPrograms.TermToIntDLAux.P11'('Syntax.XFX.F1'(A), B, [C,D], E, F, G, H, I, J, K, L) :-
        '~sharedPrograms.BinaryInfixToIntDL.P12'('Syntax.XFX.F1'(A), B, C, D, E, F, G, H, I, J, K, L).
'sharedPrograms.TermToIntDLAux.P11'('Syntax.XFY.F1'(A), B, [C,D], E, F, G, H, I, J, K, L) :-
        'sharedPrograms.BinaryInfixToIntDL.P12'('Syntax.XFY.F1'(A), B, C, D, E, F, G, H, I, J, K, L).
'~sharedPrograms.TermToIntDLAux.P11'('Syntax.XFY.F1'(A), B, [C,D], E, F, G, H, I, J, K, L) :-
        '~sharedPrograms.BinaryInfixToIntDL.P12'('Syntax.XFY.F1'(A), B, C, D, E, F, G, H, I, J, K, L).
'sharedPrograms.TermToIntDLAux.P11'('Syntax.YFX.F1'(A), B, [C,D], E, F, G, H, I, J, K, L) :-
        'sharedPrograms.BinaryInfixToIntDL.P12'('Syntax.YFX.F1'(A), B, C, D, E, F, G, H, I, J, K, L).
'~sharedPrograms.TermToIntDLAux.P11'('Syntax.YFX.F1'(A), B, [C,D], E, F, G, H, I, J, K, L) :-
        '~sharedPrograms.BinaryInfixToIntDL.P12'('Syntax.YFX.F1'(A), B, C, D, E, F, G, H, I, J, K, L).
'sharedPrograms.TermToIntDLAux.P11'('Syntax.FX.F1'(A), B, [C], D, E, F, 'Syntax.FX.F1'(A), G, H, I, J) :-
        'sharedPrograms.UnaryPrefixToIntDL.P10'('Syntax.FX.F1'(A), B, C, D, E, F, G, H, I, J).
'~sharedPrograms.TermToIntDLAux.P11'('Syntax.FX.F1'(A), B, [C], D, E, F, 'Syntax.FX.F1'(A), G, H, I, J) :-
        '~sharedPrograms.UnaryPrefixToIntDL.P10'('Syntax.FX.F1'(A), B, C, D, E, F, G, H, I, J).
'sharedPrograms.TermToIntDLAux.P11'('Syntax.FY.F1'(A), B, [C], D, E, F, 'Syntax.FY.F1'(A), G, H, I, J) :-
        'sharedPrograms.UnaryPrefixToIntDL.P10'('Syntax.FY.F1'(A), B, C, D, E, F, G, H, I, J).
'~sharedPrograms.TermToIntDLAux.P11'('Syntax.FY.F1'(A), B, [C], D, E, F, 'Syntax.FY.F1'(A), G, H, I, J) :-
        '~sharedPrograms.UnaryPrefixToIntDL.P10'('Syntax.FY.F1'(A), B, C, D, E, F, G, H, I, J).
'sharedPrograms.TermToIntDLAux.P11'('Syntax.XF.F1'(A), B, [C], D, E, F, 'Syntax.XF.F1'(A), G, H, I, J) :-
        'sharedPrograms.UnaryPostfixToIntDL.P10'('Syntax.XF.F1'(A), B, C, D, E, F, G, H, I, J).
'~sharedPrograms.TermToIntDLAux.P11'('Syntax.XF.F1'(A), B, [C], D, E, F, 'Syntax.XF.F1'(A), G, H, I, J) :-
        '~sharedPrograms.UnaryPostfixToIntDL.P10'('Syntax.XF.F1'(A), B, C, D, E, F, G, H, I, J).
'sharedPrograms.TermToIntDLAux.P11'('Syntax.YF.F1'(A), B, [C], D, E, F, 'Syntax.YF.F1'(A), G, H, I, J) :-
        'sharedPrograms.UnaryPostfixToIntDL.P10'('Syntax.YF.F1'(A), B, C, D, E, F, G, H, I, J).
'~sharedPrograms.TermToIntDLAux.P11'('Syntax.YF.F1'(A), B, [C], D, E, F, 'Syntax.YF.F1'(A), G, H, I, J) :-
        '~sharedPrograms.UnaryPostfixToIntDL.P10'('Syntax.YF.F1'(A), B, C, D, E, F, G, H, I, J).
'sharedPrograms.ThenPartToIntDL.P6'(A, B, C, D, E, F) :-
        'sharedPrograms.FormulaToIntDL.P6'(A, B, C, D, G, H),
        user:goedel_freeze(ground([A]), ('SharedPrograms':'~sharedPrograms.MustBracketThen.P1'(A),true->'SharedPrograms':'sharedPrograms.CharDL.P3'('"(',E,G),'SharedPrograms':'sharedPrograms.CharDL.P3'('")',H,F);E=G,F=H)).
'~sharedPrograms.ThenPartToIntDL.P6'(A, B, C, D, E, F) :-
        '~sharedPrograms.FormulaToIntDL.P6'(A, B, C, D, G, H),
        user:goedel_freeze(ground([A]), ('SharedPrograms':'~sharedPrograms.MustBracketThen.P1'(A),true->'SharedPrograms':'~sharedPrograms.CharDL.P3'('"(',E,G),'SharedPrograms':'~sharedPrograms.CharDL.P3'('")',H,F);E=G,F=H)).
'sharedPrograms.TypeSymbolInLanguage.P3'('MetaDefs.Name.F4'(A,B,C,D), 'ProgDefs.Language.F1'(E), F) :-
        'sharedPrograms.AVLFind.P3'(E, A, 'ProgDefs.Module.F3'(G,'ProgDefs.Categories.F2'(H,_),_)),
        'sharedPrograms.AVLFind.P3'(H, B, I),
        'sharedPrograms.FindDescriptor.P5'(I, G, C, D, F).
'~sharedPrograms.TypeSymbolInLanguage.P3'('MetaDefs.Name.F4'(A,B,C,D), 'ProgDefs.Language.F1'(E), F) :-
        '~sharedPrograms.AVLFind.P3'(E, A, 'ProgDefs.Module.F3'(G,'ProgDefs.Categories.F2'(H,_),_)),
        '~sharedPrograms.AVLFind.P3'(H, B, I),
        '~sharedPrograms.FindDescriptor.P5'(I, G, C, D, F).
'sharedPrograms.TypeListToIntDL.P4'([A|B], C, D, E) :-
        'sharedPrograms.TypeToIntDL.P4'(A, C, D, F),
        'sharedPrograms.TypeListToIntDLAux.P4'(B, C, F, E).
'~sharedPrograms.TypeListToIntDL.P4'([A|B], C, D, E) :-
        '~sharedPrograms.TypeToIntDL.P4'(A, C, D, F),
        '~sharedPrograms.TypeListToIntDLAux.P4'(B, C, F, E).
'sharedPrograms.TypeListToIntDLAux.P4'([], _, A, A).
'~sharedPrograms.TypeListToIntDLAux.P4'([], _, A, A).
'sharedPrograms.TypeListToIntDLAux.P4'([A|B], C, D, E) :-
        'sharedPrograms.CharDL.P3'('",', D, F),
        'sharedPrograms.TypeToIntDL.P4'(A, C, F, G),
        'sharedPrograms.TypeListToIntDLAux.P4'(B, C, G, E).
'~sharedPrograms.TypeListToIntDLAux.P4'([A|B], C, D, E) :-
        '~sharedPrograms.CharDL.P3'('",', D, F),
        '~sharedPrograms.TypeToIntDL.P4'(A, C, F, G),
        '~sharedPrograms.TypeListToIntDLAux.P4'(B, C, G, E).
'sharedPrograms.UnaryPrefixToIntDL.P10'(A, 'MetaDefs.Name.F4'(_,B,_,_), C, D, E, F, G, H, I, J) :-
        'sharedPrograms.TermToIntDL.P9'(C, D, E, F, K, L, M, N, O),
        'sharedPrograms.ClassifyToken.P2'(B, G),
        'Strings':'Strings.StringInts.P2'(B, P),
        'Lists':'Lists.Append.P3'(P, Q, I),
        user:goedel_freeze(ground([A,K]), (('SharedPrograms':'~sharedPrograms.LPrec.P2'(K,R),'SharedPrograms':'~sharedPrograms.RPrec.P2'(A,S),'SharedPrograms':'~sharedPrograms.BindsTighter.P2'(R,S)),true->H=M,'SharedPrograms':'sharedPrograms.SpaceIfNeeded.P4'(G,L,Q,N),J=O;H='sharedPrograms.Bounded.C0','SharedPrograms':'sharedPrograms.CharDL.P3'('"(',Q,N),'SharedPrograms':'sharedPrograms.CharDL.P3'('")',O,J))).
'~sharedPrograms.UnaryPrefixToIntDL.P10'(A, 'MetaDefs.Name.F4'(_,B,_,_), C, D, E, F, G, H, I, J) :-
        '~sharedPrograms.TermToIntDL.P9'(C, D, E, F, K, L, M, N, O),
        '~sharedPrograms.ClassifyToken.P2'(B, G),
        'Strings':'~Strings.StringInts.P2'(B, P),
        'Lists':'~Lists.Append.P3'(P, Q, I),
        user:goedel_freeze(ground([A,K]), (('SharedPrograms':'~sharedPrograms.LPrec.P2'(K,R),'SharedPrograms':'~sharedPrograms.RPrec.P2'(A,S),'SharedPrograms':'~sharedPrograms.BindsTighter.P2'(R,S)),true->H=M,'SharedPrograms':'~sharedPrograms.SpaceIfNeeded.P4'(G,L,Q,N),J=O;H='sharedPrograms.Bounded.C0','SharedPrograms':'~sharedPrograms.CharDL.P3'('"(',Q,N),'SharedPrograms':'~sharedPrograms.CharDL.P3'('")',O,J))).
'sharedPrograms.TypeToIntDL.P4'('MetaDefs.Type.F2'(A,B), C, D, E) :-
        'sharedPrograms.ConstructorInLanguage.P3'(A, C, F),
        'Lists':'Lists.Length.P2'(B, F),
        A='MetaDefs.Name.F4'(_,G,_,_),
        'Strings':'Strings.StringInts.P2'(G, H),
        'Lists':'Lists.Append.P3'(H, I, D),
        'sharedPrograms.CharDL.P3'('"(', I, J),
        'sharedPrograms.TypeListToIntDL.P4'(B, C, J, K),
        'sharedPrograms.CharDL.P3'('")', K, E).
'~sharedPrograms.TypeToIntDL.P4'('MetaDefs.Type.F2'(A,B), C, D, E) :-
        '~sharedPrograms.ConstructorInLanguage.P3'(A, C, F),
        'Lists':'~Lists.Length.P2'(B, F),
        A='MetaDefs.Name.F4'(_,G,_,_),
        'Strings':'~Strings.StringInts.P2'(G, H),
        'Lists':'~Lists.Append.P3'(H, I, D),
        '~sharedPrograms.CharDL.P3'('"(', I, J),
        '~sharedPrograms.TypeListToIntDL.P4'(B, C, J, K),
        '~sharedPrograms.CharDL.P3'('")', K, E).
'sharedPrograms.TypeToIntDL.P4'('MetaDefs.BType.F1'(A), B, C, D) :-
        'sharedPrograms.BaseInLanguage.P2'(A, B),
        A='MetaDefs.Name.F4'(_,E,_,_),
        'Strings':'Strings.StringInts.P2'(E, F),
        'Lists':'Lists.Append.P3'(F, D, C).
'~sharedPrograms.TypeToIntDL.P4'('MetaDefs.BType.F1'(A), B, C, D) :-
        '~sharedPrograms.BaseInLanguage.P2'(A, B),
        A='MetaDefs.Name.F4'(_,E,_,_),
        'Strings':'~Strings.StringInts.P2'(E, F),
        'Lists':'~Lists.Append.P3'(F, D, C).
'sharedPrograms.TypeToIntDL.P4'('MetaDefs.Par.F2'(A,B), _, C, D) :-
        'Strings':'Strings.StringInts.P2'(A, E),
        'Lists':'Lists.Append.P3'(E, F, C),
        user:goedel_freeze(ground([B]), (B=0,true->D=F;'SharedPrograms':'sharedPrograms.CharDL.P3'('"_',F,G),'SharedSyntax':'SharedSyntax.IntegerToCharDL.P3'(B,G,D))).
'~sharedPrograms.TypeToIntDL.P4'('MetaDefs.Par.F2'(A,B), _, C, D) :-
        'Strings':'~Strings.StringInts.P2'(A, E),
        'Lists':'~Lists.Append.P3'(E, F, C),
        user:goedel_freeze(ground([B]), (B=0,true->D=F;'SharedPrograms':'~sharedPrograms.CharDL.P3'('"_',F,G),'SharedSyntax':'~SharedSyntax.IntegerToCharDL.P3'(B,G,D))).
'sharedPrograms.TypeToIntDL.P4'('MetaDefs.Par.F1'(A), _, B, C) :-
        'sharedPrograms.CharDL.P3'('"p', B, D),
        user:goedel_freeze(ground([A]), (A=0,true->C=D;'SharedPrograms':'sharedPrograms.CharDL.P3'('"_',D,E),'SharedSyntax':'SharedSyntax.IntegerToCharDL.P3'(A,E,C))).
'~sharedPrograms.TypeToIntDL.P4'('MetaDefs.Par.F1'(A), _, B, C) :-
        '~sharedPrograms.CharDL.P3'('"p', B, D),
        user:goedel_freeze(ground([A]), (A=0,true->C=D;'SharedPrograms':'~sharedPrograms.CharDL.P3'('"_',D,E),'SharedSyntax':'~SharedSyntax.IntegerToCharDL.P3'(A,E,C))).
'sharedPrograms.UnaryPostfixToIntDL.P10'(A, 'MetaDefs.Name.F4'(_,B,_,_), C, D, E, F, G, H, I, J) :-
        'sharedPrograms.TermToIntDL.P9'(C, D, E, F, K, L, M, N, O),
        'sharedPrograms.ClassifyToken.P2'(B, H),
        user:goedel_freeze(ground([A,K]), (('SharedPrograms':'~sharedPrograms.RPrec.P2'(K,P),'SharedPrograms':'~sharedPrograms.LPrec.P2'(A,Q),'SharedPrograms':'~sharedPrograms.BindsTighter.P2'(P,Q)),true->G=L,I=N,'SharedPrograms':'sharedPrograms.SpaceIfNeeded.P4'(M,H,O,R);G='sharedPrograms.Bounded.C0','SharedPrograms':'sharedPrograms.CharDL.P3'('"(',I,N),'SharedPrograms':'sharedPrograms.CharDL.P3'('")',O,R))),
        'Strings':'Strings.StringInts.P2'(B, S),
        'Lists':'Lists.Append.P3'(S, J, R).
'~sharedPrograms.UnaryPostfixToIntDL.P10'(A, 'MetaDefs.Name.F4'(_,B,_,_), C, D, E, F, G, H, I, J) :-
        '~sharedPrograms.TermToIntDL.P9'(C, D, E, F, K, L, M, N, O),
        '~sharedPrograms.ClassifyToken.P2'(B, H),
        user:goedel_freeze(ground([A,K]), (('SharedPrograms':'~sharedPrograms.RPrec.P2'(K,P),'SharedPrograms':'~sharedPrograms.LPrec.P2'(A,Q),'SharedPrograms':'~sharedPrograms.BindsTighter.P2'(P,Q)),true->G=L,I=N,'SharedPrograms':'~sharedPrograms.SpaceIfNeeded.P4'(M,H,O,R);G='sharedPrograms.Bounded.C0','SharedPrograms':'~sharedPrograms.CharDL.P3'('"(',I,N),'SharedPrograms':'~sharedPrograms.CharDL.P3'('")',O,R))),
        'Strings':'~Strings.StringInts.P2'(B, S),
        'Lists':'~Lists.Append.P3'(S, J, R).
'sharedPrograms.UpdateDelays.P6'('ProgDefs.Export.C0', A, B, C, [A|B], C).
'~sharedPrograms.UpdateDelays.P6'('ProgDefs.Export.C0', A, B, C, [A|B], C).
'sharedPrograms.UpdateDelays.P6'('ProgDefs.Closed.C0', A, B, C, [A|B], C).
'~sharedPrograms.UpdateDelays.P6'('ProgDefs.Closed.C0', A, B, C, [A|B], C).
'sharedPrograms.UpdateDelays.P6'('ProgDefs.Local.C0', A, B, C, B, [A|C]).
'~sharedPrograms.UpdateDelays.P6'('ProgDefs.Local.C0', A, B, C, B, [A|C]).
'sharedPrograms.UpdateDelays.P6'('ProgDefs.Module.C0', A, B, C, B, [A|C]).
'~sharedPrograms.UpdateDelays.P6'('ProgDefs.Module.C0', A, B, C, B, [A|C]).
'sharedPrograms.VarListToIntDL.P6'([A|B], C, D, E, F, G) :-
        'sharedPrograms.CharDL.P3'('"[', F, H),
        'sharedPrograms.TermToIntDL.P9'(A, C, D, E, _, _, _, H, I),
        'sharedPrograms.RestVarListToIntDL.P6'(B, C, D, E, I, J),
        'sharedPrograms.CharDL.P3'('"]', J, G).
'~sharedPrograms.VarListToIntDL.P6'([A|B], C, D, E, F, G) :-
        '~sharedPrograms.CharDL.P3'('"[', F, H),
        '~sharedPrograms.TermToIntDL.P9'(A, C, D, E, _, _, _, H, I),
        '~sharedPrograms.RestVarListToIntDL.P6'(B, C, D, E, I, J),
        '~sharedPrograms.CharDL.P3'('"]', J, G).
%------------------------------------------------------------------------------
%------------------------------------------------------------------------------
% Prolog routines shared by the parser and Programs and Scripts system modules.
%------------------------------------------------------------------------------
%------------------------------------------------------------------------------
%------------------------------------------------------------------------------
% Useful routines
%------------------------------------------------------------------------------
 
'sharedPrograms.FindMember.P2'(X, Ys) :-
   ( var(X) ->
     Ys = [Z|Zs],
     member_in(Zs, Z, X)
   ; user:'Lists.MemberCheck.P2'(X, Ys)
   ).

member_in([], X, X).

member_in([Y|Ys], Z, X) :-
   ( X = Z ; member_in(Ys, Y, X)).

'~sharedPrograms.FindMember.P2'(X, Ys) :-
   'sharedPrograms.FindMember.P2'(X, Ys).


'sharedPrograms.PickOne.P3'(X, Ys, Rest) :-
   ( var(X) ->
     delete_one(Ys, X, Rest)
   ; user:'Lists.DeleteFirst.P3'(X, Ys, Rest)
   ).

'~sharedPrograms.PickOne.P3'(X, Ys, Rest) :-
   'sharedPrograms.PickOne.P3'(X, Ys, Rest).


delete_one([Y|Ys], X, Rest) :-
   ( Ys = [] ->
     X = Y,
     Rest = Ys
   ;
     ( X = Y, 
       Rest = Ys
     ; delete_one(Ys, X, Rest1),
       Rest = [Y|Rest1]
     )
   ).

%------------------------------------------------------------------------------
% Support for access to symbols in language
%------------------------------------------------------------------------------ 

'sharedPrograms.FindDescriptor.P5'([Desc|Descs], Access, Category, Arity, Decl) :-
   ( nonvar(Arity), nonvar(Category) ->
     one_descriptor_in([Desc|Descs], Access, Category, Arity, Decl)
   ; descriptor_in(Descs, Desc, Access, Category, Arity, Decl) 
   ).

'~sharedPrograms.FindDescriptor.P5'(Descriptors, Access, Category, Arity, Decl) :-
   'sharedPrograms.FindDescriptor.P5'(Descriptors, Access, Category, Arity, Decl).


descriptor_in([], Desc, Access, Cat, Arity, Decl) :-
   'sharedPrograms.MatchingDescriptor.P5'(Desc, Access, Cat, Arity, Decl).

descriptor_in([D|Ds], Desc, Access, Cat, Arity, Decl) :-
   ( 'sharedPrograms.MatchingDescriptor.P5'(Desc, Access, Cat, Arity, Decl)
   ; descriptor_in(Ds, D, Access, Cat, Arity, Decl)
   ).


one_descriptor_in([Desc|Descs], Access, Cat, Arity, Decl) :-
   ( 'sharedPrograms.MatchingDescriptor.P5'(Desc, Access, Cat, Arity, Decl) ->
     true
   ; one_descriptor_in(Descs, Access, Cat, Arity, Decl)
   ).

%------------------------------------------------------------------------------
% Support for access to Program code
%------------------------------------------------------------------------------

'sharedPrograms.SystemModule.P1'(S) :-
   (S == '"' ; user:system_module_name(S)), !.

'~sharedPrograms.SystemModule.P1'(S) :-
   'sharedPrograms.SystemModule.P1'(S).

 
'sharedPrograms.AVLFind.P3'(Tree, Key, Item) :-
   ( var(Key) ->
     user:'AVLTrees.AVLMember.P3'(Tree, Key, Item)
   ; user:'AVLTrees.AVLSearch.P3'(Tree, Key, Item)
   ).

'~sharedPrograms.AVLFind.P3'(Tree, Key, Item) :-
   'sharedPrograms.AVLFind.P3'(Tree, Key, Item).


'sharedPrograms.FindPredDef.P3'(Arity, PredDefs
      , 'ProgDefs.PredDef.F4'(Arity, Statements, Delays1, Delays2)
      ) :-
   ( var(Arity) ->
     user:'Lists.Member.P2'('ProgDefs.PredDef.F4'(Arity, Statements
           , Delays1, Delays2)
        , PredDefs)
   ; user:'Lists.MemberCheck.P2'('ProgDefs.PredDef.F4'(Arity, Statements
           , Delays1, Delays2)
        , PredDefs)
   ).

'~sharedPrograms.FindPredDef.P3'(Arity, PredDefs, Program) :-
   'sharedPrograms.FindPredDef.P3'(Arity, PredDefs, Program).


'sharedPrograms.PickPredDef.P4'(Arity, PredDefs
      , 'ProgDefs.PredDef.F4'(Arity, Statements, Delays1, Delays2), RestDefs
      ) :-
   ( var(Arity) ->
     'Lists':'Lists.Delete.P3'('ProgDefs.PredDef.F4'(Arity, Statements
           , Delays1, Delays2)
        , PredDefs, RestDefs)
   ; 'Lists':'Lists.DeleteFirst.P3'('ProgDefs.PredDef.F4'(Arity, Statements
           , Delays1, Delays2)
        , PredDefs, RestDefs)
   ).

'~sharedPrograms.PickPredDef.P4'(Arity, PredDefs, PredDef, RestDefs) :-
   'sharedPrograms.PickPredDef.P4'(Arity, PredDefs, PredDef, RestDefs).

%------------------------------------------------------------------------------
% Support for autorecompilation (Succeed etc.)
%------------------------------------------------------------------------------

:- dynamic used_module_version/2.

'sharedPrograms.NextModuleVersion.P2'(Module, Version) :-
   ( retract(used_module_version(Module, Old)) ->
     Version is Old + 1
   ; Version is 1
   ),
   assert(used_module_version(Module, Version)).

'~sharedPrograms.NextModuleVersion.P2'(Module, Version) :-
   'sharedPrograms.NextModuleVersion.P2'(Module, Version).


'sharedPrograms.SystemModuleRep.P4'(Module, Definition, Descriptor, PredDefs) :-
   user:system_module(Module, Definition, Descriptor, PredDefs).

'~sharedPrograms.SystemModuleRep.P4'(Module, Definition, Descriptor, PredDefs) :-
   'sharedPrograms.SystemModuleRep.P4'(Module, Definition, Descriptor, PredDefs).
%------------------------------------------------------------------------------
% Support for Type Checking
%------------------------------------------------------------------------------

'sharedPrograms.FixType.P3'(Type, N, NewN) :-
   ( var(Type) ->
     Type = 'MetaDefs.Par.F1'(N), NewN is N + 1
   ; nonvar_fix_type(Type, N, NewN)
   ).

'~sharedPrograms.FixType.P3'(Type, N, NewN) :-
   'sharedPrograms.FixType.P3'(Type, N, NewN).

nonvar_fix_type('MetaDefs.Par.F1'(_), N, N).

nonvar_fix_type('MetaDefs.Par.F2'(_, _), N, N).

nonvar_fix_type('MetaDefs.BType.F1'(_), N, N).

nonvar_fix_type('MetaDefs.Type.F2'(_, Args), N, NewN) :-
   list_fix_type(Args, N, NewN).


list_fix_type([], N, N).

list_fix_type([Type|Types], N, NewN) :-
   'sharedPrograms.FixType.P3'(Type, N, N1),
   list_fix_type(Types, N1, NewN).


'sharedPrograms.FixRationals.P2'([], 0).

'sharedPrograms.FixRationals.P2'([NumType|NumTypes], Count) :-
   fix_rational(NumType, R),
   'sharedPrograms.FixRationals.P2'(NumTypes, Count1),
   Count is Count1 + R.

'~sharedPrograms.FixRationals.P2'(NumTypes, Count) :-
   'sharedPrograms.FixRationals.P2'(NumTypes, Count).


fix_rational('sharedPrograms.NumType.F3'(Value, 'MetaDefs.BType.F1'(Name), Term)
      , Rational
      ) :-
   ( Name = 'MetaDefs.Name.F4'('"Rationals', '"Rational', 'MetaDefs.Base.C0', 0) ->
     'sharedPrograms.RationalTerm.P2'(Value, Term),
     Rational = 1
   ; Term = 'MetaDefs.Int.F1'(Value),
     Rational = 0
   ). 

%------------------------------------------------------------------------------
% Type Unification
%------------------------------------------------------------------------------
 
'sharedPrograms.UnifyMeltedTypes.P4'(ContextType, ArgType, Term, Errors) :-
   ( unify_types(ContextType, ArgType) ->
     Errors = []
   ; copy_term((ContextType, ArgType), (ContextTypeCopy, ArgTypeCopy)),
     'sharedPrograms.FixType.P3'(ArgTypeCopy, 0, N),
     'sharedPrograms.FixType.P3'(ContextTypeCopy, N, _),
     Errors = ['sharedPrograms.TypeError.F3'(Term, ArgTypeCopy, ContextTypeCopy)]
   ).

'~sharedPrograms.UnifyMeltedTypes.P4'(ContextType, ArgType, Term, Errors) :-
   'sharedPrograms.UnifyMeltedTypes.P4'(ContextType, ArgType, Term, Errors).

unify_types(Type1, Type2) :-
   ( nonvar(Type1) ->
     ( nonvar(Type2) ->
       nonvar_unify_types(Type1, Type2)
     ; not_occurs_in(Type1, Type2), Type2 = Type1
     )
   ; ( nonvar(Type2) ->
       not_occurs_in(Type2, Type1), Type1 = Type2
     ; Type1 = Type2
     )
   ).


nonvar_unify_types('MetaDefs.BType.F1'(Name), 'MetaDefs.BType.F1'(Name)).

nonvar_unify_types('MetaDefs.Type.F2'(Name, Args1), 
                   'MetaDefs.Type.F2'(Name, Args2)
                  ) :-   
   unify_type_lists(Args1, Args2).


unify_type_lists([], []).

unify_type_lists([Type1|Types1], [Type2|Types2]) :-
   unify_types(Type1, Type2),
   unify_type_lists(Types1, Types2).

 
not_occurs_in('MetaDefs.BType.F1'(_), _).

not_occurs_in('MetaDefs.Type.F2'(_, Args), Var) :-
   not_occurs_in_list(Args, Var).


not_occurs_in_list([], _).

not_occurs_in_list([Term|Terms], Var) :-
   ( var(Term) ->
     Term \== Var
   ; not_occurs_in(Term, Var)
   ),
   not_occurs_in_list(Terms, Var).

%------------------------------------------------------------------------------
% Conversion between delay conditions and strings
%------------------------------------------------------------------------------
 
'sharedPrograms.SStringToCondition.P2'(String, Condition) :-
   user:'Strings.StringInts.P2'(String, IntList),
   user:append(IntList, [0'.], Chars),
   user:get_one_item_2nd(Chars, [], Item),
   user:cond(Item, [], Condition, [], Error, 1, 2, local),
   var(Error).

'~sharedPrograms.SStringToCondition.P2'(String, Condition) :-
   'sharedPrograms.SStringToCondition.P2'(String, Condition).

%------------------------------------------------------------------------------
% Support for ground representation to String conversion
%------------------------------------------------------------------------------

'sharedPrograms.CharDL.P3'(Gstr, [Char|Chars], Chars) :-
   name(Gstr, [0'", Char]).

'~sharedPrograms.CharDL.P3'(Gstr, Chars, Chars1) :-
   'sharedPrograms.CharDL.P3'(Gstr, Chars, Chars1).


'sharedPrograms.ClassifyToken.P2'(Token, Class) :-
   name(Token, [0'", Sample|_]),
   ( 0'A =< Sample, Sample =< 0'Z ->
     Class = 'sharedPrograms.AlphaNum.C0'
   ; Class = 'sharedPrograms.Graphic.C0'
   ).

'~sharedPrograms.ClassifyToken.P2'(Token, Class) :-
   'sharedPrograms.ClassifyToken.P2'(Token, Class).

%------------------------------------------------------------------------------
% Support for symbol insertion routines
%------------------------------------------------------------------------------
 
'sharedPrograms.AddToDescriptorList.P6'(Descriptors, ModAccess, Category, Arity
      , NewDescriptor, [NewDescriptor|Descriptors]
      ) :-
   \+ 'sharedPrograms.FindDescriptor.P5'(Descriptors, ModAccess, Category, Arity
         , _Declaration).

'~sharedPrograms.AddToDescriptorList.P6'(Descriptors, ModAccess, Category, Arity
      , NewDescriptor, NewDescriptors
      ) :-
   'sharedPrograms.AddToDescriptorList.P6'(Descriptors, ModAccess, Category, Arity
      , NewDescriptor, NewDescriptors).

%------------------------------------------------------------------------------
% Variant types (used to check head condition)
%------------------------------------------------------------------------------
 
'sharedPrograms.VariantTypes.P4'(ContextType, ArgType, Term, Errors) :-
   ( variant_types(ContextType, ArgType, [], _) ->
     Errors = []
   ;
     copy_term((ContextType, ArgType), (ContextTypeCopy, ArgTypeCopy)),
     'sharedPrograms.FixType.P3'(ArgTypeCopy, 0, N),
     'sharedPrograms.FixType.P3'(ContextTypeCopy, N, _),
     Errors = ['sharedPrograms.HeadError.F3'(Term, ArgTypeCopy, ContextTypeCopy)]
   ).

'~sharedPrograms.VariantTypes.P4'(ContextType, ArgType, Term, Errors) :-
   'sharedPrograms.VariantTypes.P4'(ContextType, ArgType, Term, Errors).

variant_types(Type1, Type2, ParDict, NewParDict) :-
   ( var(Type1) ->
     var(Type2),
     ( in_par_dict(Type1, ParDict, Type1Alias) ->
       Type1Alias == Type2,
       NewParDict = ParDict
     ; NewParDict = [Type1/Type2|ParDict]
     )
   ; nonvar(Type2),
     nonvar_variant_types(Type1, Type2, ParDict, NewParDict)
   ).

nonvar_variant_types('MetaDefs.BType.F1'(Name), 'MetaDefs.BType.F1'(Name)
      , ParDict, ParDict).

nonvar_variant_types('MetaDefs.Type.F2'(Name, Args1)
      , 'MetaDefs.Type.F2'(Name, Args2), ParDict, NewParDict
      ) :-
   list_variant_types(Args1, Args2, ParDict, NewParDict).


list_variant_types([], [], ParDict, ParDict).

list_variant_types([Type1|Types1], [Type2|Types2], ParDict, NewParDict) :-
   variant_types(Type1, Type2, ParDict, ParDict1),
   list_variant_types(Types1, Types2, ParDict1, NewParDict).

in_par_dict(P1, [A1/A2|Entries], P2) :-
   ( P1 == A1 ->
     P2 = A2
   ; in_par_dict(P1, Entries, P2)
   ).
:- style_check(-singleton). % added djd
%% :- module('ProgramCache', []).
:- module(programCache).  % converted djd

:- discontiguous 'programCache.UnCacheProgram.P2'/2. %% added djd
:- discontiguous '~programCache.UnCacheProgram.P2'/2. %% added djd


:- op(500, yfx, and).
:- op(400, yfx, or).

'programCache.UnCacheProgram.P2'('ProgDefs.CachedProgram.F1'(A), B) :-
        'programCache.GetCachedProgram.P2'(A, B).
'~programCache.UnCacheProgram.P2'('ProgDefs.CachedProgram.F1'(A), B) :-
        '~programCache.GetCachedProgram.P2'(A, B).
'programCache.UnCacheProgram.P2'('ProgDefs.Program.F4'(A,B,C,D), 'ProgDefs.Program.F4'(A,B,C,D)).
'~programCache.UnCacheProgram.P2'('ProgDefs.Program.F4'(A,B,C,D), 'ProgDefs.Program.F4'(A,B,C,D)).
%------------------------------------------------------------------------------
% Program cache
%------------------------------------------------------------------------------

'programCache.GetCachedProgram.P2'(Main, Program) :-
   ( user:cached_program(Main, Cached) ->
     Program = Cached
   ; find_program(Main, Program),
     assert(user:cached_program(Main, Program))
   ).

'~programCache.GetCachedProgram.P2'(Main, Program) :-
   'programCache.GetCachedProgram.P2'(Main, Program).


find_program(Main, Program) :-
   'Strings':concat(Main, '".prm', GFile),
   user:gstring2string(GFile, File),
   ( open(File, read, Stream),
     user:readin_program(Stream, Object) ->
     Program = Object
   ; 'Strings':'Strings.StringInts.P2'(Main, Chars),
     format(user_error, 'ERROR: Couldn''t find cached object program ~s~n'
        , [Chars]),
     raise_exception(catch_in_query)  
   ).

:- style_check(-singleton). % added djd
%% :- module('Scripts', []).
:- module(scripts).   %% converted djd 

:- discontiguous 'scripts.DelayInKind.P4'/4. %% added djd
:- discontiguous '~scripts.DelayInKind.P4'/4. %% added djd
:- discontiguous 'scripts.HasIntensionalSet.P1'/1. %% added djd
:- discontiguous '~scripts.HasIntensionalSet.P1'/1. %% added djd
:- discontiguous 'scripts.OpenHeadPred.P2.0'/2. %% added djd
:- discontiguous '~scripts.OpenHeadPred.P2.0'/2. %% added djd
:- discontiguous 'scripts.ReformatDelays.P3'/3. %% added djd
:- discontiguous '~scripts.ReformatDelays.P3'/3. %% added djd
:- discontiguous 'scripts.SymbolInFormula.P2'/2. %% added djd
:- discontiguous '~scripts.SymbolInFormula.P2'/2. %% added djd
:- discontiguous 'scripts.SymbolInTerm.P2'/2. %% added djd
:- discontiguous '~scripts.SymbolInTerm.P2'/2. %% added djd
:- discontiguous 'scripts.ValidDeclaration.P2'/2. %% added djd
:- discontiguous '~scripts.ValidDeclaration.P2'/2. %% added djd

:- op(500, yfx, and).
:- op(400, yfx, or).

'scripts.FormulaInScript.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Scripts':'scripts.FormulaInScript.P4.0'(A,B,C,D)).
'~scripts.FormulaInScript.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Scripts':'~scripts.FormulaInScript.P4.0'(A,B,C,D)).
'scripts.FormulaInScript.P4.0'('scripts.Script.F5'(_,_,A,_,_), B, C, D) :-
        'SharedPrograms':'SharedPrograms.FormulaInLanguage.P4'(C, A, B, D).
'~scripts.FormulaInScript.P4.0'('scripts.Script.F5'(_,_,A,_,_), B, C, D) :-
        'SharedPrograms':'~SharedPrograms.FormulaInLanguage.P4'(C, A, B, D).
'scripts.ControlInScript.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A]), 'Scripts':'scripts.ControlInScript.P4.0'(A,B,C,D)).
'~scripts.ControlInScript.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A]), 'Scripts':'~scripts.ControlInScript.P4.0'(A,B,C,D)).
'scripts.ControlInScript.P4.0'('scripts.Script.F5'(_,A,_,_,B), 'MetaDefs.Name.F4'(C,D,'MetaDefs.Predicate.C0',E), F, G) :-
        'SharedPrograms':'SharedPrograms.AVLFind.P3'(B, C, 'ProgDefs.Code.F2'(_,H)),
        'SharedPrograms':'SharedPrograms.AVLFind.P3'(H, D, I),
        'SharedPrograms':'SharedPrograms.FindPredDef.P3'(E, I, 'ProgDefs.PredDef.F4'(E,_,J,K)),
        user:goedel_freeze(ground([C,A]), ('Scripts':'~scripts.ClosedModule.P2'(C,A),true->L=J;'Lists':'Lists.Append.P3'(J,K,L))),
        'scripts.ReformatDelays.P3'(L, F, G).
'~scripts.ControlInScript.P4.0'('scripts.Script.F5'(_,A,_,_,B), 'MetaDefs.Name.F4'(C,D,'MetaDefs.Predicate.C0',E), F, G) :-
        'SharedPrograms':'~SharedPrograms.AVLFind.P3'(B, C, 'ProgDefs.Code.F2'(_,H)),
        'SharedPrograms':'~SharedPrograms.AVLFind.P3'(H, D, I),
        'SharedPrograms':'~SharedPrograms.FindPredDef.P3'(E, I, 'ProgDefs.PredDef.F4'(E,_,J,K)),
        user:goedel_freeze(ground([C,A]), ('Scripts':'~scripts.ClosedModule.P2'(C,A),true->L=J;'Lists':'~Lists.Append.P3'(J,K,L))),
        '~scripts.ReformatDelays.P3'(L, F, G).
'scripts.ConstantInScript.P3'(A, B, C) :-
        user:goedel_freeze(ground([A]), 'Scripts':'scripts.ConstantInScript.P3.0'(A,B,C)).
'~scripts.ConstantInScript.P3'(A, B, C) :-
        user:goedel_freeze(ground([A]), 'Scripts':'~scripts.ConstantInScript.P3.0'(A,B,C)).
'scripts.ConstantInScript.P3.0'('scripts.Script.F5'(_,A,B,_,_), C, D) :-
        'scripts.SymbolInScript.P4'(C, B, A, 'ProgDefs.ConstantDecl.F1'(D)).
'~scripts.ConstantInScript.P3.0'('scripts.Script.F5'(_,A,B,_,_), C, D) :-
        '~scripts.SymbolInScript.P4'(C, B, A, 'ProgDefs.ConstantDecl.F1'(D)).
'scripts.BaseInScript.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Scripts':'scripts.BaseInScript.P2.0'(A,B)).
'~scripts.BaseInScript.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Scripts':'~scripts.BaseInScript.P2.0'(A,B)).
'scripts.BaseInScript.P2.0'('scripts.Script.F5'(_,A,B,_,_), C) :-
        'scripts.TypeSymbolInScriptLanguage.P4'(C, B, A, 'ProgDefs.BaseDecl.C0').
'~scripts.BaseInScript.P2.0'('scripts.Script.F5'(_,A,B,_,_), C) :-
        '~scripts.TypeSymbolInScriptLanguage.P4'(C, B, A, 'ProgDefs.BaseDecl.C0').
'scripts.ClosedModule.P2'(A, B) :-
        'AVLTrees':'AVLTrees.AVLSearch.P3'(B, A, 'ProgDefs.ModDef.F4'(C,_,_,_)),
        C='ProgDefs.ClosedKind.C0'.
'~scripts.ClosedModule.P2'(A, B) :-
        'AVLTrees':'~AVLTrees.AVLSearch.P3'(B, A, 'ProgDefs.ModDef.F4'(C,_,_,_)),
        C='ProgDefs.ClosedKind.C0'.
'scripts.ConstructorInScript.P3'(A, B, C) :-
        user:goedel_freeze(ground([A]), 'Scripts':'scripts.ConstructorInScript.P3.0'(A,B,C)).
'~scripts.ConstructorInScript.P3'(A, B, C) :-
        user:goedel_freeze(ground([A]), 'Scripts':'~scripts.ConstructorInScript.P3.0'(A,B,C)).
'scripts.ConstructorInScript.P3.0'('scripts.Script.F5'(_,A,B,_,_), C, D) :-
        'scripts.TypeSymbolInScriptLanguage.P4'(C, B, A, 'ProgDefs.ConstructorDecl.F1'(D)).
'~scripts.ConstructorInScript.P3.0'('scripts.Script.F5'(_,A,B,_,_), C, D) :-
        '~scripts.TypeSymbolInScriptLanguage.P4'(C, B, A, 'ProgDefs.ConstructorDecl.F1'(D)).
'scripts.DeleteScriptPredicate.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A]), 'Scripts':'scripts.DeleteScriptPredicate.P5.0'(A,B,C,D,E)).
'~scripts.DeleteScriptPredicate.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A]), 'Scripts':'~scripts.DeleteScriptPredicate.P5.0'(A,B,C,D,E)).
'scripts.DeleteScriptPredicate.P5.0'(A, B, C, D, E) :-
        'scripts.DelDeclaration.P4'(E, B, 'ProgDefs.PredicateDecl.F3'(_,C,D), A).
'~scripts.DeleteScriptPredicate.P5.0'(A, B, C, D, E) :-
        '~scripts.DelDeclaration.P4'(E, B, 'ProgDefs.PredicateDecl.F3'(_,C,D), A).
'scripts.DelayInScript.P3'(A, B, C) :-
        user:goedel_freeze(ground([A]), 'Scripts':'scripts.DelayInScript.P3.0'(A,B,C)).
'~scripts.DelayInScript.P3'(A, B, C) :-
        user:goedel_freeze(ground([A]), 'Scripts':'~scripts.DelayInScript.P3.0'(A,B,C)).
'scripts.DelayInScript.P3.0'('scripts.Script.F5'(_,A,_,_,B), C, D) :-
        C='MetaDefs.Atom.F2'('MetaDefs.Name.F4'(E,F,_,G),_),
        'SharedPrograms':'SharedPrograms.AVLFind.P3'(B, E, 'ProgDefs.Code.F2'(_,H)),
        'SharedPrograms':'SharedPrograms.AVLFind.P3'(H, F, I),
        'SharedPrograms':'SharedPrograms.FindPredDef.P3'(G, I, 'ProgDefs.PredDef.F4'(G,_,J,K)),
        'AVLTrees':'AVLTrees.AVLSearch.P3'(A, E, 'ProgDefs.ModDef.F4'(L,_,_,_)),
        'scripts.DelayInKind.P4'(L, J, K, 'ProgDefs.Delay.F2'(C,D)).
'~scripts.DelayInScript.P3.0'('scripts.Script.F5'(_,A,_,_,B), C, D) :-
        C='MetaDefs.Atom.F2'('MetaDefs.Name.F4'(E,F,_,G),_),
        'SharedPrograms':'~SharedPrograms.AVLFind.P3'(B, E, 'ProgDefs.Code.F2'(_,H)),
        'SharedPrograms':'~SharedPrograms.AVLFind.P3'(H, F, I),
        'SharedPrograms':'~SharedPrograms.FindPredDef.P3'(G, I, 'ProgDefs.PredDef.F4'(G,_,J,K)),
        'AVLTrees':'~AVLTrees.AVLSearch.P3'(A, E, 'ProgDefs.ModDef.F4'(L,_,_,_)),
        '~scripts.DelayInKind.P4'(L, J, K, 'ProgDefs.Delay.F2'(C,D)).
'scripts.DelDeclaration.P4'('scripts.Script.F5'(A,B,C,D,E), F, G, 'scripts.Script.F5'(A,B,H,D,E)) :-
        'scripts.DeleteSymbol.P5'(F, H, B, G, C),
        'scripts.FreeSymbol.P2'(F, E).
'~scripts.DelDeclaration.P4'('scripts.Script.F5'(A,B,C,D,E), F, G, 'scripts.Script.F5'(A,B,H,D,E)) :-
        '~scripts.DeleteSymbol.P5'(F, H, B, G, C),
        '~scripts.FreeSymbol.P2'(F, E).
'scripts.DefinitionInScript.P3'(A, B, C) :-
        user:goedel_freeze(ground([A]), 'Scripts':'scripts.DefinitionInScript.P3.0'(A,B,C)).
'~scripts.DefinitionInScript.P3'(A, B, C) :-
        user:goedel_freeze(ground([A]), 'Scripts':'~scripts.DefinitionInScript.P3.0'(A,B,C)).
'scripts.DefinitionInScript.P3.0'('scripts.Script.F5'(_,A,_,_,B), 'MetaDefs.Name.F4'(C,D,E,F), G) :-
        'SharedPrograms':'SharedPrograms.AVLFind.P3'(B, C, 'ProgDefs.Code.F2'(_,H)),
        user:goedel_freeze(ground([C,A]), user:goedel_not('Scripts':'~scripts.ClosedModule.P2'(C,A))),
        'SharedPrograms':'SharedPrograms.AVLFind.P3'(H, D, I),
        'SharedPrograms':'SharedPrograms.FindPredDef.P3'(F, I, 'ProgDefs.PredDef.F4'(F,G,_,_)),
        user:goedel_freeze(ground([F]), (F=0,true->E='MetaDefs.Proposition.C0';E='MetaDefs.Predicate.C0')).
'~scripts.DefinitionInScript.P3.0'('scripts.Script.F5'(_,A,_,_,B), 'MetaDefs.Name.F4'(C,D,E,F), G) :-
        'SharedPrograms':'~SharedPrograms.AVLFind.P3'(B, C, 'ProgDefs.Code.F2'(_,H)),
        user:goedel_freeze(ground([C,A]), user:goedel_not('Scripts':'~scripts.ClosedModule.P2'(C,A))),
        'SharedPrograms':'~SharedPrograms.AVLFind.P3'(H, D, I),
        'SharedPrograms':'~SharedPrograms.FindPredDef.P3'(F, I, 'ProgDefs.PredDef.F4'(F,G,_,_)),
        user:goedel_freeze(ground([F]), (F=0,true->E='MetaDefs.Proposition.C0';E='MetaDefs.Predicate.C0')).
'scripts.DelayInKind.P4'('ProgDefs.NormalKind.C0', A, B, C) :-
        (   'Lists':'Lists.Member.P2'(C, A)
        ;   'Lists':'Lists.Member.P2'(C, B)
        ).
'~scripts.DelayInKind.P4'('ProgDefs.NormalKind.C0', A, B, C) :-
        (   'Lists':'~Lists.Member.P2'(C, A)
        ;   'Lists':'~Lists.Member.P2'(C, B)
        ).
'scripts.DelayInKind.P4'('ProgDefs.ClosedKind.C0', A, _, B) :-
        'Lists':'Lists.Member.P2'(B, A).
'~scripts.DelayInKind.P4'('ProgDefs.ClosedKind.C0', A, _, B) :-
        'Lists':'~Lists.Member.P2'(B, A).
'scripts.DelayInKind.P4'('ProgDefs.ModuleKind.C0', _, A, B) :-
        'Lists':'Lists.Member.P2'(B, A).
'~scripts.DelayInKind.P4'('ProgDefs.ModuleKind.C0', _, A, B) :-
        'Lists':'~Lists.Member.P2'(B, A).
'scripts.DeleteDelay.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A]), 'Scripts':'scripts.DeleteDelay.P4.0'(A,B,C,D)).
'~scripts.DeleteDelay.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A]), 'Scripts':'~scripts.DeleteDelay.P4.0'(A,B,C,D)).
'scripts.DeleteDelay.P4.0'('scripts.Script.F5'(A,B,C,D,E), F, G, 'scripts.Script.F5'(A,B,C,D,H)) :-
        'Syntax':'Syntax.PredicateAtom.P3'(F, 'MetaDefs.Name.F4'(I,J,_,K), _),
        'SharedPrograms':'SharedPrograms.AVLFind.P3'(E, I, 'ProgDefs.Code.F2'(L,M)),
        user:goedel_freeze(ground([I,B]), user:goedel_not('Scripts':'~scripts.ClosedModule.P2'(I,B))),
        'SharedPrograms':'SharedPrograms.AVLFind.P3'(M, J, N),
        'SharedPrograms':'SharedPrograms.PickPredDef.P4'(K, N, 'ProgDefs.PredDef.F4'(K,O,P,Q), R),
        (   'SharedPrograms':'SharedPrograms.PickOne.P3'('ProgDefs.Delay.F2'(F,G), P, S),
            T=Q
        ;   'SharedPrograms':'SharedPrograms.PickOne.P3'('ProgDefs.Delay.F2'(F,G), Q, T),
            S=P
        ),
        user:goedel_freeze(ground([S,T,O]), ((O=[],S=[],T=[]),true->U=R;U=['ProgDefs.PredDef.F4'(K,O,S,T)|R])),
        user:goedel_freeze(ground([U]), (U=[],true->'AVLTrees':'AVLTrees.AVLDelete.P3'(M,J,V);'AVLTrees':'AVLTrees.AVLUpdate.P5'(M,J,U,V,_))),
        'AVLTrees':'AVLTrees.AVLUpdate.P5'(E, I, 'ProgDefs.Code.F2'(L,V), H, _).
'~scripts.DeleteDelay.P4.0'('scripts.Script.F5'(A,B,C,D,E), F, G, 'scripts.Script.F5'(A,B,C,D,H)) :-
        'Syntax':'~Syntax.PredicateAtom.P3'(F, 'MetaDefs.Name.F4'(I,J,_,K), _),
        'SharedPrograms':'~SharedPrograms.AVLFind.P3'(E, I, 'ProgDefs.Code.F2'(L,M)),
        user:goedel_freeze(ground([I,B]), user:goedel_not('Scripts':'~scripts.ClosedModule.P2'(I,B))),
        'SharedPrograms':'~SharedPrograms.AVLFind.P3'(M, J, N),
        'SharedPrograms':'~SharedPrograms.PickPredDef.P4'(K, N, 'ProgDefs.PredDef.F4'(K,O,P,Q), R),
        (   'SharedPrograms':'~SharedPrograms.PickOne.P3'('ProgDefs.Delay.F2'(F,G), P, S),
            T=Q
        ;   'SharedPrograms':'~SharedPrograms.PickOne.P3'('ProgDefs.Delay.F2'(F,G), Q, T),
            S=P
        ),
        user:goedel_freeze(ground([S,T,O]), ((O=[],S=[],T=[]),true->U=R;U=['ProgDefs.PredDef.F4'(K,O,S,T)|R])),
        user:goedel_freeze(ground([U]), (U=[],true->'AVLTrees':'~AVLTrees.AVLDelete.P3'(M,J,V);'AVLTrees':'~AVLTrees.AVLUpdate.P5'(M,J,U,V,_))),
        'AVLTrees':'~AVLTrees.AVLUpdate.P5'(E, I, 'ProgDefs.Code.F2'(L,V), H, _).
'scripts.DeleteStatement.P3'(A, B, C) :-
        user:goedel_freeze(ground([A]), 'Scripts':'scripts.DeleteStatement.P3.0'(A,B,C)).
'~scripts.DeleteStatement.P3'(A, B, C) :-
        user:goedel_freeze(ground([A]), 'Scripts':'~scripts.DeleteStatement.P3.0'(A,B,C)).
'scripts.DeleteStatement.P3.0'('scripts.Script.F5'(A,B,C,D,E), F, 'scripts.Script.F5'(A,B,C,D,G)) :-
        'scripts.OpenStatementPredicate.P2'(F, 'MetaDefs.Name.F4'(H,I,_,J)),
        'SharedPrograms':'SharedPrograms.AVLFind.P3'(E, H, 'ProgDefs.Code.F2'(K,L)),
        user:goedel_freeze(ground([H,B]), user:goedel_not('Scripts':'~scripts.ClosedModule.P2'(H,B))),
        'SharedPrograms':'SharedPrograms.AVLFind.P3'(L, I, M),
        'SharedPrograms':'SharedPrograms.PickPredDef.P4'(J, M, 'ProgDefs.PredDef.F4'(J,N,O,P), Q),
        'Lists':'Lists.Delete.P3'(F, N, R),
        user:goedel_freeze(ground([O,P,R]), ((R=[],O=[],P=[]),true->S=Q;S=['ProgDefs.PredDef.F4'(J,R,O,P)|Q])),
        user:goedel_freeze(ground([S]), (S=[],true->'AVLTrees':'AVLTrees.AVLDelete.P3'(L,I,T);'AVLTrees':'AVLTrees.AVLUpdate.P5'(L,I,S,T,_))),
        'AVLTrees':'AVLTrees.AVLUpdate.P5'(E, H, 'ProgDefs.Code.F2'(K,T), G, _).
'~scripts.DeleteStatement.P3.0'('scripts.Script.F5'(A,B,C,D,E), F, 'scripts.Script.F5'(A,B,C,D,G)) :-
        '~scripts.OpenStatementPredicate.P2'(F, 'MetaDefs.Name.F4'(H,I,_,J)),
        'SharedPrograms':'~SharedPrograms.AVLFind.P3'(E, H, 'ProgDefs.Code.F2'(K,L)),
        user:goedel_freeze(ground([H,B]), user:goedel_not('Scripts':'~scripts.ClosedModule.P2'(H,B))),
        'SharedPrograms':'~SharedPrograms.AVLFind.P3'(L, I, M),
        'SharedPrograms':'~SharedPrograms.PickPredDef.P4'(J, M, 'ProgDefs.PredDef.F4'(J,N,O,P), Q),
        'Lists':'~Lists.Delete.P3'(F, N, R),
        user:goedel_freeze(ground([O,P,R]), ((R=[],O=[],P=[]),true->S=Q;S=['ProgDefs.PredDef.F4'(J,R,O,P)|Q])),
        user:goedel_freeze(ground([S]), (S=[],true->'AVLTrees':'~AVLTrees.AVLDelete.P3'(L,I,T);'AVLTrees':'~AVLTrees.AVLUpdate.P5'(L,I,S,T,_))),
        'AVLTrees':'~AVLTrees.AVLUpdate.P5'(E, H, 'ProgDefs.Code.F2'(K,T), G, _).
'scripts.DeleteScriptProposition.P3'(A, B, C) :-
        user:goedel_freeze(ground([A]), 'Scripts':'scripts.DeleteScriptProposition.P3.0'(A,B,C)).
'~scripts.DeleteScriptProposition.P3'(A, B, C) :-
        user:goedel_freeze(ground([A]), 'Scripts':'~scripts.DeleteScriptProposition.P3.0'(A,B,C)).
'scripts.DeleteScriptProposition.P3.0'(A, B, C) :-
        'scripts.DelDeclaration.P4'(C, B, 'ProgDefs.PropositionDecl.C0', A).
'~scripts.DeleteScriptProposition.P3.0'(A, B, C) :-
        '~scripts.DelDeclaration.P4'(C, B, 'ProgDefs.PropositionDecl.C0', A).
'scripts.DeleteSymbol.P5'('MetaDefs.Name.F4'(A,B,C,D), 'ProgDefs.Language.F1'(E), F, G, 'ProgDefs.Language.F1'(H)) :-
        'SharedPrograms':'SharedPrograms.AVLFind.P3'(E, A, 'ProgDefs.Module.F3'(I,'ProgDefs.Categories.F2'(J,K),L)),
        user:goedel_freeze(ground([A,F]), user:goedel_not('Scripts':'~scripts.ClosedModule.P2'(A,F))),
        'SharedPrograms':'SharedPrograms.AVLFind.P3'(K, B, M),
        'SharedPrograms':'SharedPrograms.FindDescriptor.P5'(M, I, C, D, G),
        'Lists':'Lists.DeleteFirst.P3'('ProgDefs.Symbol.F2'(_,G), M, N),
        user:goedel_freeze(ground([N]), (N=[],true->'AVLTrees':'AVLTrees.AVLDelete.P3'(K,B,O);'AVLTrees':'AVLTrees.AVLUpdate.P5'(K,B,N,O,_))),
        'AVLTrees':'AVLTrees.AVLUpdate.P5'(E, A, 'ProgDefs.Module.F3'(I,'ProgDefs.Categories.F2'(J,O),L), H, _).
'~scripts.DeleteSymbol.P5'('MetaDefs.Name.F4'(A,B,C,D), 'ProgDefs.Language.F1'(E), F, G, 'ProgDefs.Language.F1'(H)) :-
        'SharedPrograms':'~SharedPrograms.AVLFind.P3'(E, A, 'ProgDefs.Module.F3'(I,'ProgDefs.Categories.F2'(J,K),L)),
        user:goedel_freeze(ground([A,F]), user:goedel_not('Scripts':'~scripts.ClosedModule.P2'(A,F))),
        'SharedPrograms':'~SharedPrograms.AVLFind.P3'(K, B, M),
        'SharedPrograms':'~SharedPrograms.FindDescriptor.P5'(M, I, C, D, G),
        'Lists':'~Lists.DeleteFirst.P3'('ProgDefs.Symbol.F2'(_,G), M, N),
        user:goedel_freeze(ground([N]), (N=[],true->'AVLTrees':'~AVLTrees.AVLDelete.P3'(K,B,O);'AVLTrees':'~AVLTrees.AVLUpdate.P5'(K,B,N,O,_))),
        'AVLTrees':'~AVLTrees.AVLUpdate.P5'(E, A, 'ProgDefs.Module.F3'(I,'ProgDefs.Categories.F2'(J,O),L), H, _).
'scripts.ProgramToScript.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Scripts':'scripts.ProgramToScript.P2.0'(A,B)).
'~scripts.ProgramToScript.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Scripts':'~scripts.ProgramToScript.P2.0'(A,B)).
'scripts.ProgramToScript.P2.0'(A, 'scripts.Script.F5'(B,C,D,E,F)) :-
        'ProgramCache':'ProgramCache.UnCacheProgram.P2'(A, G),
        'SharedPrograms':'SharedPrograms.ModuleLanguage.P3'(G, B, E),
        G='ProgDefs.Program.F4'(B,C,D,F).
'~scripts.ProgramToScript.P2.0'(A, 'scripts.Script.F5'(B,C,D,E,F)) :-
        'ProgramCache':'~ProgramCache.UnCacheProgram.P2'(A, G),
        'SharedPrograms':'~SharedPrograms.ModuleLanguage.P3'(G, B, E),
        G='ProgDefs.Program.F4'(B,C,D,F).
'scripts.InsertScriptProposition.P3'(A, B, C) :-
        user:goedel_freeze(ground([A,B]), 'Scripts':'scripts.InsertScriptProposition.P3.0'(A,B,C)).
'~scripts.InsertScriptProposition.P3'(A, B, C) :-
        user:goedel_freeze(ground([A,B]), 'Scripts':'~scripts.InsertScriptProposition.P3.0'(A,B,C)).
'scripts.InsertScriptProposition.P3.0'(A, B, C) :-
        'scripts.InsDeclaration.P4'(A, B, 'ProgDefs.PropositionDecl.C0', C).
'~scripts.InsertScriptProposition.P3.0'(A, B, C) :-
        '~scripts.InsDeclaration.P4'(A, B, 'ProgDefs.PropositionDecl.C0', C).
'scripts.InsDeclaration.P4'('scripts.Script.F5'(A,B,C,D,E), F, G, 'scripts.Script.F5'(A,B,H,D,E)) :-
        'scripts.ValidDeclaration.P2'(G, C),
        F='MetaDefs.Name.F4'(I,_,_,_),
        user:goedel_freeze(ground([I,B]), user:goedel_not('Scripts':'~scripts.ClosedModule.P2'(I,B))),
        'SharedPrograms':'SharedPrograms.InsertSymbol.P5'(F, C, 'ProgDefs.Exported.C0', G, H).
'~scripts.InsDeclaration.P4'('scripts.Script.F5'(A,B,C,D,E), F, G, 'scripts.Script.F5'(A,B,H,D,E)) :-
        '~scripts.ValidDeclaration.P2'(G, C),
        F='MetaDefs.Name.F4'(I,_,_,_),
        user:goedel_freeze(ground([I,B]), user:goedel_not('Scripts':'~scripts.ClosedModule.P2'(I,B))),
        'SharedPrograms':'~SharedPrograms.InsertSymbol.P5'(F, C, 'ProgDefs.Exported.C0', G, H).
'scripts.FunctionInScript.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A]), 'Scripts':'scripts.FunctionInScript.P5.0'(A,B,C,D,E)).
'~scripts.FunctionInScript.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A]), 'Scripts':'~scripts.FunctionInScript.P5.0'(A,B,C,D,E)).
'scripts.FunctionInScript.P5.0'('scripts.Script.F5'(_,A,B,_,_), C, D, E, F) :-
        'scripts.SymbolInScript.P4'(C, B, A, 'ProgDefs.FunctionDecl.F4'(_,D,E,F)).
'~scripts.FunctionInScript.P5.0'('scripts.Script.F5'(_,A,B,_,_), C, D, E, F) :-
        '~scripts.SymbolInScript.P4'(C, B, A, 'ProgDefs.FunctionDecl.F4'(_,D,E,F)).
'scripts.FreeSymbol.P2'(A, B) :-
        user:goedel_freeze(ground([B,A]), user:goedel_not(('AVLTrees':'~AVLTrees.AVLMember.P3'(B,_,C),user:goedel_freeze(ground([C,A]),user:goedel_not('Scripts':'~scripts.SymbolFreeInModuleCode.P2'(A,C)))))).
'~scripts.FreeSymbol.P2'(A, B) :-
        user:goedel_freeze(ground([B,A]), user:goedel_not(('AVLTrees':'~AVLTrees.AVLMember.P3'(B,_,C),user:goedel_freeze(ground([C,A]),user:goedel_not('Scripts':'~scripts.SymbolFreeInModuleCode.P2'(A,C)))))).
'scripts.HasIntensionalSet.P1'('MetaDefs.Term.F2'(_,A)) :-
        'scripts.HasIntensionalSet1.P1'(A).
'~scripts.HasIntensionalSet.P1'('MetaDefs.Term.F2'(_,A)) :-
        '~scripts.HasIntensionalSet1.P1'(A).
'scripts.HasIntensionalSet.P1'('MetaDefs.SuchThat.F2'(_,_)).
'~scripts.HasIntensionalSet.P1'('MetaDefs.SuchThat.F2'(_,_)).
'scripts.HasIntensionalSet1.P1'([A|B]) :-
        (   'scripts.HasIntensionalSet.P1'(A)
        ;   'scripts.HasIntensionalSet1.P1'(B)
        ).
'~scripts.HasIntensionalSet1.P1'([A|B]) :-
        (   '~scripts.HasIntensionalSet.P1'(A)
        ;   '~scripts.HasIntensionalSet1.P1'(B)
        ).
'scripts.InsertDelay.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Scripts':'scripts.InsertDelay.P4.0'(A,B,C,D)).
'~scripts.InsertDelay.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A,B,C]), 'Scripts':'~scripts.InsertDelay.P4.0'(A,B,C,D)).
'scripts.InsertDelay.P4.0'('scripts.Script.F5'(A,B,C,D,E), F, G, 'scripts.Script.F5'(A,B,C,D,H)) :-
        'Syntax':'Syntax.PredicateAtom.P3'(F, 'MetaDefs.Name.F4'(I,J,_,K), _),
        user:goedel_freeze(ground([I,B]), user:goedel_not('Scripts':'~scripts.ClosedModule.P2'(I,B))),
        'SharedPrograms':'SharedPrograms.FormulaInLanguage.P4'(F, C, 'MetaDefs.VarTyping.F1'([]), _),
        'scripts.IntensionalSetFree.P1'(F),
        'AVLTrees':'AVLTrees.AVLIsEmpty.P1'(L),
        'AVLTrees':'AVLTrees.AVLAmend.P6'(E, I, 'ProgDefs.Code.F2'(M,N), 'ProgDefs.Code.F2'(0,L), H, 'ProgDefs.Code.F2'(M,O)),
        'AVLTrees':'AVLTrees.AVLAmend.P6'(O, J, P, [], N, Q),
        user:goedel_freeze(ground([K,Q]), if(('Lists':'~Lists.DeleteFirst.P3'('ProgDefs.PredDef.F4'(K,R,S,T),Q,U),true),P=['ProgDefs.PredDef.F4'(K,R,S,['ProgDefs.Delay.F2'(F,G)|T])|U],P=['ProgDefs.PredDef.F4'(K,[],[],['ProgDefs.Delay.F2'(F,G)])|Q])).
'~scripts.InsertDelay.P4.0'('scripts.Script.F5'(A,B,C,D,E), F, G, 'scripts.Script.F5'(A,B,C,D,H)) :-
        'Syntax':'~Syntax.PredicateAtom.P3'(F, 'MetaDefs.Name.F4'(I,J,_,K), _),
        user:goedel_freeze(ground([I,B]), user:goedel_not('Scripts':'~scripts.ClosedModule.P2'(I,B))),
        'SharedPrograms':'~SharedPrograms.FormulaInLanguage.P4'(F, C, 'MetaDefs.VarTyping.F1'([]), _),
        '~scripts.IntensionalSetFree.P1'(F),
        'AVLTrees':'~AVLTrees.AVLIsEmpty.P1'(L),
        'AVLTrees':'~AVLTrees.AVLAmend.P6'(E, I, 'ProgDefs.Code.F2'(M,N), 'ProgDefs.Code.F2'(0,L), H, 'ProgDefs.Code.F2'(M,O)),
        'AVLTrees':'~AVLTrees.AVLAmend.P6'(O, J, P, [], N, Q),
        user:goedel_freeze(ground([K,Q]), if(('Lists':'~Lists.DeleteFirst.P3'('ProgDefs.PredDef.F4'(K,R,S,T),Q,U),true),P=['ProgDefs.PredDef.F4'(K,R,S,['ProgDefs.Delay.F2'(F,G)|T])|U],P=['ProgDefs.PredDef.F4'(K,[],[],['ProgDefs.Delay.F2'(F,G)])|Q])).
'scripts.InsertScriptPredicate.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A,B,C,D]), 'Scripts':'scripts.InsertScriptPredicate.P5.0'(A,B,C,D,E)).
'~scripts.InsertScriptPredicate.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A,B,C,D]), 'Scripts':'~scripts.InsertScriptPredicate.P5.0'(A,B,C,D,E)).
'scripts.InsertScriptPredicate.P5.0'(A, B, C, D, E) :-
        'scripts.InsDeclaration.P4'(A, B, 'ProgDefs.PredicateDecl.F3'(_,C,D), E).
'~scripts.InsertScriptPredicate.P5.0'(A, B, C, D, E) :-
        '~scripts.InsDeclaration.P4'(A, B, 'ProgDefs.PredicateDecl.F3'(_,C,D), E).
'scripts.OpenHeadPred.P2'(A, B) :-
        user:goedel_freeze(nonvar(A), 'Scripts':'scripts.OpenHeadPred.P2.0'(A,B)).
'~scripts.OpenHeadPred.P2'(A, B) :-
        user:goedel_freeze(nonvar(A), 'Scripts':'~scripts.OpenHeadPred.P2.0'(A,B)).
'scripts.OpenHeadPred.P2.0'('MetaDefs.PAtom.F1'(A), A).
'~scripts.OpenHeadPred.P2.0'('MetaDefs.PAtom.F1'(A), A).
'scripts.OpenHeadPred.P2.0'('MetaDefs.Atom.F2'(A,_), A).
'~scripts.OpenHeadPred.P2.0'('MetaDefs.Atom.F2'(A,_), A).
'scripts.InsertStatement.P3'(A, B, C) :-
        user:goedel_freeze(ground([A,B]), 'Scripts':'scripts.InsertStatement.P3.0'(A,B,C)).
'~scripts.InsertStatement.P3'(A, B, C) :-
        user:goedel_freeze(ground([A,B]), 'Scripts':'~scripts.InsertStatement.P3.0'(A,B,C)).
'scripts.InsertStatement.P3.0'('scripts.Script.F5'(A,B,C,D,E), F, 'scripts.Script.F5'(A,B,C,D,G)) :-
        'SharedPrograms':'SharedPrograms.StatementInLanguage.P5'(F, C, _, _, []),
        'scripts.OpenStatementPredicate.P2'(F, 'MetaDefs.Name.F4'(H,I,_,J)),
        user:goedel_freeze(ground([H,B]), user:goedel_not('Scripts':'~scripts.ClosedModule.P2'(H,B))),
        'AVLTrees':'AVLTrees.AVLIsEmpty.P1'(K),
        'AVLTrees':'AVLTrees.AVLAmend.P6'(E, H, 'ProgDefs.Code.F2'(L,M), 'ProgDefs.Code.F2'(0,K), G, 'ProgDefs.Code.F2'(L,N)),
        'AVLTrees':'AVLTrees.AVLAmend.P6'(N, I, O, [], M, P),
        user:goedel_freeze(ground([J,P]), if(('Lists':'~Lists.DeleteFirst.P3'('ProgDefs.PredDef.F4'(J,Q,R,S),P,T),true),O=['ProgDefs.PredDef.F4'(J,[F|Q],R,S)|T],O=['ProgDefs.PredDef.F4'(J,[F],[],[])|P])).
'~scripts.InsertStatement.P3.0'('scripts.Script.F5'(A,B,C,D,E), F, 'scripts.Script.F5'(A,B,C,D,G)) :-
        'SharedPrograms':'~SharedPrograms.StatementInLanguage.P5'(F, C, _, _, []),
        '~scripts.OpenStatementPredicate.P2'(F, 'MetaDefs.Name.F4'(H,I,_,J)),
        user:goedel_freeze(ground([H,B]), user:goedel_not('Scripts':'~scripts.ClosedModule.P2'(H,B))),
        'AVLTrees':'~AVLTrees.AVLIsEmpty.P1'(K),
        'AVLTrees':'~AVLTrees.AVLAmend.P6'(E, H, 'ProgDefs.Code.F2'(L,M), 'ProgDefs.Code.F2'(0,K), G, 'ProgDefs.Code.F2'(L,N)),
        'AVLTrees':'~AVLTrees.AVLAmend.P6'(N, I, O, [], M, P),
        user:goedel_freeze(ground([J,P]), if(('Lists':'~Lists.DeleteFirst.P3'('ProgDefs.PredDef.F4'(J,Q,R,S),P,T),true),O=['ProgDefs.PredDef.F4'(J,[F|Q],R,S)|T],O=['ProgDefs.PredDef.F4'(J,[F],[],[])|P])).
'scripts.IntensionalSetFree.P1'('MetaDefs.Atom.F2'(_,A)) :-
        user:goedel_freeze(ground([A]), user:goedel_not('Scripts':'~scripts.HasIntensionalSet1.P1'(A))).
'~scripts.IntensionalSetFree.P1'('MetaDefs.Atom.F2'(_,A)) :-
        user:goedel_freeze(ground([A]), user:goedel_not('Scripts':'~scripts.HasIntensionalSet1.P1'(A))).
'scripts.PredicateInScript.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A]), 'Scripts':'scripts.PredicateInScript.P4.0'(A,B,C,D)).
'~scripts.PredicateInScript.P4'(A, B, C, D) :-
        user:goedel_freeze(ground([A]), 'Scripts':'~scripts.PredicateInScript.P4.0'(A,B,C,D)).
'scripts.PredicateInScript.P4.0'('scripts.Script.F5'(_,A,B,_,_), C, D, E) :-
        'scripts.SymbolInScript.P4'(C, B, A, 'ProgDefs.PredicateDecl.F3'(_,D,E)).
'~scripts.PredicateInScript.P4.0'('scripts.Script.F5'(_,A,B,_,_), C, D, E) :-
        '~scripts.SymbolInScript.P4'(C, B, A, 'ProgDefs.PredicateDecl.F3'(_,D,E)).
'scripts.OpenStatementPredicate.P2'('MetaDefs.<-''.F2'(A,_), B) :-
        'scripts.OpenHeadPred.P2'(A, B).
'~scripts.OpenStatementPredicate.P2'('MetaDefs.<-''.F2'(A,_), B) :-
        '~scripts.OpenHeadPred.P2'(A, B).
'scripts.SymbolInScript.P4'('MetaDefs.Name.F4'(A,B,C,D), 'ProgDefs.Language.F1'(E), F, G) :-
        'SharedPrograms':'SharedPrograms.AVLFind.P3'(E, A, 'ProgDefs.Module.F3'(H,'ProgDefs.Categories.F2'(_,I),_)),
        'AVLTrees':'AVLTrees.AVLSearch.P3'(F, A, 'ProgDefs.ModDef.F4'(J,_,_,_)),
        user:goedel_freeze(ground([J]), (J='ProgDefs.ClosedKind.C0',true->H='ProgDefs.Exported.C0';H='ProgDefs.Hidden.C0')),
        'SharedPrograms':'SharedPrograms.AVLFind.P3'(I, B, K),
        'SharedPrograms':'SharedPrograms.FindDescriptor.P5'(K, H, C, D, G).
'~scripts.SymbolInScript.P4'('MetaDefs.Name.F4'(A,B,C,D), 'ProgDefs.Language.F1'(E), F, G) :-
        'SharedPrograms':'~SharedPrograms.AVLFind.P3'(E, A, 'ProgDefs.Module.F3'(H,'ProgDefs.Categories.F2'(_,I),_)),
        'AVLTrees':'~AVLTrees.AVLSearch.P3'(F, A, 'ProgDefs.ModDef.F4'(J,_,_,_)),
        user:goedel_freeze(ground([J]), (J='ProgDefs.ClosedKind.C0',true->H='ProgDefs.Exported.C0';H='ProgDefs.Hidden.C0')),
        'SharedPrograms':'~SharedPrograms.AVLFind.P3'(I, B, K),
        'SharedPrograms':'~SharedPrograms.FindDescriptor.P5'(K, H, C, D, G).
'scripts.SymbolFreeInModuleCode.P2'(A, 'ProgDefs.Code.F2'(_,B)) :-
        user:goedel_freeze(ground([A,B]), user:goedel_not((('AVLTrees':'~AVLTrees.AVLMember.P3'(B,_,C),'Lists':'~Lists.Member.P2'('ProgDefs.PredDef.F4'(_,D,E,F),C)),('Lists':'~Lists.Member.P2'(G,D),'Scripts':'~scripts.SymbolInFormula.P2'(G,A);'Lists':'~Lists.Member.P2'(H,E),'Scripts':'~scripts.SymbolInDelay.P2'(H,A);'Lists':'~Lists.Member.P2'(I,F),'Scripts':'~scripts.SymbolInDelay.P2'(I,A))))).
'~scripts.SymbolFreeInModuleCode.P2'(A, 'ProgDefs.Code.F2'(_,B)) :-
        user:goedel_freeze(ground([A,B]), user:goedel_not((('AVLTrees':'~AVLTrees.AVLMember.P3'(B,_,C),'Lists':'~Lists.Member.P2'('ProgDefs.PredDef.F4'(_,D,E,F),C)),('Lists':'~Lists.Member.P2'(G,D),'Scripts':'~scripts.SymbolInFormula.P2'(G,A);'Lists':'~Lists.Member.P2'(H,E),'Scripts':'~scripts.SymbolInDelay.P2'(H,A);'Lists':'~Lists.Member.P2'(I,F),'Scripts':'~scripts.SymbolInDelay.P2'(I,A))))).
'scripts.StatementInScript.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Scripts':'scripts.StatementInScript.P2.0'(A,B)).
'~scripts.StatementInScript.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Scripts':'~scripts.StatementInScript.P2.0'(A,B)).
'scripts.StatementInScript.P2.0'(A, B) :-
        'scripts.OpenStatementPredicate.P2'(B, C),
        'scripts.DefinitionInScript.P3'(A, C, D),
        'Lists':'Lists.Member.P2'(B, D).
'~scripts.StatementInScript.P2.0'(A, B) :-
        '~scripts.OpenStatementPredicate.P2'(B, C),
        '~scripts.DefinitionInScript.P3'(A, C, D),
        'Lists':'~Lists.Member.P2'(B, D).
'scripts.PropositionInScript.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Scripts':'scripts.PropositionInScript.P2.0'(A,B)).
'~scripts.PropositionInScript.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'Scripts':'~scripts.PropositionInScript.P2.0'(A,B)).
'scripts.PropositionInScript.P2.0'('scripts.Script.F5'(_,A,B,_,_), C) :-
        'scripts.SymbolInScript.P4'(C, B, A, 'ProgDefs.PropositionDecl.C0').
'~scripts.PropositionInScript.P2.0'('scripts.Script.F5'(_,A,B,_,_), C) :-
        '~scripts.SymbolInScript.P4'(C, B, A, 'ProgDefs.PropositionDecl.C0').
'scripts.ReformatDelays.P3'([], [], []).
'~scripts.ReformatDelays.P3'([], [], []).
'scripts.ReformatDelays.P3'(['ProgDefs.Delay.F2'(B,C)|A], [B|D], [C|E]) :-
        'scripts.ReformatDelays.P3'(A, D, E).
'~scripts.ReformatDelays.P3'(['ProgDefs.Delay.F2'(B,C)|A], [B|D], [C|E]) :-
        '~scripts.ReformatDelays.P3'(A, D, E).
'scripts.StatementMatchAtom.P3'(A, B, C) :-
        user:goedel_freeze(ground([A,B]), 'Scripts':'scripts.StatementMatchAtom.P3.0'(A,B,C)).
'~scripts.StatementMatchAtom.P3'(A, B, C) :-
        user:goedel_freeze(ground([A,B]), 'Scripts':'~scripts.StatementMatchAtom.P3.0'(A,B,C)).
'scripts.StatementMatchAtom.P3.0'('scripts.Script.F5'(_,A,B,_,C), D, E) :-
        'scripts.OpenHeadPred.P2'(D, 'MetaDefs.Name.F4'(F,G,_,H)),
        'SharedPrograms':'SharedPrograms.FormulaInLanguage.P4'(D, B, 'MetaDefs.VarTyping.F1'([]), _),
        user:goedel_freeze(ground([F,A]), user:goedel_not('Scripts':'~scripts.ClosedModule.P2'(F,A))),
        'AVLTrees':'AVLTrees.AVLSearch.P3'(C, F, 'ProgDefs.Code.F2'(_,I)),
        'AVLTrees':'AVLTrees.AVLSearch.P3'(I, G, J),
        'Lists':'Lists.MemberCheck.P2'('ProgDefs.PredDef.F4'(H,K,_,_), J),
        'Lists':'Lists.Member.P2'(E, K).
'~scripts.StatementMatchAtom.P3.0'('scripts.Script.F5'(_,A,B,_,C), D, E) :-
        '~scripts.OpenHeadPred.P2'(D, 'MetaDefs.Name.F4'(F,G,_,H)),
        'SharedPrograms':'~SharedPrograms.FormulaInLanguage.P4'(D, B, 'MetaDefs.VarTyping.F1'([]), _),
        user:goedel_freeze(ground([F,A]), user:goedel_not('Scripts':'~scripts.ClosedModule.P2'(F,A))),
        'AVLTrees':'~AVLTrees.AVLSearch.P3'(C, F, 'ProgDefs.Code.F2'(_,I)),
        'AVLTrees':'~AVLTrees.AVLSearch.P3'(I, G, J),
        'Lists':'~Lists.MemberCheck.P2'('ProgDefs.PredDef.F4'(H,K,_,_), J),
        'Lists':'~Lists.Member.P2'(E, K).
'scripts.SymbolInFormula.P2'('MetaDefs.PAtom.F1'(A), A).
'~scripts.SymbolInFormula.P2'('MetaDefs.PAtom.F1'(A), A).
'scripts.SymbolInFormula.P2'('MetaDefs.Atom.F2'(A,B), C) :-
        (   C=A
        ;   'scripts.SymbolInTermList.P2'(B, C)
        ).
'~scripts.SymbolInFormula.P2'('MetaDefs.Atom.F2'(A,B), C) :-
        (   C=A
        ;   '~scripts.SymbolInTermList.P2'(B, C)
        ).
'scripts.SymbolInFormula.P2'('MetaDefs.~''.F1'(A), B) :-
        'scripts.SymbolInFormula.P2'(A, B).
'~scripts.SymbolInFormula.P2'('MetaDefs.~''.F1'(A), B) :-
        '~scripts.SymbolInFormula.P2'(A, B).
'scripts.SymbolInFormula.P2'('MetaDefs.&''.F2'(A,B), C) :-
        (   'scripts.SymbolInFormula.P2'(A, C)
        ;   'scripts.SymbolInFormula.P2'(B, C)
        ).
'~scripts.SymbolInFormula.P2'('MetaDefs.&''.F2'(A,B), C) :-
        (   '~scripts.SymbolInFormula.P2'(A, C)
        ;   '~scripts.SymbolInFormula.P2'(B, C)
        ).
'scripts.SymbolInFormula.P2'('MetaDefs.\\/''.F2'(A,B), C) :-   % added \ djd
        (   'scripts.SymbolInFormula.P2'(A, C)
        ;   'scripts.SymbolInFormula.P2'(B, C)
        ).
'~scripts.SymbolInFormula.P2'('MetaDefs.\\/''.F2'(A,B), C) :-   % added \ djd
        (   '~scripts.SymbolInFormula.P2'(A, C)
        ;   '~scripts.SymbolInFormula.P2'(B, C)
        ).
'scripts.SymbolInFormula.P2'('MetaDefs.->''.F2'(A,B), C) :-
        (   'scripts.SymbolInFormula.P2'(A, C)
        ;   'scripts.SymbolInFormula.P2'(B, C)
        ).
'~scripts.SymbolInFormula.P2'('MetaDefs.->''.F2'(A,B), C) :-
        (   '~scripts.SymbolInFormula.P2'(A, C)
        ;   '~scripts.SymbolInFormula.P2'(B, C)
        ).
'scripts.SymbolInFormula.P2'('MetaDefs.<-''.F2'(A,B), C) :-
        (   'scripts.SymbolInFormula.P2'(A, C)
        ;   'scripts.SymbolInFormula.P2'(B, C)
        ).
'~scripts.SymbolInFormula.P2'('MetaDefs.<-''.F2'(A,B), C) :-
        (   '~scripts.SymbolInFormula.P2'(A, C)
        ;   '~scripts.SymbolInFormula.P2'(B, C)
        ).
'scripts.SymbolInFormula.P2'('MetaDefs.<->''.F2'(A,B), C) :-
        (   'scripts.SymbolInFormula.P2'(A, C)
        ;   'scripts.SymbolInFormula.P2'(B, C)
        ).
'~scripts.SymbolInFormula.P2'('MetaDefs.<->''.F2'(A,B), C) :-
        (   '~scripts.SymbolInFormula.P2'(A, C)
        ;   '~scripts.SymbolInFormula.P2'(B, C)
        ).
'scripts.SymbolInFormula.P2'('MetaDefs.All.F2'(_,A), B) :-
        'scripts.SymbolInFormula.P2'(A, B).
'~scripts.SymbolInFormula.P2'('MetaDefs.All.F2'(_,A), B) :-
        '~scripts.SymbolInFormula.P2'(A, B).
'scripts.SymbolInFormula.P2'('MetaDefs.Some.F2'(_,A), B) :-
        'scripts.SymbolInFormula.P2'(A, B).
'~scripts.SymbolInFormula.P2'('MetaDefs.Some.F2'(_,A), B) :-
        '~scripts.SymbolInFormula.P2'(A, B).
'scripts.SymbolInFormula.P2'('MetaDefs.ISTE.F4'(_,A,B,C), D) :-
        (   'scripts.SymbolInFormula.P2'(A, D)
        ;   'scripts.SymbolInFormula.P2'(B, D)
        ;   'scripts.SymbolInFormula.P2'(C, D)
        ).
'~scripts.SymbolInFormula.P2'('MetaDefs.ISTE.F4'(_,A,B,C), D) :-
        (   '~scripts.SymbolInFormula.P2'(A, D)
        ;   '~scripts.SymbolInFormula.P2'(B, D)
        ;   '~scripts.SymbolInFormula.P2'(C, D)
        ).
'scripts.SymbolInFormula.P2'('MetaDefs.ITE.F3'(A,B,C), D) :-
        (   'scripts.SymbolInFormula.P2'(A, D)
        ;   'scripts.SymbolInFormula.P2'(B, D)
        ;   'scripts.SymbolInFormula.P2'(C, D)
        ).
'~scripts.SymbolInFormula.P2'('MetaDefs.ITE.F3'(A,B,C), D) :-
        (   '~scripts.SymbolInFormula.P2'(A, D)
        ;   '~scripts.SymbolInFormula.P2'(B, D)
        ;   '~scripts.SymbolInFormula.P2'(C, D)
        ).
'scripts.SymbolInFormula.P2'('MetaDefs.IST.F3'(_,A,B), C) :-
        (   'scripts.SymbolInFormula.P2'(A, C)
        ;   'scripts.SymbolInFormula.P2'(B, C)
        ).
'~scripts.SymbolInFormula.P2'('MetaDefs.IST.F3'(_,A,B), C) :-
        (   '~scripts.SymbolInFormula.P2'(A, C)
        ;   '~scripts.SymbolInFormula.P2'(B, C)
        ).
'scripts.SymbolInFormula.P2'('MetaDefs.IT.F2'(A,B), C) :-
        (   'scripts.SymbolInFormula.P2'(A, C)
        ;   'scripts.SymbolInFormula.P2'(B, C)
        ).
'~scripts.SymbolInFormula.P2'('MetaDefs.IT.F2'(A,B), C) :-
        (   '~scripts.SymbolInFormula.P2'(A, C)
        ;   '~scripts.SymbolInFormula.P2'(B, C)
        ).
'scripts.SymbolInDelay.P2'('ProgDefs.Delay.F2'(A,_), B) :-
        'scripts.SymbolInFormula.P2'(A, B).
'~scripts.SymbolInDelay.P2'('ProgDefs.Delay.F2'(A,_), B) :-
        '~scripts.SymbolInFormula.P2'(A, B).
'scripts.TermInScript.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A,B,C]), 'Scripts':'scripts.TermInScript.P5.0'(A,B,C,D,E)).
'~scripts.TermInScript.P5'(A, B, C, D, E) :-
        user:goedel_freeze(ground([A,B,C]), 'Scripts':'~scripts.TermInScript.P5.0'(A,B,C,D,E)).
'scripts.TermInScript.P5.0'('scripts.Script.F5'(_,_,A,_,_), B, C, D, E) :-
        'SharedPrograms':'SharedPrograms.TermInLanguage.P5'(C, A, B, E, D).
'~scripts.TermInScript.P5.0'('scripts.Script.F5'(_,_,A,_,_), B, C, D, E) :-
        'SharedPrograms':'~SharedPrograms.TermInLanguage.P5'(C, A, B, E, D).
'scripts.SymbolInTermList.P2'([A|B], C) :-
        (   'scripts.SymbolInTerm.P2'(A, C)
        ;   'scripts.SymbolInTermList.P2'(B, C)
        ).
'~scripts.SymbolInTermList.P2'([A|B], C) :-
        (   '~scripts.SymbolInTerm.P2'(A, C)
        ;   '~scripts.SymbolInTermList.P2'(B, C)
        ).
'scripts.SymbolInTerm.P2'('MetaDefs.CTerm.F1'(A), A).
'~scripts.SymbolInTerm.P2'('MetaDefs.CTerm.F1'(A), A).
'scripts.SymbolInTerm.P2'('MetaDefs.Term.F2'(A,B), C) :-
        (   A=C
        ;   'scripts.SymbolInTermList.P2'(B, C)
        ).
'~scripts.SymbolInTerm.P2'('MetaDefs.Term.F2'(A,B), C) :-
        (   A=C
        ;   '~scripts.SymbolInTermList.P2'(B, C)
        ).
'scripts.SymbolInTerm.P2'('MetaDefs.SuchThat.F2'(A,B), C) :-
        (   'scripts.SymbolInTerm.P2'(A, C)
        ;   'scripts.SymbolInFormula.P2'(B, C)
        ).
'~scripts.SymbolInTerm.P2'('MetaDefs.SuchThat.F2'(A,B), C) :-
        (   '~scripts.SymbolInTerm.P2'(A, C)
        ;   '~scripts.SymbolInFormula.P2'(B, C)
        ).
'scripts.TypeSymbolInScriptLanguage.P4'('MetaDefs.Name.F4'(A,B,C,D), 'ProgDefs.Language.F1'(E), F, G) :-
        'SharedPrograms':'SharedPrograms.AVLFind.P3'(E, A, 'ProgDefs.Module.F3'(_,'ProgDefs.Categories.F2'(H,_),_)),
        'AVLTrees':'AVLTrees.AVLSearch.P3'(F, A, 'ProgDefs.ModDef.F4'(I,_,_,_)),
        user:goedel_freeze(ground([I]), (I='ProgDefs.ClosedKind.C0',true->J='ProgDefs.Exported.C0';J='ProgDefs.Hidden.C0')),
        'SharedPrograms':'SharedPrograms.AVLFind.P3'(H, B, K),
        'SharedPrograms':'SharedPrograms.FindDescriptor.P5'(K, J, C, D, G).
'~scripts.TypeSymbolInScriptLanguage.P4'('MetaDefs.Name.F4'(A,B,C,D), 'ProgDefs.Language.F1'(E), F, G) :-
        'SharedPrograms':'~SharedPrograms.AVLFind.P3'(E, A, 'ProgDefs.Module.F3'(_,'ProgDefs.Categories.F2'(H,_),_)),
        'AVLTrees':'~AVLTrees.AVLSearch.P3'(F, A, 'ProgDefs.ModDef.F4'(I,_,_,_)),
        user:goedel_freeze(ground([I]), (I='ProgDefs.ClosedKind.C0',true->J='ProgDefs.Exported.C0';J='ProgDefs.Hidden.C0')),
        'SharedPrograms':'~SharedPrograms.AVLFind.P3'(H, B, K),
        'SharedPrograms':'~SharedPrograms.FindDescriptor.P5'(K, J, C, D, G).
'scripts.TypeInScript.P2'(A, B) :-
        user:goedel_freeze(ground([A,B]), 'Scripts':'scripts.TypeInScript.P2.0'(A,B)).
'~scripts.TypeInScript.P2'(A, B) :-
        user:goedel_freeze(ground([A,B]), 'Scripts':'~scripts.TypeInScript.P2.0'(A,B)).
'scripts.TypeInScript.P2.0'('scripts.Script.F5'(_,_,A,_,_), B) :-
        'SharedPrograms':'SharedPrograms.TypeInLanguage.P2'(B, A).
'~scripts.TypeInScript.P2.0'('scripts.Script.F5'(_,_,A,_,_), B) :-
        'SharedPrograms':'~SharedPrograms.TypeInLanguage.P2'(B, A).
'scripts.ValidDeclaration.P2'('ProgDefs.PropositionDecl.C0', _).
'~scripts.ValidDeclaration.P2'('ProgDefs.PropositionDecl.C0', _).
'scripts.ValidDeclaration.P2'('ProgDefs.PredicateDecl.F3'(_,_,A), B) :-
        'SharedPrograms':'SharedPrograms.ListTypesInLanguage.P2'(A, B).
'~scripts.ValidDeclaration.P2'('ProgDefs.PredicateDecl.F3'(_,_,A), B) :-
        'SharedPrograms':'~SharedPrograms.ListTypesInLanguage.P2'(A, B).
:- style_check(-singleton). % added djd
%% :- module('ScriptsIO', []).
:- module(scriptsIO).  %% converted djd

:- op(500, yfx, and).
:- op(400, yfx, or).

/* 
File:		ScriptsIO.sup
Subject:	Implemention of the system module ScriptsIO
Author: 	Jiwei Wang
Date:		7 April 1992

================================================================================
*/

%% '$$module'('@(#)ScriptsIO.sup 1.4 last updated 93/05/22 23:56:01 by jiwei').

:- module(scriptsIO_sup). %% converted djd


/*------------------------------------------------------------------------------
 */

'ScriptsIO.GetScript.P2'(Stream, Script) :-
	user:goedel_freeze(ground([Stream]),
		'ScriptsIO':'ScriptsIO.GetScript.P2.0'(Stream, Script)).

'~ScriptsIO.GetScript.P2'(Stream, Script) :-
	'ScriptsIO.GetScript.P2'(Stream, Script).

/*- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 */

'ScriptsIO.GetScript.P2.0'(Stream, Script) :-
   'IO':translate_stream(Stream, PrologStream),
   readin_script(PrologStream, Script), !.

readin_script(Stream, Script) :-
   ( user:file_version(V),
     read(Stream, version(V, scr)) 		% test the version number
     -> Script = 'Scripts.Script.F5'(MainModuleName, ModuleDefAVL, Language,
			GoalLanguage, Code),
	read(Stream, MainModuleName),
	read(Stream, ModuleDefAVL),
	read(Stream, Language),
	read(Stream, GoalLanguage),
	read(Stream, Code)
     ;  format(user_error, 'Error: ".scr" file is out of date.~n', []),
	fail
   ).

/*------------------------------------------------------------------------------
 */

'ScriptsIO.PutScript.P2'(Stream, Script) :-
   user:goedel_freeze(ground([Stream,Script]),
		'ScriptsIO':'ScriptsIO.PutScript.P2.0'(Stream, Script)).

'~ScriptsIO.PutScript.P2'(Stream, Script) :-
   'ScriptsIO.PutScript.P2'(Stream, Script).

/*- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
 */

'ScriptsIO.PutScript.P2.0'(Stream, Script) :-
   'IO':translate_stream(Stream, PrologStream),
   Script = 'Scripts.Script.F5'(MainModuleName, ModuleDefAVL, Language,
				GoalLanguage, Code),
   user:file_version(V),
   format(PrologStream, 'version(''~a'', scr).~n', [V]), 
   write_canonical(PrologStream, MainModuleName),
   format(PrologStream, '.~n', []),
   write_canonical(PrologStream, ModuleDefAVL),
   format(PrologStream, '.~n', []),
   write_canonical(PrologStream, Language),
   format(PrologStream, '.~n', []),
   write_canonical(PrologStream, GoalLanguage),
   format(PrologStream, '.~n', []),
   write_canonical(PrologStream, Code),
   format(PrologStream, '.~n', []).
:- style_check(-singleton). % added djd
%% :- module('AVLTrees', []).
:- module(aVLTrees).  %% converted djd

:- discontiguous 'aVLTrees.Adjustment.P4'/4. %% added djd
:- discontiguous '~aVLTrees.Adjustment.P4'/4. %% added djd
:- discontiguous 'aVLTrees.AVLSearch.P3.0'/3. %% added djd
:- discontiguous '~aVLTrees.AVLSearch.P3.0'/3. %% added djd
:- discontiguous 'aVLTrees.AVLMember.P3.0'/3. %% added djd
:- discontiguous '~aVLTrees.AVLMember.P3.0'/3. %% added djd
:- discontiguous 'aVLTrees.AVLJoinAux.P3'/3. %% added djd
:- discontiguous '~aVLTrees.AVLJoinAux.P3'/3. %% added djd
:- discontiguous 'aVLTrees.AVLUpdate.P5.0'/5. %% added djd
:- discontiguous '~aVLTrees.AVLUpdate.P5.0'/5. %% added djd
:- discontiguous 'aVLTrees.AVLToBinary.P2.0'/2. %% added djd
:- discontiguous '~aVLTrees.AVLToBinary.P2.0'/2. %% added djd
:- discontiguous 'aVLTrees.Adjust.P6'/6. %% added djd
:- discontiguous '~aVLTrees.Adjust.P6'/6. %% added djd
:- discontiguous 'aVLTrees.DeleteKey.P4'/4. %% added djd
:- discontiguous '~aVLTrees.DeleteKey.P4'/4. %% added djd
:- discontiguous 'aVLTrees.BalanceTable2.P3'/3. %% added djd
:- discontiguous '~aVLTrees.BalanceTable2.P3'/3. %% added djd
:- discontiguous 'aVLTrees.BalanceTable1.P3'/3. %% added djd
:- discontiguous '~aVLTrees.BalanceTable1.P3'/3. %% added djd
:- discontiguous 'aVLTrees.Amend.P7'/7. %% added djd
:- discontiguous '~aVLTrees.Amend.P7'/7. %% added djd
:- discontiguous 'aVLTrees.Combine.P5'/5. %% added djd
:- discontiguous '~aVLTrees.Combine.P5'/5. %% added djd
:- discontiguous 'aVLTrees.Insert.P5'/5. %% added djd
:- discontiguous '~aVLTrees.Insert.P5'/5. %% added djd
:- discontiguous 'aVLTrees.HeightIncreased.P3'/3. %% added djd
:- discontiguous '~aVLTrees.HeightIncreased.P3'/3. %% added djd
:- discontiguous 'aVLTrees.HeightDecreased.P3'/3. %% added djd
:- discontiguous '~aVLTrees.HeightDecreased.P3'/3. %% added djd
:- discontiguous 'aVLTrees.RemoveRightmost.P5'/5. %% added djd
:- discontiguous '~aVLTrees.RemoveRightmost.P5'/5. %% added djd
:- discontiguous 'aVLTrees.Rebalance.P4'/4. %% added djd
:- discontiguous '~aVLTrees.Rebalance.P4'/4. %% added djd
:- discontiguous 'aVLTrees.Restructure.P3'/3. %% added djd
:- discontiguous '~aVLTrees.Restructure.P3'/3. %% added djd



:- op(500, yfx, and).
:- op(400, yfx, or).

'aVLTrees.Adjustment.P4'('aVLTrees.EQ.C0', 'aVLTrees.Left.C0', 'aVLTrees.LH.C0', 'aVLTrees.No.C0') :- !.
'~aVLTrees.Adjustment.P4'('aVLTrees.EQ.C0', 'aVLTrees.Left.C0', 'aVLTrees.LH.C0', 'aVLTrees.No.C0').
'aVLTrees.Adjustment.P4'('aVLTrees.EQ.C0', 'aVLTrees.Right.C0', 'aVLTrees.RH.C0', 'aVLTrees.No.C0') :- !.
'~aVLTrees.Adjustment.P4'('aVLTrees.EQ.C0', 'aVLTrees.Right.C0', 'aVLTrees.RH.C0', 'aVLTrees.No.C0').
'aVLTrees.Adjustment.P4'('aVLTrees.LH.C0', 'aVLTrees.Left.C0', _, 'aVLTrees.Yes.C0') :- !.
'~aVLTrees.Adjustment.P4'('aVLTrees.LH.C0', 'aVLTrees.Left.C0', _, 'aVLTrees.Yes.C0').
'aVLTrees.Adjustment.P4'('aVLTrees.LH.C0', 'aVLTrees.Right.C0', 'aVLTrees.EQ.C0', 'aVLTrees.No.C0') :- !.
'~aVLTrees.Adjustment.P4'('aVLTrees.LH.C0', 'aVLTrees.Right.C0', 'aVLTrees.EQ.C0', 'aVLTrees.No.C0').
'aVLTrees.Adjustment.P4'('aVLTrees.RH.C0', 'aVLTrees.Left.C0', 'aVLTrees.EQ.C0', 'aVLTrees.No.C0') :- !.
'~aVLTrees.Adjustment.P4'('aVLTrees.RH.C0', 'aVLTrees.Left.C0', 'aVLTrees.EQ.C0', 'aVLTrees.No.C0').
'aVLTrees.Adjustment.P4'('aVLTrees.RH.C0', 'aVLTrees.Right.C0', _, 'aVLTrees.Yes.C0') :- !.
'~aVLTrees.Adjustment.P4'('aVLTrees.RH.C0', 'aVLTrees.Right.C0', _, 'aVLTrees.Yes.C0').
'aVLTrees.AVLJoin.P3'(A, B, C) :-
        user:goedel_freeze(nonvar(A)and nonvar(B), 'AVLTrees':'aVLTrees.AVLJoin.P3.0'(A,B,C)).
'~aVLTrees.AVLJoin.P3'(A, B, C) :-
        user:goedel_freeze(nonvar(A)and nonvar(B), 'AVLTrees':'~aVLTrees.AVLJoin.P3.0'(A,B,C)).
'aVLTrees.AVLJoin.P3.0'(A, B, C) :-
        'aVLTrees.AVLJoinAux.P3'(B, A, C).
'~aVLTrees.AVLJoin.P3.0'(A, B, C) :-
        '~aVLTrees.AVLJoinAux.P3'(B, A, C).
'aVLTrees.AVLInsert.P4'(A, B, C, D) :-
        user:goedel_freeze(nonvar(A)and ground([B]), 'AVLTrees':'aVLTrees.AVLInsert.P4.0'(A,B,C,D)).
'~aVLTrees.AVLInsert.P4'(A, B, C, D) :-
        user:goedel_freeze(nonvar(A)and ground([B]), 'AVLTrees':'~aVLTrees.AVLInsert.P4.0'(A,B,C,D)).
'aVLTrees.AVLInsert.P4.0'(A, B, C, D) :-
        'aVLTrees.Insert.P5'(A, B, C, D, _).
'~aVLTrees.AVLInsert.P4.0'(A, B, C, D) :-
        '~aVLTrees.Insert.P5'(A, B, C, D, _).
'aVLTrees.AVLAmend.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(nonvar(A)and ground([B]), 'AVLTrees':'aVLTrees.AVLAmend.P6.0'(A,B,C,D,E,F)).
'~aVLTrees.AVLAmend.P6'(A, B, C, D, E, F) :-
        user:goedel_freeze(nonvar(A)and ground([B]), 'AVLTrees':'~aVLTrees.AVLAmend.P6.0'(A,B,C,D,E,F)).
'aVLTrees.AVLAmend.P6.0'(A, B, C, D, E, F) :-
        'aVLTrees.Amend.P7'(A, B, C, D, E, F, _).
'~aVLTrees.AVLAmend.P6.0'(A, B, C, D, E, F) :-
        '~aVLTrees.Amend.P7'(A, B, C, D, E, F, _).
'aVLTrees.AVLDelete.P3'(A, B, C) :-
        user:goedel_freeze(nonvar(A)and ground([B]), 'AVLTrees':'aVLTrees.AVLDelete.P3.0'(A,B,C)).
'~aVLTrees.AVLDelete.P3'(A, B, C) :-
        user:goedel_freeze(nonvar(A)and ground([B]), 'AVLTrees':'~aVLTrees.AVLDelete.P3.0'(A,B,C)).
'aVLTrees.AVLDelete.P3.0'(A, B, C) :-
        'aVLTrees.DeleteKey.P4'(A, B, C, _).
'~aVLTrees.AVLDelete.P3.0'(A, B, C) :-
        '~aVLTrees.DeleteKey.P4'(A, B, C, _).
'aVLTrees.AVLIsEmpty.P1'('aVLTrees.Null.C0').
'~aVLTrees.AVLIsEmpty.P1'('aVLTrees.Null.C0').
'aVLTrees.AVLSearch.P3'(A, B, C) :-
        user:goedel_freeze(nonvar(A)and ground([B]), 'AVLTrees':'aVLTrees.AVLSearch.P3.0'(A,B,C)).
'~aVLTrees.AVLSearch.P3'(A, B, C) :-
        user:goedel_freeze(nonvar(A)and ground([B]), 'AVLTrees':'~aVLTrees.AVLSearch.P3.0'(A,B,C)).
'aVLTrees.AVLSearch.P3.0'('aVLTrees.Node.F5'(_,A,B,_,_), C, D) :-
        call_residue(C=A, E),
        (   E=[] ->
            !
        ;   user:release_suspended(E)
        ),
        D=B.
'~aVLTrees.AVLSearch.P3.0'('aVLTrees.Node.F5'(_,A,B,_,_), C, D) :-
        C=A,
        D=B.
'aVLTrees.AVLSearch.P3.0'('aVLTrees.Node.F5'(A,B,_,_,_), C, D) :-
        call_residue('Strings':'Strings.<.P2'(C,B), E),
        (   E=[] ->
            !
        ;   user:release_suspended(E)
        ),
        'aVLTrees.AVLSearch.P3'(A, C, D).
'~aVLTrees.AVLSearch.P3.0'('aVLTrees.Node.F5'(A,B,_,_,_), C, D) :-
        'Strings':'~Strings.<.P2'(C, B),
        '~aVLTrees.AVLSearch.P3'(A, C, D).
'aVLTrees.AVLSearch.P3.0'('aVLTrees.Node.F5'(_,A,_,_,B), C, D) :-
        call_residue('Strings':'Strings.>.P2'(C,A), E),
        (   E=[] ->
            !
        ;   user:release_suspended(E)
        ),
        'aVLTrees.AVLSearch.P3'(B, C, D).
'~aVLTrees.AVLSearch.P3.0'('aVLTrees.Node.F5'(_,A,_,_,B), C, D) :-
        'Strings':'~Strings.>.P2'(C, A),
        '~aVLTrees.AVLSearch.P3'(B, C, D).
'aVLTrees.AVLMember.P3'(A, B, C) :-
        user:goedel_freeze(nonvar(A), 'AVLTrees':'aVLTrees.AVLMember.P3.0'(A,B,C)).
'~aVLTrees.AVLMember.P3'(A, B, C) :-
        user:goedel_freeze(nonvar(A), 'AVLTrees':'~aVLTrees.AVLMember.P3.0'(A,B,C)).
'aVLTrees.AVLMember.P3.0'('aVLTrees.Node.F5'(_,A,B,_,_), A, B).
'~aVLTrees.AVLMember.P3.0'('aVLTrees.Node.F5'(_,A,B,_,_), A, B).
'aVLTrees.AVLMember.P3.0'('aVLTrees.Node.F5'(A,_,_,_,_), B, C) :-
        'aVLTrees.AVLMember.P3'(A, B, C).
'~aVLTrees.AVLMember.P3.0'('aVLTrees.Node.F5'(A,_,_,_,_), B, C) :-
        '~aVLTrees.AVLMember.P3'(A, B, C).
'aVLTrees.AVLMember.P3.0'('aVLTrees.Node.F5'(_,_,_,_,A), B, C) :-
        'aVLTrees.AVLMember.P3'(A, B, C).
'~aVLTrees.AVLMember.P3.0'('aVLTrees.Node.F5'(_,_,_,_,A), B, C) :-
        '~aVLTrees.AVLMember.P3'(A, B, C).
'aVLTrees.AVLJoinAux.P3'('aVLTrees.Null.C0', A, A).
'~aVLTrees.AVLJoinAux.P3'('aVLTrees.Null.C0', A, A).
'aVLTrees.AVLJoinAux.P3'('aVLTrees.Node.F5'(A,B,C,_,D), E, F) :-
        'aVLTrees.Amend.P7'(E, B, C, _, G, _, _),
        'aVLTrees.AVLJoinAux.P3'(A, G, H),
        'aVLTrees.AVLJoinAux.P3'(D, H, F).
'~aVLTrees.AVLJoinAux.P3'('aVLTrees.Node.F5'(A,B,C,_,D), E, F) :-
        '~aVLTrees.Amend.P7'(E, B, C, _, G, _, _),
        '~aVLTrees.AVLJoinAux.P3'(A, G, H),
        '~aVLTrees.AVLJoinAux.P3'(D, H, F).
'aVLTrees.AVLUpdate.P5'(A, B, C, D, E) :-
        user:goedel_freeze(nonvar(A)and ground([B]), 'AVLTrees':'aVLTrees.AVLUpdate.P5.0'(A,B,C,D,E)).
'~aVLTrees.AVLUpdate.P5'(A, B, C, D, E) :-
        user:goedel_freeze(nonvar(A)and ground([B]), 'AVLTrees':'~aVLTrees.AVLUpdate.P5.0'(A,B,C,D,E)).
'aVLTrees.AVLUpdate.P5.0'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H, I) :-
        call_residue(F=B, J),
        (   J=[] ->
            !
        ;   user:release_suspended(J)
        ),
        H='aVLTrees.Node.F5'(A,B,G,D,E),
        I=C.
'~aVLTrees.AVLUpdate.P5.0'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H, I) :-
        F=B,
        H='aVLTrees.Node.F5'(A,B,G,D,E),
        I=C.
'aVLTrees.AVLUpdate.P5.0'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H, I) :-
        call_residue('Strings':'Strings.<.P2'(F,B), J),
        (   J=[] ->
            !
        ;   user:release_suspended(J)
        ),
        'aVLTrees.AVLUpdate.P5'(A, F, G, K, I),
        H='aVLTrees.Node.F5'(K,B,C,D,E).
'~aVLTrees.AVLUpdate.P5.0'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H, I) :-
        'Strings':'~Strings.<.P2'(F, B),
        '~aVLTrees.AVLUpdate.P5'(A, F, G, J, I),
        H='aVLTrees.Node.F5'(J,B,C,D,E).
'aVLTrees.AVLUpdate.P5.0'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H, I) :-
        call_residue('Strings':'Strings.>.P2'(F,B), J),
        (   J=[] ->
            !
        ;   user:release_suspended(J)
        ),
        'aVLTrees.AVLUpdate.P5'(E, F, G, K, I),
        H='aVLTrees.Node.F5'(A,B,C,D,K).
'~aVLTrees.AVLUpdate.P5.0'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H, I) :-
        'Strings':'~Strings.>.P2'(F, B),
        '~aVLTrees.AVLUpdate.P5'(E, F, G, J, I),
        H='aVLTrees.Node.F5'(A,B,C,D,J).
'aVLTrees.AVLToBinary.P2'(A, B) :-
        user:goedel_freeze(nonvar(A), 'AVLTrees':'aVLTrees.AVLToBinary.P2.0'(A,B)).
'~aVLTrees.AVLToBinary.P2'(A, B) :-
        user:goedel_freeze(nonvar(A), 'AVLTrees':'~aVLTrees.AVLToBinary.P2.0'(A,B)).
'aVLTrees.AVLToBinary.P2.0'('aVLTrees.Null.C0', 'aVLTrees.Empty.C0').
'~aVLTrees.AVLToBinary.P2.0'('aVLTrees.Null.C0', 'aVLTrees.Empty.C0').
'aVLTrees.AVLToBinary.P2.0'('aVLTrees.Node.F5'(A,B,C,_,D), 'aVLTrees.Tree.F4'(E,B,C,F)) :-
        'aVLTrees.AVLToBinary.P2'(A, E),
        'aVLTrees.AVLToBinary.P2'(D, F).
'~aVLTrees.AVLToBinary.P2.0'('aVLTrees.Node.F5'(A,B,C,_,D), 'aVLTrees.Tree.F4'(E,B,C,F)) :-
        '~aVLTrees.AVLToBinary.P2'(A, E),
        '~aVLTrees.AVLToBinary.P2'(D, F).
'aVLTrees.Adjust.P6'('aVLTrees.No.C0', A, B, _, B, A).
'~aVLTrees.Adjust.P6'('aVLTrees.No.C0', A, B, _, B, A).
'aVLTrees.Adjust.P6'('aVLTrees.Yes.C0', A, B, C, D, E) :-
        'aVLTrees.Adjustment.P4'(B, C, D, F),
        'aVLTrees.Rebalance.P4'(F, A, D, E).
'~aVLTrees.Adjust.P6'('aVLTrees.Yes.C0', A, B, C, D, E) :-
        '~aVLTrees.Adjustment.P4'(B, C, D, F),
        '~aVLTrees.Rebalance.P4'(F, A, D, E).
'aVLTrees.DeleteKey.P4'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H) :-
        call_residue('Strings':'Strings.<.P2'(F,B), I),
        (   I=[] ->
            !
        ;   user:release_suspended(I)
        ),
        'aVLTrees.DeleteKey.P4'(A, F, J, K),
        'aVLTrees.Adjust.P6'(K, 'aVLTrees.Node.F5'(J,B,C,D,E), D, 'aVLTrees.Right.C0', L, G),
        'aVLTrees.HeightDecreased.P3'(D, L, H).
'~aVLTrees.DeleteKey.P4'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H) :-
        'Strings':'~Strings.<.P2'(F, B),
        '~aVLTrees.DeleteKey.P4'(A, F, I, J),
        '~aVLTrees.Adjust.P6'(J, 'aVLTrees.Node.F5'(I,B,C,D,E), D, 'aVLTrees.Right.C0', K, G),
        '~aVLTrees.HeightDecreased.P3'(D, K, H).
'aVLTrees.DeleteKey.P4'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H) :-
        call_residue('Strings':'Strings.>.P2'(F,B), I),
        (   I=[] ->
            !
        ;   user:release_suspended(I)
        ),
        'aVLTrees.DeleteKey.P4'(E, F, J, K),
        'aVLTrees.Adjust.P6'(K, 'aVLTrees.Node.F5'(A,B,C,D,J), D, 'aVLTrees.Left.C0', L, G),
        'aVLTrees.HeightDecreased.P3'(D, L, H).
'~aVLTrees.DeleteKey.P4'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H) :-
        'Strings':'~Strings.>.P2'(F, B),
        '~aVLTrees.DeleteKey.P4'(E, F, I, J),
        '~aVLTrees.Adjust.P6'(J, 'aVLTrees.Node.F5'(A,B,C,D,I), D, 'aVLTrees.Left.C0', K, G),
        '~aVLTrees.HeightDecreased.P3'(D, K, H).
'aVLTrees.DeleteKey.P4'('aVLTrees.Node.F5'(A,B,_,C,D), E, F, G) :-
        call_residue(E=B, H),
        (   H=[] ->
            !
        ;   user:release_suspended(H)
        ),
        'aVLTrees.Combine.P5'(A, C, D, F, G).
'~aVLTrees.DeleteKey.P4'('aVLTrees.Node.F5'(A,B,_,C,D), E, F, G) :-
        E=B,
        '~aVLTrees.Combine.P5'(A, C, D, F, G).
'aVLTrees.BalanceTable2.P3'('aVLTrees.LH.C0', 'aVLTrees.EQ.C0', 'aVLTrees.RH.C0').
'~aVLTrees.BalanceTable2.P3'('aVLTrees.LH.C0', 'aVLTrees.EQ.C0', 'aVLTrees.RH.C0').
'aVLTrees.BalanceTable2.P3'('aVLTrees.RH.C0', 'aVLTrees.LH.C0', 'aVLTrees.EQ.C0').
'~aVLTrees.BalanceTable2.P3'('aVLTrees.RH.C0', 'aVLTrees.LH.C0', 'aVLTrees.EQ.C0').
'aVLTrees.BalanceTable2.P3'('aVLTrees.EQ.C0', 'aVLTrees.EQ.C0', 'aVLTrees.EQ.C0').
'~aVLTrees.BalanceTable2.P3'('aVLTrees.EQ.C0', 'aVLTrees.EQ.C0', 'aVLTrees.EQ.C0').
'aVLTrees.BalanceTable1.P3'('aVLTrees.EQ.C0', 'aVLTrees.RH.C0', 'aVLTrees.LH.C0').
'~aVLTrees.BalanceTable1.P3'('aVLTrees.EQ.C0', 'aVLTrees.RH.C0', 'aVLTrees.LH.C0').
'aVLTrees.BalanceTable1.P3'('aVLTrees.LH.C0', 'aVLTrees.EQ.C0', 'aVLTrees.EQ.C0').
'~aVLTrees.BalanceTable1.P3'('aVLTrees.LH.C0', 'aVLTrees.EQ.C0', 'aVLTrees.EQ.C0').
'aVLTrees.BalanceTable1.P3'('aVLTrees.RH.C0', 'aVLTrees.EQ.C0', 'aVLTrees.EQ.C0').
'~aVLTrees.BalanceTable1.P3'('aVLTrees.RH.C0', 'aVLTrees.EQ.C0', 'aVLTrees.EQ.C0').
'aVLTrees.Amend.P7'('aVLTrees.Null.C0', A, B, C, 'aVLTrees.Node.F5'('aVLTrees.Null.C0',A,B,'aVLTrees.EQ.C0','aVLTrees.Null.C0'), C, 'aVLTrees.Yes.C0').
'~aVLTrees.Amend.P7'('aVLTrees.Null.C0', A, B, C, 'aVLTrees.Node.F5'('aVLTrees.Null.C0',A,B,'aVLTrees.EQ.C0','aVLTrees.Null.C0'), C, 'aVLTrees.Yes.C0').
'aVLTrees.Amend.P7'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H, I, J, K) :-
        call_residue('Strings':'Strings.<.P2'(F,B), L),
        (   L=[] ->
            !
        ;   user:release_suspended(L)
        ),
        'aVLTrees.Amend.P7'(A, F, G, H, M, J, N),
        'aVLTrees.Adjust.P6'(N, 'aVLTrees.Node.F5'(M,B,C,D,E), D, 'aVLTrees.Left.C0', O, I),
        'aVLTrees.HeightIncreased.P3'(D, O, K).
'~aVLTrees.Amend.P7'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H, I, J, K) :-
        'Strings':'~Strings.<.P2'(F, B),
        '~aVLTrees.Amend.P7'(A, F, G, H, L, J, M),
        '~aVLTrees.Adjust.P6'(M, 'aVLTrees.Node.F5'(L,B,C,D,E), D, 'aVLTrees.Left.C0', N, I),
        '~aVLTrees.HeightIncreased.P3'(D, N, K).
'aVLTrees.Amend.P7'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H, I, J, K) :-
        call_residue('Strings':'Strings.>.P2'(F,B), L),
        (   L=[] ->
            !
        ;   user:release_suspended(L)
        ),
        'aVLTrees.Amend.P7'(E, F, G, H, M, J, N),
        'aVLTrees.Adjust.P6'(N, 'aVLTrees.Node.F5'(A,B,C,D,M), D, 'aVLTrees.Right.C0', O, I),
        'aVLTrees.HeightIncreased.P3'(D, O, K).
'~aVLTrees.Amend.P7'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H, I, J, K) :-
        'Strings':'~Strings.>.P2'(F, B),
        '~aVLTrees.Amend.P7'(E, F, G, H, L, J, M),
        '~aVLTrees.Adjust.P6'(M, 'aVLTrees.Node.F5'(A,B,C,D,L), D, 'aVLTrees.Right.C0', N, I),
        '~aVLTrees.HeightIncreased.P3'(D, N, K).
'aVLTrees.Amend.P7'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, _, H, I, J) :-
        call_residue(F=B, K),
        (   K=[] ->
            !
        ;   user:release_suspended(K)
        ),
        H='aVLTrees.Node.F5'(A,F,G,D,E),
        I=C,
        J='aVLTrees.No.C0'.
'~aVLTrees.Amend.P7'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, _, H, I, J) :-
        F=B,
        H='aVLTrees.Node.F5'(A,F,G,D,E),
        I=C,
        J='aVLTrees.No.C0'.
'aVLTrees.Combine.P5'('aVLTrees.Null.C0', _, A, A, 'aVLTrees.Yes.C0') :- !.
'~aVLTrees.Combine.P5'('aVLTrees.Null.C0', _, A, A, 'aVLTrees.Yes.C0').
'aVLTrees.Combine.P5'(A, _, 'aVLTrees.Null.C0', A, 'aVLTrees.Yes.C0') :- !.
'~aVLTrees.Combine.P5'(A, _, 'aVLTrees.Null.C0', A, 'aVLTrees.Yes.C0').
'aVLTrees.Combine.P5'(A, B, C, D, E) :-
        call_residue((user:not_equal([],[A],A,'aVLTrees.Null.C0'),user:not_equal([],[C],C,'aVLTrees.Null.C0')), F),
        (   F=[] ->
            !
        ;   user:release_suspended(F)
        ),
        'aVLTrees.RemoveRightmost.P5'(A, G, H, I, J),
        'aVLTrees.Adjust.P6'(J, 'aVLTrees.Node.F5'(I,G,H,B,C), B, 'aVLTrees.Right.C0', K, D),
        'aVLTrees.HeightDecreased.P3'(B, K, E).
'~aVLTrees.Combine.P5'(A, B, C, D, E) :-
        user:not_equal([], [A], A, 'aVLTrees.Null.C0'),
        user:not_equal([], [C], C, 'aVLTrees.Null.C0'),
        '~aVLTrees.RemoveRightmost.P5'(A, F, G, H, I),
        '~aVLTrees.Adjust.P6'(I, 'aVLTrees.Node.F5'(H,F,G,B,C), B, 'aVLTrees.Right.C0', J, D),
        '~aVLTrees.HeightDecreased.P3'(B, J, E).
'aVLTrees.Insert.P5'('aVLTrees.Null.C0', A, B, 'aVLTrees.Node.F5'('aVLTrees.Null.C0',A,B,'aVLTrees.EQ.C0','aVLTrees.Null.C0'), 'aVLTrees.Yes.C0').
'~aVLTrees.Insert.P5'('aVLTrees.Null.C0', A, B, 'aVLTrees.Node.F5'('aVLTrees.Null.C0',A,B,'aVLTrees.EQ.C0','aVLTrees.Null.C0'), 'aVLTrees.Yes.C0').
'aVLTrees.Insert.P5'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H, I) :-
        call_residue('Strings':'Strings.<.P2'(F,B), J),
        (   J=[] ->
            !
        ;   user:release_suspended(J)
        ),
        'aVLTrees.Insert.P5'(A, F, G, K, L),
        'aVLTrees.Adjust.P6'(L, 'aVLTrees.Node.F5'(K,B,C,D,E), D, 'aVLTrees.Left.C0', M, H),
        'aVLTrees.HeightIncreased.P3'(D, M, I).
'~aVLTrees.Insert.P5'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H, I) :-
        'Strings':'~Strings.<.P2'(F, B),
        '~aVLTrees.Insert.P5'(A, F, G, J, K),
        '~aVLTrees.Adjust.P6'(K, 'aVLTrees.Node.F5'(J,B,C,D,E), D, 'aVLTrees.Left.C0', L, H),
        '~aVLTrees.HeightIncreased.P3'(D, L, I).
'aVLTrees.Insert.P5'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H, I) :-
        call_residue('Strings':'Strings.>.P2'(F,B), J),
        (   J=[] ->
            !
        ;   user:release_suspended(J)
        ),
        'aVLTrees.Insert.P5'(E, F, G, K, L),
        'aVLTrees.Adjust.P6'(L, 'aVLTrees.Node.F5'(A,B,C,D,K), D, 'aVLTrees.Right.C0', M, H),
        'aVLTrees.HeightIncreased.P3'(D, M, I).
'~aVLTrees.Insert.P5'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H, I) :-
        'Strings':'~Strings.>.P2'(F, B),
        '~aVLTrees.Insert.P5'(E, F, G, J, K),
        '~aVLTrees.Adjust.P6'(K, 'aVLTrees.Node.F5'(A,B,C,D,J), D, 'aVLTrees.Right.C0', L, H),
        '~aVLTrees.HeightIncreased.P3'(D, L, I).
'aVLTrees.Insert.P5'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H, I) :-
        call_residue(F=B, J),
        (   J=[] ->
            !
        ;   user:release_suspended(J)
        ),
        G=C,
        H='aVLTrees.Node.F5'(A,B,C,D,E),
        I='aVLTrees.No.C0'.
'~aVLTrees.Insert.P5'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H, I) :-
        F=B,
        G=C,
        H='aVLTrees.Node.F5'(A,B,C,D,E),
        I='aVLTrees.No.C0'.
'aVLTrees.HeightIncreased.P3'('aVLTrees.RH.C0', 'aVLTrees.EQ.C0', 'aVLTrees.No.C0') :- !.
'~aVLTrees.HeightIncreased.P3'('aVLTrees.RH.C0', 'aVLTrees.EQ.C0', 'aVLTrees.No.C0').
'aVLTrees.HeightIncreased.P3'('aVLTrees.LH.C0', 'aVLTrees.EQ.C0', 'aVLTrees.No.C0') :- !.
'~aVLTrees.HeightIncreased.P3'('aVLTrees.LH.C0', 'aVLTrees.EQ.C0', 'aVLTrees.No.C0').
'aVLTrees.HeightIncreased.P3'('aVLTrees.EQ.C0', 'aVLTrees.LH.C0', 'aVLTrees.Yes.C0') :- !.
'~aVLTrees.HeightIncreased.P3'('aVLTrees.EQ.C0', 'aVLTrees.LH.C0', 'aVLTrees.Yes.C0').
'aVLTrees.HeightIncreased.P3'('aVLTrees.EQ.C0', 'aVLTrees.RH.C0', 'aVLTrees.Yes.C0') :- !.
'~aVLTrees.HeightIncreased.P3'('aVLTrees.EQ.C0', 'aVLTrees.RH.C0', 'aVLTrees.Yes.C0').
'aVLTrees.HeightIncreased.P3'(A, A, 'aVLTrees.No.C0') :- !.
'~aVLTrees.HeightIncreased.P3'(A, A, 'aVLTrees.No.C0').
'aVLTrees.HeightDecreased.P3'('aVLTrees.LH.C0', 'aVLTrees.RH.C0', 'aVLTrees.No.C0') :- !.
'~aVLTrees.HeightDecreased.P3'('aVLTrees.LH.C0', 'aVLTrees.RH.C0', 'aVLTrees.No.C0').
'aVLTrees.HeightDecreased.P3'('aVLTrees.RH.C0', 'aVLTrees.LH.C0', 'aVLTrees.No.C0') :- !.
'~aVLTrees.HeightDecreased.P3'('aVLTrees.RH.C0', 'aVLTrees.LH.C0', 'aVLTrees.No.C0').
'aVLTrees.HeightDecreased.P3'('aVLTrees.LH.C0', 'aVLTrees.EQ.C0', 'aVLTrees.Yes.C0') :- !.
'~aVLTrees.HeightDecreased.P3'('aVLTrees.LH.C0', 'aVLTrees.EQ.C0', 'aVLTrees.Yes.C0').
'aVLTrees.HeightDecreased.P3'('aVLTrees.RH.C0', 'aVLTrees.EQ.C0', 'aVLTrees.Yes.C0') :- !.
'~aVLTrees.HeightDecreased.P3'('aVLTrees.RH.C0', 'aVLTrees.EQ.C0', 'aVLTrees.Yes.C0').
'aVLTrees.HeightDecreased.P3'('aVLTrees.EQ.C0', _, 'aVLTrees.No.C0') :- !.
'~aVLTrees.HeightDecreased.P3'('aVLTrees.EQ.C0', _, 'aVLTrees.No.C0').
'aVLTrees.HeightDecreased.P3'(A, A, 'aVLTrees.No.C0') :- !.
'~aVLTrees.HeightDecreased.P3'(A, A, 'aVLTrees.No.C0').
'aVLTrees.RemoveRightmost.P5'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H, I) :-
        call_residue(user:not_equal([],[E],E,'aVLTrees.Null.C0'), J),
        (   J=[] ->
            !
        ;   user:release_suspended(J)
        ),
        'aVLTrees.RemoveRightmost.P5'(E, F, G, K, L),
        'aVLTrees.Adjust.P6'(L, 'aVLTrees.Node.F5'(A,B,C,D,K), D, 'aVLTrees.Left.C0', M, H),
        'aVLTrees.HeightDecreased.P3'(D, M, I).
'~aVLTrees.RemoveRightmost.P5'('aVLTrees.Node.F5'(A,B,C,D,E), F, G, H, I) :-
        user:not_equal([], [E], E, 'aVLTrees.Null.C0'),
        '~aVLTrees.RemoveRightmost.P5'(E, F, G, J, K),
        '~aVLTrees.Adjust.P6'(K, 'aVLTrees.Node.F5'(A,B,C,D,J), D, 'aVLTrees.Left.C0', L, H),
        '~aVLTrees.HeightDecreased.P3'(D, L, I).
'aVLTrees.RemoveRightmost.P5'('aVLTrees.Node.F5'(A,B,C,_,'aVLTrees.Null.C0'), B, C, A, 'aVLTrees.Yes.C0') :- !.
'~aVLTrees.RemoveRightmost.P5'('aVLTrees.Node.F5'(A,B,C,_,'aVLTrees.Null.C0'), B, C, A, 'aVLTrees.Yes.C0').
'aVLTrees.Rebalance.P4'('aVLTrees.No.C0', 'aVLTrees.Node.F5'(A,B,C,_,D), E, 'aVLTrees.Node.F5'(A,B,C,E,D)).
'~aVLTrees.Rebalance.P4'('aVLTrees.No.C0', 'aVLTrees.Node.F5'(A,B,C,_,D), E, 'aVLTrees.Node.F5'(A,B,C,E,D)).
'aVLTrees.Rebalance.P4'('aVLTrees.Yes.C0', A, B, C) :-
        'aVLTrees.Restructure.P3'(A, B, C).
'~aVLTrees.Rebalance.P4'('aVLTrees.Yes.C0', A, B, C) :-
        '~aVLTrees.Restructure.P3'(A, B, C).
'aVLTrees.Restructure.P3'('aVLTrees.Node.F5'(A,B,C,'aVLTrees.RH.C0','aVLTrees.Node.F5'(D,E,F,G,H)), I, J) :-
        call_residue(user:not_equal([],[G],G,'aVLTrees.LH.C0'), K),
        (   K=[] ->
            !
        ;   user:release_suspended(K)
        ),
        J='aVLTrees.Node.F5'('aVLTrees.Node.F5'(A,B,C,L,D),E,F,I,H),
        'aVLTrees.BalanceTable1.P3'(G, L, I).
'~aVLTrees.Restructure.P3'('aVLTrees.Node.F5'(A,B,C,'aVLTrees.RH.C0','aVLTrees.Node.F5'(D,E,F,G,H)), I, J) :-
        user:not_equal([], [G], G, 'aVLTrees.LH.C0'),
        J='aVLTrees.Node.F5'('aVLTrees.Node.F5'(A,B,C,K,D),E,F,I,H),
        '~aVLTrees.BalanceTable1.P3'(G, K, I).
'aVLTrees.Restructure.P3'('aVLTrees.Node.F5'('aVLTrees.Node.F5'(A,B,C,D,E),F,G,'aVLTrees.LH.C0',H), I, J) :-
        call_residue(user:not_equal([],[D],D,'aVLTrees.RH.C0'), K),
        (   K=[] ->
            !
        ;   user:release_suspended(K)
        ),
        J='aVLTrees.Node.F5'(A,B,C,I,'aVLTrees.Node.F5'(E,F,G,L,H)),
        'aVLTrees.BalanceTable1.P3'(D, I, L).
'~aVLTrees.Restructure.P3'('aVLTrees.Node.F5'('aVLTrees.Node.F5'(A,B,C,D,E),F,G,'aVLTrees.LH.C0',H), I, J) :-
        user:not_equal([], [D], D, 'aVLTrees.RH.C0'),
        J='aVLTrees.Node.F5'(A,B,C,I,'aVLTrees.Node.F5'(E,F,G,K,H)),
        '~aVLTrees.BalanceTable1.P3'(D, I, K).
'aVLTrees.Restructure.P3'('aVLTrees.Node.F5'(A,B,C,'aVLTrees.RH.C0','aVLTrees.Node.F5'('aVLTrees.Node.F5'(D,E,F,G,H),I,J,'aVLTrees.LH.C0',K)), 'aVLTrees.EQ.C0', 'aVLTrees.Node.F5'('aVLTrees.Node.F5'(A,B,C,L,D),E,F,'aVLTrees.EQ.C0','aVLTrees.Node.F5'(H,I,J,M,K))) :- !,
        'aVLTrees.BalanceTable2.P3'(G, L, M).
'~aVLTrees.Restructure.P3'('aVLTrees.Node.F5'(A,B,C,'aVLTrees.RH.C0','aVLTrees.Node.F5'('aVLTrees.Node.F5'(D,E,F,G,H),I,J,'aVLTrees.LH.C0',K)), 'aVLTrees.EQ.C0', 'aVLTrees.Node.F5'('aVLTrees.Node.F5'(A,B,C,L,D),E,F,'aVLTrees.EQ.C0','aVLTrees.Node.F5'(H,I,J,M,K))) :-
        true,
        '~aVLTrees.BalanceTable2.P3'(G, L, M).
'aVLTrees.Restructure.P3'('aVLTrees.Node.F5'('aVLTrees.Node.F5'(A,B,C,'aVLTrees.RH.C0','aVLTrees.Node.F5'(D,E,F,G,H)),I,J,'aVLTrees.LH.C0',K), 'aVLTrees.EQ.C0', 'aVLTrees.Node.F5'('aVLTrees.Node.F5'(A,B,C,L,D),E,F,'aVLTrees.EQ.C0','aVLTrees.Node.F5'(H,I,J,M,K))) :- !,
        'aVLTrees.BalanceTable2.P3'(G, L, M).
'~aVLTrees.Restructure.P3'('aVLTrees.Node.F5'('aVLTrees.Node.F5'(A,B,C,'aVLTrees.RH.C0','aVLTrees.Node.F5'(D,E,F,G,H)),I,J,'aVLTrees.LH.C0',K), 'aVLTrees.EQ.C0', 'aVLTrees.Node.F5'('aVLTrees.Node.F5'(A,B,C,L,D),E,F,'aVLTrees.EQ.C0','aVLTrees.Node.F5'(H,I,J,M,K))) :-
        true,
        '~aVLTrees.BalanceTable2.P3'(G, L, M).
:- style_check(-singleton). % added djd
%% :- module('ProgramsIO', []).
:- module(programsIO).  %% converted djd

:- op(500, yfx, and).
:- op(400, yfx, or).

'ProgramsIO.ProgramCompile.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'ProgramsIO':'ProgramsIO.ProgramCompile.P2.0'(A,B)).
'~ProgramsIO.ProgramCompile.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'ProgramsIO':'~ProgramsIO.ProgramCompile.P2.0'(A,B)).
'ProgramsIO.ProgramCompile.P2.0'(A, B) :-
        'ProgramsIO.ProgramCompileAux.P2'(A, B).
'~ProgramsIO.ProgramCompile.P2.0'(A, B) :-
        '~ProgramsIO.ProgramCompileAux.P2'(A, B).
'ProgramsIO.GetProgram.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'ProgramsIO':'ProgramsIO.GetProgram.P2.0'(A,B)).
'~ProgramsIO.GetProgram.P2'(A, B) :-
        user:goedel_freeze(ground([A]), 'ProgramsIO':'~ProgramsIO.GetProgram.P2.0'(A,B)).
'ProgramsIO.GetProgram.P2.0'(A, B) :-
        'ProgramsIO.GetProgramAux.P2'(A, B).
'~ProgramsIO.GetProgram.P2.0'(A, B) :-
        '~ProgramsIO.GetProgramAux.P2'(A, B).
'ProgramsIO.PutProgram.P2'(A, B) :-
        user:goedel_freeze(ground([A,B]), 'ProgramsIO':'ProgramsIO.PutProgram.P2.0'(A,B)).
'~ProgramsIO.PutProgram.P2'(A, B) :-
        user:goedel_freeze(ground([A,B]), 'ProgramsIO':'~ProgramsIO.PutProgram.P2.0'(A,B)).
'ProgramsIO.PutProgram.P2.0'(A, B) :-
        'ProgramsIO.PutProgramAux.P2'(A, B).
'~ProgramsIO.PutProgram.P2.0'(A, B) :-
        '~ProgramsIO.PutProgramAux.P2'(A, B).
'ProgramsIO.ProgramDecompile.P1'(A) :-
        user:goedel_freeze(ground([A]), 'ProgramsIO':'ProgramsIO.ProgramDecompile.P1.0'(A)).
'~ProgramsIO.ProgramDecompile.P1'(A) :-
        user:goedel_freeze(ground([A]), 'ProgramsIO':'~ProgramsIO.ProgramDecompile.P1.0'(A)).
'ProgramsIO.ProgramDecompile.P1.0'(A) :-
        'ProgramsIO.ProgramDecompileAux.P1'(A).
'~ProgramsIO.ProgramDecompile.P1.0'(A) :-
        '~ProgramsIO.ProgramDecompileAux.P1'(A).
/* 
File:		ProgramsIO.sup
Subject:	Implemention of the system module ProgramsIO
Author: 	Jiwei Wang
Date:		15 June 1992

================================================================================
*/

%% '$$module'('@(#)ProgramsIO.sup 1.26 last updated 93/11/10 17:37:10 by bowers').
:- module(programsIO_sup).   %% converted djd

%------------------------------------------------------------------------------

% 'ProgramsIO.GetProgramAux.P2'(Stream, 'ProgDefs.CachedProgram.F1'(Main)) :-
%    'IO':translate_stream(Stream, PrologStream),
%    user:readin_program(PrologStream, Program),
%    Program = 'ProgDefs.Program.F4'(Main, _, _, _),
%    retractall(user:cached_program(Main, _)),%
    assert(user:cached_program(Main, Program)).

'ProgramsIO.GetProgramAux.P2'(Stream, Program) :-
    'IO':translate_stream(Stream, PrologStream),
    user:readin_program(PrologStream, Program).

'~ProgramsIO.GetProgramAux.P2'(Stream, Program) :-
   'ProgramsIO.GetProgramAux.P2'(Stream, Program).

%------------------------------------------------------------------------------

'ProgramsIO.PutProgramAux.P2'(Stream, Program) :-
   'IO':translate_stream(Stream, PrologStream),
   user:file_version(V),
   format(PrologStream, 'version(''~a'', prm).~n', [V]),
   user:create_prm_file_aux(Program, PrologStream), !.

'~ProgramsIO.PutProgramAux.P2'(Stream, Program) :-
   'ProgramsIO.PutProgramAux.P2'(Stream, Program).

%------------------------------------------------------------------------------

'ProgramsIO.ProgramCompileAux.P2'(GModuleName, Program) :-
   user:gstring2string(GModuleName, ModuleName),
   ( user:system_module_name(GModuleName)
     -> user:load_system_module(ModuleName, Program)
     ;  retractall(user:there_is_error),
        assert(user:no_message),
        user:parse_program(ModuleName, make, Program), 
        retractall(user:no_message), !,
	\+ user:there_is_error
   ).

%------------------------------------------------------------------------------

'ProgramsIO.ProgramDecompileAux.P1'(Program) :-
   user:'ParserPrograms.Decompile.P2'(Program, 'ParserPrograms.Quiet.C0').

:- style_check(-singleton). % added djd
%% :- module('Theories', []).
:- module(theories).  %% converted djd

:- op(500, yfx, and).
:- op(400, yfx, or).

:- style_check(-singleton). % added djd
%% :- module('TheoriesIO', []).
:- module(theoriesIO).  %% converted djd 

:- op(500, yfx, and).
:- op(400, yfx, or).

%% 236 lines cleaned djd
