[Date Index]
[Thread Index]
[Author Index]
Re: Solving linear equations with symbolic RHS
*To*: mathgroup at smc.vnet.net
*Subject*: [mg30183] Re: Solving linear equations with symbolic RHS
*From*: Weber <M_S_WEBER at prodigy.net>
*Date*: Wed, 1 Aug 2001 02:19:51 -0400 (EDT)
*References*: <9k5qn6$h9t$1@smc.vnet.net>
*Sender*: owner-wri-mathgroup at wolfram.com
In article <9k5qn6$h9t$1 at smc.vnet.net>, "Tony MacKenzie"
<mackenzi at usq.edu.au> wrote:
> Once again I would like to thank everyone who helped with my last post.
> This
> question is more general and therefore probably much more difficult to
> answer.
>
> I am trying to solve linear equations of the form A.x=b. A is a
> completely
> numeric matrix but b is a symbolic vector. I have tried Solve and
> LUDecomposition but neither of these seem to work very well when b is a
> symbolic vector. What has worked the best for me is to invert the matrix
> A
> (There is no problem with ill-conditioning) and to multiply by the
> symbolic
> vector b. However, what slows this process down is when I expand the
> result.
>
> Ainv=Inverse[N[A,16]];
> soln=Ainv.N[b,16];
> Expand[soln]; (This last steps slows down dramatically as the size of
> the
> problem increases).
>
> Each element of the symbolic solution vector may have a large number of
> terms.
>
> I realise this question I am posting is quite vague but if anyone has any
> ideas it would be greatly appreciated.
>
>
A vague answer which may or may not apply to your situation. It requires
you to know what kind of solution vector you get.
An example: Suppose your vector b has entries which are linear fractional
expressions in two variables x and y. Then the solution vector will be
some rational function in x and y, where you know bounds on the degree
of the numerator and denominator in advance. So instead of working
symbolically with x and y, you plug in finitely many pairs of exact
values for (x,y), solve the system numerically for all pairs, and then
you reconstruct the symbolic solution using (rational) interpolation.
This has worked for me quite well also in cases where the matrix itself
had symbolic entries abd algebric inversion was hopeless.
Matthias Weber
Prev by Date:
**Re: Lists and speed**
Next by Date:
**Re: Sum**
Previous by thread:
**Re: Solving linear equations with symbolic RHS**
Next by thread:
**Re: Solving linear equations with symbolic RHS**
| |