Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.soft-sys.math.mathematica > #11162 > unrolled thread

Re: Evaluation of boolean functions in Mathematica 8

Started byDaniel <dosadchy@its.jnj.com>
First post2012-08-02 08:48 +0000
Last post2012-08-02 08:48 +0000
Articles 1 — 1 participant

Back to article view | Back to comp.soft-sys.math.mathematica


Contents

  Re: Evaluation of boolean functions in Mathematica 8 Daniel <dosadchy@its.jnj.com> - 2012-08-02 08:48 +0000

#11162 — Re: Evaluation of boolean functions in Mathematica 8

FromDaniel <dosadchy@its.jnj.com>
Date2012-08-02 08:48 +0000
SubjectRe: Evaluation of boolean functions in Mathematica 8
Message-ID<jvdes7$c0o$1@smc.vnet.net>
Mathematica cannot guess that you meant for p,q,r to be variables. You should write:

g[p_, q_, r_] = BooleanConvert[And[p, q, r], "BFF"]

or even better (this would work for any number of variables):

g = BooleanConvert[And[##], "BFF"] &

[toc] | [standalone]


Back to top | Article view | comp.soft-sys.math.mathematica


csiph-web