Re: How to factor a rational
- To: mathgroup at smc.vnet.net
- Subject: [mg78847] Re: [mg78813] How to factor a rational
- From: DrMajorBob <DrMajorBob at bigfoot.com>
- Date: Wed, 11 Jul 2007 06:07:42 -0400 (EDT)
- References: <200707101031.GAA26987@smc.vnet.net>
Some options are:
Factor /@ eq1
4/3 (A - B) L == a k t
Collect[eq1, L]
((4 A)/3 - (4 B)/3) L == a k t
Factor /@ Collect[eq1, L]
4/3 (A - B) L == a k t
Factor@eq1
4/3 (A - B) L == a k t
Bobby
On Tue, 10 Jul 2007 05:31:16 -0500, Steven Siew <siewsk at bp.com> wrote:
> I'm trying to factor a rational constant (4/3) L in equation 1 so
> that it looks like equation 2
>
> But I was unable to do so. What would be the correct transformation to
> do so?
>
> $ cat file6.out
> Mathematica 5.2 for Students: Microsoft Windows Version
> Copyright 1988-2005 Wolfram Research, Inc.
>
> In[1]:=
> Out[1]= {stdout}
>
> In[2]:= (* Write your mathematica code below *)
>
> In[3]:= eq1 = (4/3)*L*A - (4/3)*L*B == a*k*t
>
> 4 A L 4 B L
> Out[3]= ----- - ----- == a k t
> 3 3
>
> In[4]:= FullForm[eq1]
>
> Out[4]//FullForm=
>
>> Equal[Plus[Times[Rational[4, 3], A, L], Times[Rational[-4, 3], B, L]],
>
>> Times[a, k, t]]
>
> In[5]:= eq2 = (4/3)*L*(A - B) == a*k*t
>
> 4 (A - B) L
> Out[5]= ----------- == a k t
> 3
>
> In[6]:= FullForm[eq2]
>
> Out[6]//FullForm=
>
>> Equal[Times[Rational[4, 3], Plus[A, Times[-1, B]], L], Times[a, k, t]]
>
> In[7]:= eq3 = eq1 /. Rational[n_, d_]*(a_)*(b___) + Rational[-n,
> d]*(c_)*b -> Ra
> tional[n, d]*(a - c)*b
>
> 4 A L 4 B L
> Out[7]= ----- - ----- == a k t
> 3 3
>
> In[8]:= (* End of mathematica code *)
>
> In[9]:= Quit[];
>
>
--
Using Opera's revolutionary e-mail client: http://www.opera.com/mail/
- References:
- How to factor a rational
- From: Steven Siew <siewsk@bp.com>
- How to factor a rational