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


Groups > comp.soft-sys.math.mathematica > #16407

Re: Compact formulation of array of constraints

From Bob Hanlon <hanlonr357@gmail.com>
Newsgroups comp.soft-sys.math.mathematica
Subject Re: Compact formulation of array of constraints
Date 2014-01-12 07:12 +0000
Message-ID <latf82$8qd$1@smc.vnet.net> (permalink)
References <20140111073531.79E3569E2@smc.vnet.net>
Organization Time-Warner Telecom

Show all headers | View raw


x[#] >= 0 & /@ Range[5]


{x[1] >= 0, x[2] >= 0,
   x[3] >= 0, x[4] >= 0,
   x[5] >= 0}


Thread[x /@ Range[5] >= 0]


{x[1] >= 0, x[2] >= 0,
   x[3] >= 0, x[4] >= 0,
   x[5] >= 0}



Bob Hanlon




On Sat, Jan 11, 2014 at 2:35 AM, 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 comp.soft-sys.math.mathematica | Previous | Next | Find similar | Unroll thread


Thread

Re: Compact formulation of array of constraints Bob Hanlon <hanlonr357@gmail.com> - 2014-01-12 07:12 +0000

csiph-web