Changeset 12741
- Timestamp:
- 27.10.2009 15:36:41 (4 weeks ago)
- Location:
- trunk
- Files:
-
- 3 modified
-
CASL/Freeness.hs (modified) (3 diffs)
-
Logic/Logic.hs (modified) (1 diff)
-
Proofs/NormalForm.hs (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/CASL/Freeness.hs
r12724 r12741 37 37 -> [Named CASLFORMULA] -- Th(M) 38 38 -> Result (CASLSign, -- SigmaK 39 CASLMor, -- iota : SigmaM' -> SigmaK39 -- CASLMor, -- iota : SigmaM' -> SigmaK 40 40 [Named CASLFORMULA] -- Ax(K) 41 41 ) … … 46 46 ss_0 = sortSet sigma_0 47 47 sigma_m = mtarget sigma 48 iota_mor = create_iota_mor ss_0 sigma_m 49 sigma_k = mtarget iota_mor 48 sigma_k = create_sigma_k ss_0 sigma_m 50 49 axs = create_axs ss_0 sigma_m sigma_k sens 51 in return (sigma_k, iota_mor,axs)50 in return (sigma_k, axs) 52 51 53 52 horn_clauses :: [Named CASLFORMULA] -> Bool … … 496 495 showSepList (showString "_") showId sortList "") f 497 496 498 -- | given the signature in M the function computes the morphism from M' toK499 create_ iota_mor :: Set.Set SORT -> CASLSign -> CASLMor500 create_ iota_mor ss sg_m = Morphism iota_sg usg' sm om pm ()497 -- | given the signature in M the function computes the signature K 498 create_sigma_k :: Set.Set SORT -> CASLSign -> CASLSign 499 create_sigma_k ss sg_m = usg' 501 500 where iota_sg = totalSignCopy sg_m 502 501 usg = addSig const sg_m iota_sg 503 sm = iota_sort_map_mor $ sortSet sg_m504 om = iota_op_map_mor $ opMap sg_m505 pm = iota_pred_map_mor $ predMap sg_m506 502 om' = homomorphism_ops (sortSet sg_m) (opMap usg) 507 503 om'' = make_ops ss om' -
trunk/Logic/Logic.hs
r12681 r12741 361 361 -> Result 362 362 (sign, -- SigmaK 363 morphism, -- iota : SigmaM' -> SigmaK364 363 [Named sentence] -- Ax(K) 365 364 ) -
trunk/Proofs/NormalForm.hs
r12611 r12741 265 265 let res = quotient_term_algebra lid mor $ toNamedList sen 266 266 case maybeResult res of 267 Just (sigK, iota,axK) -> do267 Just (sigK, axK) -> do 268 268 -- success in logic lid 269 269 let thK = G_theory lid (makeExtSign lid sigK) 270 270 startSigId (toThSens axK) startThId 271 let thM' = noSensGTheory lid sig startSigId272 iotaM' = gEmbed $ mkG_morphism lid iota273 271 incl <- subsig_inclusion lid (plainSign sig) sigK 274 272 let inclM = gEmbed $ mkG_morphism lid incl 275 -- m' with signature = sig, no sentences276 273 -- remove x 277 274 -- add nodes 278 275 -- k with signature = sigK, sentences axK 279 -- global def link s from m and m' to k, mapped with incl, resp iota276 -- global def link from m to k, labeled with inclusion 280 277 -- hiding def link from k to n, labeled with inclusion 281 m' = getNewNodeDG dg -- new node278 -- m' = getNewNodeDG dg -- new node 282 279 nodelab = labDG dg m 283 280 info = nodeInfo nodelab 284 281 ConsStatus c _ _ = node_cons_status info 285 labelM' = newInfoNodeLab 286 (extName "NormalForm" $ dgn_name nodelab) 287 info 288 { node_origin = DGNormalForm m 289 , node_cons_status = mkConsStatus c } 290 thM' 291 -- insert the new node and add edges from the predecessors 292 insM' = InsertNode (m', labelM') 293 k = (getNewNodeDG dg) + 1 282 k = (getNewNodeDG dg) 294 283 labelK = newInfoNodeLab 295 284 (extName "NormalForm" $ dgn_name nodelab) … … 304 293 , dgl_id = defaultEdgeId 305 294 }), 306 InsertEdge (m',k,DGLink { dgl_morphism = iotaM'307 , dgl_type = globalDef308 , dgl_origin = DGLinkProof309 , dgl_id = defaultEdgeId310 }),311 295 InsertEdge (k, n,DGLink { dgl_morphism = inclM 312 296 , dgl_type = HidingDefLink … … 315 299 })] 316 300 del = DeleteEdge edge 317 allChanges = del: insM' :insK : insE301 allChanges = del: insK : insE 318 302 return $ changesDGH dg allChanges 319 303 _ -> do … … 327 311 (m', dgM) <- translateFree dg edge com 328 312 foldM handleEdge dgM $ out (dgBody dgM) m' 329 --return dgM330 313 _ -> return dg 331 314