Lines Matching defs:acc

32   fun iexp x y acc =
33 if y mod 2 = 0 then iexp' x y acc
35 case multInt acc x of
36 SOME acc => iexp' x y acc
39 and iexp' x y acc =
40 if y = 1 then SOME acc
46 SOME x => iexp x y acc
98 fun f acc elts =
100 [] => acc
101 | elt :: elts => f (N * acc + elt) elts
218 fun union (fix,acc) = unionFixed acc fix
323 fun addProj i acc =
324 if i > arity then acc
325 else addProj (i + 1) (NameArityMap.insert acc (mkProj i))
589 fun f 0 acc = acc
590 | f x acc = f (x div 2) (acc + 1)
605 fun f 0w0 acc = acc
606 | f s acc =
608 val acc = if Word.andb (s,0w1) = 0w0 then acc else acc + 1
610 f (Word.>> (s,0w1)) acc
795 fun fold V acc =
797 val acc = f (V,acc)
800 NONE => acc
801 | SOME V => fold V acc
1091 fun randomCheck acc = score (randomValuation {size = N} fv, acc)
1177 fun pertTerm _ [] _ acc = acc
1178 | pertTerm M target tm acc =
1180 ModelVar => acc
1187 val acc =
1188 if isFixedFunction M func_xs then acc
1191 fun add (y,acc) = FunctionPerturbation (func_xs,y) :: acc
1193 List.foldl add acc target
1196 pertTerms M onTarget tms xs acc
1205 fun filt 0 acc = acc
1206 | filt i acc =
1209 val acc = if pred i then i :: acc else acc
1211 filt i acc
1217 fun pert _ [] [] acc = acc
1218 | pert ys (tm :: tms) (x :: xs) acc =
1225 val acc = pertTerm M target tm acc
1227 pert (x :: ys) tms xs acc
1234 fun pertAtom M V target (rel,tms) acc =
1242 val acc =
1243 if isFixedRelation M rel_xs then acc
1244 else RelationPerturbation (rel_xs,target) :: acc
1246 pertTerms M onTarget tms xs acc
1249 fun pertLiteral M V ((pol,atm),acc) = pertAtom M V pol atm acc;
1251 fun pertClause M V cl acc = LiteralSet.foldl (pertLiteral M V) acc cl;