MathGroup Archive 2002

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Getting symbols out of list returned by solve

  • To: mathgroup at smc.vnet.net
  • Subject: [mg37346] Re: Getting symbols out of list returned by solve
  • From: Tom Burton <tburton at brahea.com>
  • Date: Thu, 24 Oct 2002 02:56:02 -0400 (EDT)
  • Sender: owner-wri-mathgroup at wolfram.com

On 10/22/02 11:39 PM, in article ap5g7d$4kn$1 at smc.vnet.net, "Sam"
<phry420 at yahoo.com> wrote:

> This may be really simple but I am having trouble setting the
> variables to the values returned by solve.  If
> solution={S0 -> 0,S1 -> 5....}the numbers of S# are subscripts
> I can get to the idivdual parts with
> solution[[1]][[1]] and solution[[1]][[2]] but when I try to set the
> one equal to the other I get this error
> Set::"setps": solution[[1]] in assignment of part is not a symbol."
> What is going on and how can I fix this?

Sam, you're working too hard :)

If you really want permanent assignments, then substitute (Apply) Rule for
Set:

assignments=Set@@@solution

Tom Burton



  • Prev by Date: Problem with user defined functions
  • Next by Date: Re: Custom colors on a 3-d suface
  • Previous by thread: Getting symbols out of list returned by solve
  • Next by thread: Re: Getting symbols out of list returned by solve