       Re: symbolic approximation (formular manipulation)

• To: mathgroup at smc.vnet.net
• Subject: [mg55024] Re: [mg54991] symbolic approximation (formular manipulation)
• From: Daniel Lichtblau <danl at wolfram.com>
• Date: Thu, 10 Mar 2005 05:24:23 -0500 (EST)
• References: <200503091134.GAA06931@smc.vnet.net>
• Sender: owner-wri-mathgroup at wolfram.com

```Zhe Hu wrote:
> A formula in electrical engineering can be simplified after assuming,
> e.g. R1<<R2, within 10% error tolerance.
>
> How this kind of "simplify" or approximation can be performed by Mathematica?
>
> For example, R1<<R2, R2<<R3
>
> R1+R2                      R2                                      R2
> ---------------  --->  ------------------  ---------> ------------------
> R1(R2+R3)               R1(R2+R3)                       R1 R3
>
>
>
> I thought about replacing: R1->0.00001*R2, but that would eliminate R1
> completely from the formula (denumerator), which is not favorable in
> some cases.

One way is to figure out which are "leading" terms in numerator and
denominator. This might be done as below.

expr = (r1+r2)/(r1*(r2+r3));
{num,den} = With[{te=Together[expr]}, {Numerator[te],Denominator[te]}]
vars = {r3,r2,r1};

InputForm[leadterms = Map[First,
First[Internal`DistributedTermsList[{num,den}, vars]]]]
Out//InputForm= {{{0, 1, 0}, 1}, {{1, 0, 1}, 1}}

What we see are terms represented as {exponent vector, coefficient}
pairs. To recover them in explicit polynomial form we then do as below.

In:= InputForm[{reducednum, reducedden} =
Map[#[]*Apply[Times,vars^#[]]&, leadterms]]
Out//InputForm= {r2, r1*r3}

There are no doubt simpler ways to do this but the way indicated above
is fairly extensible to handle cases where you might have "comparable"
variables and hence may need to keep more terms.

A remotely similar example is discussed at

http://library.wolfram.com/infocenter/Conferences/325/

in the second item of the section "Examples of polynomial manipulation"

Daniel Lichtblau
Wolfram Research

```

• Prev by Date: Re: RationalApproximation
• Next by Date: Re: findfit or solve?
• Previous by thread: symbolic approximation (formular manipulation)
• Next by thread: Re: symbolic approximation (formular manipulation)