---------------------

showAllApplicableRules :: (AbsCalculus,Proof) -> [Int] -> String
showAllApplicableRules (calculus,proof) ints =
 case lookup ints [x | Left x <- goalsOfProof proof] of
   Just sequent -> foldr ((++++) . prAr) [] (allApplicableRules calculus sequent)
   _            -> prGoalId ints +++ "does not exist"
  where
    prAr ((sq,(i,j)),((r,_),_)) =
      "r" +++ prGoalId ints +++ "A" ++ show i +++ "S" ++ show j +++ r +++
      "--" +++ prSequent sq

-----------------------
showAllApplicableRules :: (AbsCalculus,Proof) -> [Int] -> String
showAllApplicableRules (calculus,proof) ints =
 case lookup ints [x | Left x <- goalsOfProof proof] of
   Just sequent -> foldr ((++++) . prAr) [] (allApplicableRules calculus sequent)
   _            -> prGoalId ints +++ "does not exist"
  where
    prAr ((sq,(i,j)),((r,_),_)) =
      "r" +++ prGoalId ints +++ "A" ++ show i +++ "S" ++ show j +++ r +++
      "--" +++ prSequent sq

-----------------------
showAllApplicableRules (calculus,proof) ints =
 case lookup ints [x | Left x <- goalsOfProof proof] of
   Just sequent -> foldr ((++++) . prAr) [] (allApplicableRules calculus sequent)
   _            -> prGoalId ints +++ "does not exist"
  where
    prAr ((sq,(i,j)),((r,_),_)) =
      "r" +++ prGoalId ints +++ "A" ++ show i +++ "S" ++ show j +++ r +++
      "--" +++ prSequent sq

-----------------------