Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.soft-sys.math.mathematica > #16414 > unrolled thread
| Started by | Ray Koopman <koopman@sfu.ca> |
|---|---|
| First post | 2014-01-13 06:55 +0000 |
| Last post | 2014-01-13 06:55 +0000 |
| Articles | 1 — 1 participant |
Back to article view | Back to comp.soft-sys.math.mathematica
Re: Compact formulation of array of constraints Ray Koopman <koopman@sfu.ca> - 2014-01-13 06:55 +0000
| From | Ray Koopman <koopman@sfu.ca> |
|---|---|
| Date | 2014-01-13 06:55 +0000 |
| Subject | Re: Compact formulation of array of constraints |
| Message-ID | <lb02ls$dn0$1@smc.vnet.net> |
If all the constraints must be satisfied then you need to AND them: And @@ Array[x@# >= 0 &, 6, 0] x[0] >= 0 && x[1] >= 0 && x[2] >= 0 && x[3] >= 0 && x[4] >= 0 && x[5] >= 0 ----- Paul Smith <phhs80@gmail.com> wrote: > Dear All, > > How can one formulate the set of constraints > > x[1] >= 0, x[1] >= 0, x[2] >= 0, x[3] >= 0, x[4] >= 0, x[5] >= 0 > > by using a compact form? > > Thanks in advance, > > Paul
Back to top | Article view | comp.soft-sys.math.mathematica
csiph-web