[Date Index]
[Thread Index]
[Author Index]
Re: Using results of "Solve"
*To*: mathgroup at smc.vnet.net
*Subject*: [mg25736] Re: [mg25693] Using results of "Solve"
*From*: Daniel Lichtblau <danl at wolfram.com>
*Date*: Sat, 21 Oct 2000 14:42:47 -0400 (EDT)
*References*: <200010190835.EAA21602@smc.vnet.net>
*Sender*: owner-wri-mathgroup at wolfram.com
Helge Kreutzmann wrote:
>
> Hello !
> I have a series of matrices which depend on several parameters. I can
> create those matrices fine and display them. They are called
>
> S[k_,m_,b_,n_]
>
> Now there is an unkown called "q" in the matrix which is evaluated by
> setting the determinant of the matrix zero and solving the resulting
> equation for q:
>
> Solve[Det[S[2, m, b, 2]] == 0, q]
>
> Now I want to use this function. The result is given in a form like:
> {{ q -> rhs1 },{ q -> rhs2}} and so on. I would like now to plot q.
>
> A colleque gave me the following "hack":
> h =.;
> h[m_, b_] := Solve[Det[S[2, m, b, 2]] == 0, q];
> Plot3D[q /. h[m, b] [[2]], {m, 0, 3}, {b, 0, 3}]
>
> Is there a more straightforward way ? Especially I would like to create
> several functions this way and their sum is the resulting function I
> am interested in (actually it's a series).
>
> Regards
>
> Helge
The way to get a list of solutions for q is simply
solns = q /. h[m,b]
You now have the solutions in a list and can plot any or all of them.
If you are working with algebraic functions (that is, the solution for q
is expressed in terms of Root[...] with ... dependent on parameters m
and b) then you might want to look into using RootSum. This is
frequently of use when one works with an ensemble of eigenvalues, say.
Daniel Lichtblau
Wolfram Research
Prev by Date:
**Re: Solve...**
Next by Date:
**Re: Solve...**
Previous by thread:
**Using results of "Solve"**
Next by thread:
**Re: Using results of "Solve"**
| |