make-node := word1 & [ NODE #1, 1 #1 & lex-word-sign]. extract-node := unary-phrase & [ NODE #sign, 1 [ node [ cat [ result3 [ sign #sign, number-args [ lst e-list ]], active3 [ lst #2, last #2 ]]]]]. ;;; inserted 22/01/99 ;;; X/Y/Z* Y = X/Z* forward-application := forward-application & [ NODE [ cat [ result3 [ sign #1, number-args [ lst #2, last #3], permuted-args[ lst #2, last #3]], active3 [ lst #4, last #5]]], 1 [ node [ cat [ result3 [sign #1, number-args [ lst [ hd arg , tl #2 ], last #3]], active3 [ lst [ hd [ sign #6, direction1 [ dir-value forward]], tl #4], last #5]]]], 2 [ node #6]]. ;;; inserted 22/01/99 backward-application := backward-application & [ NODE [ cat [ result3 [ sign #1, number-args [ lst #2, last #3], permuted-args [ lst #2, last #3]], active3 [lst #5, last #6]]], 1 [ node #4], 2 [ node [ cat [ result3 [sign #1, number-args [ lst [ hd arg, tl #2 ], last #3]], active3 [lst [ hd [ sign #4, direction1 [ dir-value backward]], tl #5], last #6]]]]]. ;;; inserted 22/01/99 ;;; X/Y Y|Z = X|Z forward-composition-1 := forward-composition & [ NODE [ cat [ result3 [ sign #1 , number-args #2 & [lst #na & [ hd arg], last #nalast] , permuted-args #2 ], active3 [lst #6, last #8]]], 1 [ node [ cat [ result3 [sign #1, number-args [ lst [ tl e-list]]], active3 [ lst [ hd [ sign [ cat [ result3 [sign #3], active3 [ lst [ hd [ sign #4, direction1 [ dir-value #5]]]]]], direction1 [ dir-value forward]], tl #7], last #7]]]], 2 [ node [ cat [ result3 [ sign #3, number-args [ lst [ tl #na], last #nalast]], active3 [ lst [ hd [ sign #4, direction1 [dir-value #5]], tl #6 ], last #8]]]]]. ;;; inserted 22/01/99 ;;; X/W/Y Y|Z = X/W|Z forward-composition-2 := forward-composition & [ NODE [ cat [ result3 [ sign #1 , number-args #2 & [ lst [ tl #na], last #lna], permuted-args #2 ], active3 [ lst [ hd #3, tl #4], last #5]]], 1 [ node [ cat [ result3 [sign #1, number-args [ lst [ tl [ tl e-list]]]], active3 [ lst [ hd [ sign [ cat [ result3 [sign #6], active3 [ lst [ hd [ sign #8, direction1 [dir-value #9]]]]]], direction1 [dir-value forward]], tl [ hd #3]]]]]], 2 [ node [ cat [ result3 [ sign #6, number-args [ lst [ tl #na & [ hd arg]], last #lna]], active3 [ lst [ hd [ sign #8, direction1 [ dir-value #9]], tl #4], last #5]]]]]. ;;; inserted 22/01/99 ;;; Y|Z X\Y = X|Z backward-composition-1 := backward-composition & [ NODE [ cat [ result3 [ sign #1 , number-args #2 & [lst #na & [ hd arg], last #nalast] , permuted-args #2 ], active3 [lst #6, last #8]]], 1 [ node [ cat [ result3 [ sign #3, number-args [ lst [ tl #na], last #nalast]], active3 [ lst [ hd [ sign #4, direction1 [dir-value #5]], tl #6 ], last #8]]]], 2 [ node [ cat [ result3 [sign #1, number-args [ lst [ tl e-list]]], active3 [ lst [ hd [ sign [ cat [ result3 [sign #3], active3 [ lst [ hd [ sign #4, direction1 [dir-value #5]]]]]], direction1 [dir-value backward]], tl #7], last #7]]]]]. ;;; inserted 22/01/99 ;;; X/W/Y Y|Z = X/W|Z backward-composition-2 := backward-composition & [ NODE [ cat [ result3 [ sign #1 , number-args #2 & [ lst [ tl #na], last #lna], permuted-args #2 ], active3 [ lst [ hd #3, tl #4], last #5]]], 1 [ node [ cat [ result3 [ sign #6, number-args [ lst [ tl #na & [ hd arg]], last #lna]], active3 [ lst [ hd [ sign #8, direction1 [dir-value #9]], tl #4], last #5]]]], 2 [ node [ cat [ result3 [sign #1, number-args [ lst [ tl [ tl e-list]]]], active3 [ lst [ hd [ sign [ cat [ result3 [sign #6], active3 [ lst [ hd [ sign #8, direction1 [dir-value #9]]]]]], direction1 [dir-value backward]], tl [ hd #3]]]]]]]. ;permutation := permutation & ;[ NODE [ cat [ result3 [ sign #1, ; number-args #2, ; permuted-args [ lst #3, ; last #4]], ; active3 [lst #5, ; last #6]]], ; 1 [ node [ cat [ result3 [ sign #1, ; number-args #2, ; permuted-args [ lst [ tl #3 & ; [ hd arg]], ; last #4]], ; active3 [lst [ hd #7, ; tl #5], ; last [ hd #7, ; tl #6]]]]]]. ; permutation-2 := permutation & [ NODE [ cat [ result3 [ sign #1, number-args #2 & [ LST [ TL [ TL e-list]]], permuted-args [ lst #3, last #4]], active3 [lst [ hd #5, tl [ hd #7, tl #e-list]], last #e-list]]], 1 [ node [ cat [ result3 [ sign #1, number-args #2, permuted-args [ lst [ tl #3 & [ hd arg]], last #4]], active3 [lst [ hd #7, tl [ hd #5, tl #e-list]], last #e-list]]]]]. permutation-3 := permutation & [ NODE [ cat [ result3 [ sign #1, number-args #2 & [ LST [ TL [ TL [ TL e-list]]]], permuted-args [ lst #3, last #4]], active3 [lst [ hd #5, tl [ hd #8, tl [ hd #7, tl #e-list]]], last #e-list]]], 1 [ node [ cat [ result3 [ sign #1, number-args #2, permuted-args [ lst [ tl #3 & [hd arg]], last #4]], active3 [lst [ hd #8, tl [ hd #7, tl [ hd #5, tl #e-list]]], last #e-list]]]]]. permutation-4 := permutation & [ NODE [ cat [ result3 [ sign #1, number-args #2 & [ LST [ TL [ TL [ TL e-list]]]], permuted-args [ lst #3, last #4]], active3 [lst [ hd #5, tl [ hd #7, tl [ hd #8, tl [ hd #9, tl #e-list]]]], last #e-list]]], 1 [ node [ cat [ result3 [ sign #1, number-args #2, permuted-args [ lst [ tl #3 & [ hd arg]], last #4]], active3 [lst [ hd #9, tl [ hd #8, tl [ hd #7, tl [ hd #5, tl #e-list]]]], last #e-list]]]]]. permutation-5 := permutation & [ NODE [ cat [ result3 [ sign #1, number-args #2 & [ LST [ TL [ TL [ TL [ TL e-list]]]]], permuted-args [ lst #3, last #4]], active3 [lst [ hd #5, tl [ hd #7, tl [ hd #8, tl [ hd #9, tl [ hd #10, tl #e-list]]]]], last #e-list]]], 1 [ node [ cat [ result3 [ sign #1, number-args #2, permuted-args [ lst [ tl #3 & [ hd arg]], last #4]], active3 [lst [ hd #10, tl [ hd #9, tl [ hd #8, tl [ hd #7, tl [ hd #5, tl #e-list]]]]], last #e-list]]]]].