跳转到内容

This page is also in English.

Read it in English

Esta página también está en español.

Léela en español

このページは日本語でも読めます。

日本語で読む

conflicting_rules 函数

返回所有不能同时成立的规则集合,每个集合是它所需规则的列表;全部可以成立时为 []。

怎么写

conflicting_rules(rules, domain)

rules
这些规则,写成列表或用 and 连接;n : integer 表示 n 是整数。接受一个列表或一个条件,真或假。
domain
指定 integer 时,每个未知数都是整数;省略时为实数。

示例

  • {x>1 或 y>1x≤0y<0z>2  {x>1 或 y>1x≤0y<0\displaystyle \begin{cases} x > 1 \text{ 或 } y > 1 \\ x \le 0 \\ y < 0 \\ z > 2 \end{cases} \; \begin{cases} x > 1 \text{ 或 } y > 1 \\ x \le 0 \\ y < 0 \end{cases}
    conflicting_rules([x > 1 or y > 1, x <= 0, y < 0, z > 2])

    在求解器中,conflicting_rules([x > 1 or y > 1, x <= 0, y < 0, z > 2]) 的结果是 [[x > 1 or y > 1, x <= 0, y < 0]]。

    在求解器中打开
  • {6t+4u=40t≥5u≥2  {6t+4u=40t≥5u≥2\displaystyle \begin{cases} 6 t+4 u = 40 \\ t \ge 5 \\ u \ge 2 \end{cases} \; \begin{cases} 6 t+4 u = 40 \\ t \ge 5 \\ u \ge 2 \end{cases}
    conflicting_rules([6*t + 4*u = 40, t >= 5, u >= 2], integer)

    在求解器中,conflicting_rules([6*t + 4*u = 40, t >= 5, u >= 2], integer) 的结果是 [[6t + 4u = 40, t >= 5, u >= 2]]。

    在求解器中打开