Re: How to parse equations

• To: mathgroup at smc.vnet.net
• Subject: [mg91642] Re: [mg91621] How to parse equations
• From: Bob Hanlon <hanlonr at cox.net>
• Date: Sat, 30 Aug 2008 01:52:49 -0400 (EDT)

```Use Variables

eqns = {x[1] + y[1] + z[1], x[1] + 3 z[1] + u[1]^2, z[1] - u[1] - 16,
u[1] - 5};

Variables /@ eqns

{{x(1),y(1),z(1)},{u(1),x(1),z(1)},{u(1),z(1)},{u(1)}}

Bob Hanlon

---- Stuart Nettleton <Stuart.Nettleton at uts.edu.au> wrote:

=============
Hi,
I am a bit stuck on how to convert the following set of equations to a
list of variables:
eqns = {
x[1] + y[1] + z[1],
x[1] + 3 z[1] + u[1]^2,
z[1] - u[1] - 16,
u[1] - 5};
to give..
{{ x[1], y[1], z[1]},{x[1], z[1], u[1]},{z[1], u[1],}, {u[1]}}
Any thoughts would be appreciated!
Thanks,
Stuart

--
UTS CRICOS Provider Code:  00099F
DISCLAIMER: This email message and any accompanying attachments may contain
confidential information.  If you are not the intended recipient, do not
read, use, disseminate, distribute or copy this message or attachments.  If
immediately and delete this message. Any views expressed in this message
are those of the individual sender, except where the sender expressly, and
with authority, states them to be the views the University of Technology,
Sydney. Before opening any attachments, please check them for viruses and
defects.

```

• Prev by Date: Re: Mathematica and F#
• Next by Date: Re: light-weight PC to run Mathematica?
• Previous by thread: Re: How to parse equations
• Next by thread: Monitoring/collecting evaluations