home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!ogicse!das-news.harvard.edu!cantaloupe.srv.cs.cmu.edu!crabapple.srv.cs.cmu.edu!silverblue.fac.cs.cmu.edu!lrf
- From: lrf@silverblue.fac.cs.cmu.edu (Lee Furnival)
- Newsgroups: sci.math
- Subject: Mathematica Help
- Message-ID: <1992Jul21.222351.160911@cs.cmu.edu>
- Date: 21 Jul 92 22:23:51 GMT
- Article-I.D.: cs.1992Jul21.222351.160911
- Distribution: usa
- Organization: School of Computer Science, Carnegie Mellon
- Lines: 28
- Nntp-Posting-Host: silverblue.fac.cs.cmu.edu
-
-
- I am having trouble with this small part of a mathematica function I am
- writing, maybe someone here can help...
-
- I want to define a vector, call it v*, such that the components of v*
- are defined by the partial derivatives of a group of other functions.
- Here is what the code looks like at this point:
-
- While [i < n,
- v*[[i]] = D[f[x1,x2,...,xn],x[[i]]];
- i++ ]
-
- So, what I WANT this part do (but it doesn't) is give me this:
-
- v* = {(dx1/dx1,dx2/dx1,...,dxn/dx1),...,(dx1/dxn,dx2,dxn,...,dxn,dxn)}
-
- but when I try to execute the While loop, I get back something like
- "v* not assigned an immediate value". To solve this, I have tried to define
- v* before the loop by using Array and Table, but I still get the same thing.
- My problem is that I want some way of indexing v* in the While loop so
- that its components can be defined as the loop iterates.
-
- I don't know if this makes any sense, so if you have any questions or know
- exactly what I am talking about, then please e-mail me!
-
- Lee Furnival
- lrf@silverblue.fac.cs.cmu.edu
-
-