use of kodkod.ast.Variable in project org.alloytools.alloy by AlloyTools.
the class MED001 method insulin_effect.
/**
* Returns the insulin_effect axiom.
*
* @return insulin_effect
*/
public final Formula insulin_effect() {
final Variable x0 = Variable.unary("X0");
final Expression x1 = UNIV.difference(x0.join(gt));
return x1.in(drugi).implies(x1.in(uptakelg.intersection(uptakepg))).forAll(x0.oneOf(UNIV));
}
use of kodkod.ast.Variable in project org.alloytools.alloy by AlloyTools.
the class MED001 method sulfonylurea_effect.
/**
* Returns the sulfonylurea_effect axiom.
*
* @return sulfonylurea_effect
*/
public final Formula sulfonylurea_effect() {
final Variable x0 = Variable.unary("X0");
final Expression x1 = UNIV.difference(x0.join(gt));
return x1.in(drugi).and(x0.in(bcapacityex).not()).implies(x1.in(bsecretioni)).forAll(x0.oneOf(UNIV));
}
use of kodkod.ast.Variable in project org.alloytools.alloy by AlloyTools.
the class MED009 method transsls2_qige27.
/**
* Returns transsls2_qige27 conjecture.
*
* @return transsls2_qige27
*/
public final Formula transsls2_qige27() {
final Variable x0 = Variable.unary("X0");
final Formula f0 = n0.in(s1).and(n0.join(gt).in(conditionhyper)).and(n0.in(bcapacitysn).not()).and(n0.in(qilt27).not());
final Formula f1 = n0.product(x0).in(gt).not().and(x0.in(s2)).and(x0.join(gt).in(conditionhyper)).and(x0.in(bcapacityne.union(bcapacityex))).forSome(x0.oneOf(UNIV));
return f0.implies(f1);
}
use of kodkod.ast.Variable in project org.alloytools.alloy by AlloyTools.
the class NUM374 method associative.
/**
* Returns all X, Y, Z: Num | op[X][op[Y][Z]] = op[op[X][Y]][Z]
*
* @return all X, Y, Z: Num | op[X][op[Y][Z]] = op[op[X][Y]][Z]
*/
final Formula associative(Relation op) {
// all X, Y, Z: Num | op[X][op[Y][Z]] = op[op[X][Y]][Z]
final Variable x = Variable.unary("X");
final Variable y = Variable.unary("Y");
final Variable z = Variable.unary("Z");
return apply(op, x, apply(op, y, z)).eq(apply(op, apply(op, x, y), z)).forAll(x.oneOf(UNIV).and(y.oneOf(UNIV)).and(z.oneOf(UNIV)));
}
use of kodkod.ast.Variable in project org.alloytools.alloy by AlloyTools.
the class NUM374 method wilkie.
/**
* Returns the wilkie conjecture.
*
* @return wilkie
*/
public final Formula wilkie() {
// ! [C,P,Q,R,S,A,B] :
// ( ( C = product(A,A)
// & P = sum(n1,A)
// & Q = sum(P,C)
// & R = sum(n1,product(A,C))
// & S = sum(sum(n1,C),product(C,C)) )
// =>
// product(exponent(sum(exponent(P,A),exponent(Q,A)),B),exponent(sum(exponent(R,B),exponent(S,B)),A))
// =
// product(exponent(sum(exponent(P,B),exponent(Q,B)),A),exponent(sum(exponent(R,A),exponent(S,A)),B))
// ) )).
final Variable c = Variable.unary("C");
final Variable p = Variable.unary("P");
final Variable q = Variable.unary("Q");
final Variable r = Variable.unary("R");
final Variable s = Variable.unary("S");
final Variable a = Variable.unary("A");
final Variable b = Variable.unary("B");
final Formula f0 = c.eq(product(a, a));
final Formula f1 = p.eq(sum(n1, a));
final Formula f2 = q.eq(sum(p, c));
final Formula f3 = r.eq(sum(n1, product(a, c)));
final Formula f4 = s.eq(sum(sum(n1, c), product(c, c)));
final Expression e0 = product(exponent(sum(exponent(p, a), exponent(q, a)), b), exponent(sum(exponent(r, b), exponent(s, b)), a));
final Expression e1 = product(exponent(sum(exponent(p, b), exponent(q, b)), a), exponent(sum(exponent(r, a), exponent(s, a)), b));
final Formula f5 = e0.eq(e1);
return (f0.and(f1).and(f2).and(f3).and(f4)).implies(f5).forAll(c.oneOf(UNIV).and(p.oneOf(UNIV)).and(q.oneOf(UNIV)).and(r.oneOf(UNIV)).and(s.oneOf(UNIV)).and(a.oneOf(UNIV)).and(b.oneOf(UNIV)));
}
Aggregations