MiniZinc“无法确定界限". [英] MiniZinc "cannot determine bounds"

查看:102
本文介绍了MiniZinc“无法确定界限".的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在编写我的第一个平凡的MiniZinc应用程序时,我一直遇到错误无法确定界限".通常如何解决此错误?

Writing my first non-trivial MiniZinc app, I keep running into the error "cannot determine bounds". How does one generally resolve this error?

推荐答案

通常,无法确定范围"表示求解器无法确定决策变量的范围(域).

In general "cannot determine bounds" means that the solver cannot determine the bounds (the domain) of a decision variable.

如果可能,应避免将"var int"用作决策变量的域,因为这可能会减慢求解过程.有时求解器可以找出域,例如在喜欢的情况下

Using "var int" as the domain of a decision variable should be avoided if possible, since it will probably slow down the solving process. There are times where the solver can figure out the domain, e.g. in cases likes

% ...
var int: z = sum(x);

当"x"具有声明的域时.但是,通常,请尝试定义域.

when "x" have declared domains. But, as a rule, try to define the domains.

这篇关于MiniZinc“无法确定界限".的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆