### Related

##### rhs-solve-subst

eq1:rso^2=x^2+(z-cs)^2;

eq2:r1^2=x^2+(z-e)^2;

subst(rhs(solve([eq1]...

Calculate

##### rhs-solve

f(x):=x^2-4;

zero : solve ([f(x)=0...

zero1 : rhs(zero[1]);

Calculate

##### rhs-solve

f1:1/f=1/g+1/b1;

f2:d/p=b1/(b-b1);

solve(f2,b1);

Calculate

##### rhs-solve

f1:1/f=1/g+1/b1;

f2:d/p=b1/(b-b1);

m:solve(f2,b1);

Calculate

##### rhs-solve

eq1: Ip + If + I1 = I2;

eq2: Vout = Vmax -...

eq3: Vout = Vc + If *...

Calculate

##### rhs-sum

y_hat[i] = b + m*x[i];

y[i] = b + m*x[i] + e...

SSE = sum(e[i]^2, i, ...

Calculate

##### rhs-solve

N(p):=1+(p0-p)/e;

Ng(p,Nq) := kp * N(p)...

S:solve(Ng(x,1)=Ng(p0...

Calculate

##### rhs

rhs(3*x^2+2*x+x^3-x^2...

Calculate

##### rhs

liste1: [3, 9, 1, 0, ...

liste2: [z=-3, x=-1, ...

liste3: [[1,2],[2,2],...

Calculate

##### rhs-solve-subst

f1:1/f=1/b+1/g;

f2:f/g=ff/gg;

m:rhs(solve(f1,g)[1]);

Calculate

### rhs

Run Example
(%i1)kill(all);
(%o0)                                done
(%i1) Ik:16;
(%o1)                                 16
(%i2) U0:92;
(%o2)                                 92
(%i3) a:I/Ik=1-(U/U0)^2;
2
I         U
(%o3)                            -- = 1 - ----
16       8464
(%i4) l:solve(a,U);
(%o4)            [U = - 23 sqrt(16 - I), U = 23 sqrt(16 - I)]
(%i5) m:solve(a,I);
2
U  - 8464
(%o5)                          [I = - ---------]
529
(%i6) define(I(U),rhs(m[1]));
2
U  - 8464
(%o6)                         I(U) := - ---------
529
(%i7) define(U(I),rhs(l[2]));
(%o7)                       U(I) := 23 sqrt(16 - I)
(%i8) P(I,U):=I*U;
(%o8)                           P(I, U) := I U
(%i9) plot2d(I(U),[U,0,92], [xlabel, "U[V]"], [ylabel, "I[A]"]);
plotplot2d(U(I),[I,0,16], [ylabel, "U[V]"], [xlabel, "I[A]"]);
plotplot2d([P(I(U),U)],[U,0,92], [xlabel, "U[V]"], [ylabel, "P[W]"]);
plotplot2d([P(I,U(I))],[I,0,16], [xlabel, "I[A]"], [ylabel, "P[W]"], [grid, 10, 10]);
plotdefine(Iabgeleitet(U),diff(P(I(U),U),U));
2    2
2 U    U  - 8464
(%o13)               Iabgeleitet(U) := - ---- - ---------
529       529
(%i14) define(Uabgeleitet(I),diff(P(U(I),I),I));
23 I
(%o14)        Uabgeleitet(I) := 23 sqrt(16 - I) - --------------
2 sqrt(16 - I)
(%i15) Umax:solve(Iabgeleitet(U),U);
92           92
(%o15)                   [U = - -------, U = -------]
sqrt(3)      sqrt(3)
(%i16) Imax:solve(Uabgeleitet(I),I);
32
(%o16)                             [I = --]
3
(%i17) P[max]=float(Imax[1]*Umax[2]);
(%o17)                 P    = (I U = 566.5730641647529)
max
(%i18) R[L]=float(Umax[2]/Imax[1]);
U
(%o18)                   R  = (- = 4.979646071760522)
L    I
(%i19) 
Run Example
factorC(_f,_z):=block([s,n,m,fp,j],fp:1,/* This commented code was meant to use themore robust solver to_poly_solve, but I couldn't understand how to handle multiplicitiesss:args(to_poly_solve(_f,_z)),s:create_list(ss[k][1],k,1,length(ss)),*/s:solve(_f,_z),m:multiplicities,n:length(s),for j:1 thru n do  if lhs(s[j])#0  then fp:fp*(_z-(rhs(s[j])))^m[j], fp:fp*divide(_f,fp)[1],fp);
(%o1) factorC(_f, _z) := block([s, n, m, fp, j], fp : 1, s : solve(_f, _z),
m : multiplicities, n : length(s), for j thru n
m
j
do if lhs(s ) # 0 then fp : fp (_z - rhs(s ))  , fp : fp divide(_f, fp) , fp)
j                              j                            1
(%i2) partfracC(_f,_z):=block([d,fd],d:denom(_f),fd:factorC(d,_z),partfrac(1/fd,_z));
(%o2) partfracC(_f, _z) := block([d, fd], d : denom(_f), fd : factorC(d, _z),
1
partfrac(--, _z))
fd
(%i3) O:partfracC(1/(x^5-1)^4,x);
4 %i %pi           2 %i %pi             2 %i %pi
--------           --------           - --------
5                  5                    5
(%o3) (41992 %e         + 42160 %e         + 42076 %e
4 %i %pi                  4 %i %pi         2 %i %pi            4 %i %pi            4 %i %pi
- --------                  --------         --------          - --------            --------
5                         5                5                   5                   5
+ 41824 %e           + 42328)/((625 %e         - 625 %e         + 1875 %e           - 1875) (%e         x
- 1))
4 %i %pi          2 %i %pi            2 %i %pi            4 %i %pi
--------          --------          - --------          - --------
5                 5                   5                   5
+ (1082 %e         + 1018 %e         + 1114 %e           + 1114 %e
2 %i %pi           2 %i %pi           4 %i %pi
--------         - --------         - --------
5                  5                  5
+ 1082)/((- 1250 %e         + 625 %e           + 625 %e          )
4 %i %pi
--------
5           2
(%e         x - 1) )
4 %i %pi        2 %i %pi          2 %i %pi          4 %i %pi
--------        --------        - --------        - --------
5               5                 5                 5
28 %e         + 20 %e         + 12 %e           + 20 %e           + 20
+ ----------------------------------------------------------------------
2 %i %pi         4 %i %pi     4 %i %pi
- --------         --------     --------
5                5            5           3
(625 %e           - 625 %e        ) (%e         x - 1)
4 %i %pi         2 %i %pi           2 %i %pi           4 %i %pi
--------         --------         - --------         - --------
5                5                  5                  5
+ 1/((- 125 %e         - 125 %e         - 125 %e           - 125 %e
4 %i %pi                      4 %i %pi          2 %i %pi
--------                      --------          --------
5           4                 5                 5
+ 500) (%e         x - 1) ) - (- 1544 %e         - 1880 %e
2 %i %pi           4 %i %pi
- --------         - --------
5                  5
- 32 %e           - 368 %e           - 956)
4 %i %pi          2 %i %pi            2 %i %pi            4 %i %pi     2 %i %pi
--------          --------          - --------          - --------     --------
5                 5                   5                   5            5
/((- 4375 %e         - 6875 %e         + 6875 %e           + 4375 %e          ) (%e         x - 1))
4 %i %pi         2 %i %pi          2 %i %pi          4 %i %pi
--------         --------        - --------        - --------
5                5                 5                 5
+ (42 %e         + 170 %e         + 42 %e           - 54 %e           + 170)
4 %i %pi          2 %i %pi           2 %i %pi            4 %i %pi
--------          --------         - --------          - --------
5                 5                  5                   5
/((- 625 %e         + 1875 %e         - 625 %e           - 2500 %e           + 1875)
2 %i %pi
--------
5           2
(%e         x - 1) )
4 %i %pi       2 %i %pi          2 %i %pi         4 %i %pi
--------       --------        - --------       - --------
5              5                 5                5
- (4 %e         - 4 %e         - 12 %e           + 4 %e           - 12)
4 %i %pi           2 %i %pi           4 %i %pi           2 %i %pi
--------         - --------         - --------           --------
5                  5                  5                  5           3
/((625 %e         - 625 %e           + 625 %e           - 625) (%e         x - 1) )
2 %i %pi           4 %i %pi         2 %i %pi           2 %i %pi           4 %i %pi
- --------           --------         --------         - --------         - --------
5                  5                5                  5                  5
+ %e          /((- 125 %e         - 125 %e         + 500 %e           - 125 %e
2 %i %pi
--------
5           4
- 125) (%e         x - 1) )
4 %i %pi           2 %i %pi             2 %i %pi
--------           --------           - --------
5                  5                    5
- (41824 %e         + 42076 %e         + 42160 %e
4 %i %pi                  4 %i %pi         2 %i %pi            4 %i %pi
- --------                  --------         --------          - --------
5                         5                5                   5
+ 41992 %e           + 42328)/((625 %e         - 625 %e         + 1875 %e           - 1875) (x
4 %i %pi
--------
5
- %e        ))
4 %i %pi          2 %i %pi            2 %i %pi            4 %i %pi
--------          --------          - --------          - --------
5                 5                   5                   5
+ (1114 %e         + 1082 %e         + 1082 %e           + 1114 %e
2 %i %pi           2 %i %pi           4 %i %pi
--------         - --------         - --------
5                  5                  5
+ 1018)/((- 1250 %e         + 625 %e           + 625 %e          )
4 %i %pi
--------
5     2
(x - %e        ) )
4 %i %pi        2 %i %pi          2 %i %pi          4 %i %pi
--------        --------        - --------        - --------
5               5                 5                 5
20 %e         + 20 %e         + 20 %e           + 12 %e           + 28
- ----------------------------------------------------------------------
2 %i %pi         4 %i %pi         4 %i %pi
- --------         --------         --------
5                5                5     3
(625 %e           - 625 %e        ) (x - %e        )
4 %i %pi           4 %i %pi         2 %i %pi           2 %i %pi           4 %i %pi
- --------           --------         --------         - --------         - --------
5                  5                5                  5                  5
+ %e          /((- 125 %e         - 125 %e         - 125 %e           - 125 %e
4 %i %pi
--------
5     4
+ 500) (x - %e        ) )
4 %i %pi         2 %i %pi            2 %i %pi           4 %i %pi
--------         --------          - --------         - --------
5                5                   5                  5
- (32 %e         + 956 %e         + 1544 %e           + 368 %e
4 %i %pi          2 %i %pi            2 %i %pi            4 %i %pi
--------          --------          - --------          - --------
5                 5                   5                   5
+ 1880)/((- 4375 %e         - 6875 %e         + 6875 %e           + 4375 %e          ) (x
2 %i %pi
--------
5
- %e        ))
4 %i %pi        2 %i %pi          2 %i %pi           4 %i %pi
--------        --------        - --------         - --------
5               5                 5                  5
+ (170 %e         + 42 %e         + 42 %e           + 170 %e           - 54)
4 %i %pi          2 %i %pi           2 %i %pi            4 %i %pi
--------          --------         - --------          - --------
5                 5                  5                   5
/((- 625 %e         + 1875 %e         - 625 %e           - 2500 %e           + 1875)
2 %i %pi
--------
5     2
(x - %e        ) )
4 %i %pi        2 %i %pi         2 %i %pi         4 %i %pi
--------        --------       - --------       - --------
5               5                5                5
- (- 4 %e         + 12 %e         + 4 %e           - 4 %e           + 12)
4 %i %pi           2 %i %pi           4 %i %pi               2 %i %pi
--------         - --------         - --------               --------
5                  5                  5                      5     3
/((625 %e         - 625 %e           + 625 %e           - 625) (x - %e        ) )
4 %i %pi           4 %i %pi         2 %i %pi           2 %i %pi           4 %i %pi
- --------           --------         --------         - --------         - --------
5                  5                5                  5                  5
+ %e          /((- 125 %e         - 125 %e         + 500 %e           - 125 %e
2 %i %pi
--------
5     4
- 125) (x - %e        ) )
4 %i %pi         2 %i %pi           2 %i %pi          4 %i %pi
--------         --------         - --------        - --------
5                5                  5                 5
120 %e         + 120 %e         - 132 %e           + 36 %e           + 36
- -------------------------------------------------------------------------
4 %i %pi         2 %i %pi            2 %i %pi
--------         --------          - --------
5                5                   5
(625 %e         + 625 %e         - 1250 %e          ) (x - 1)
4 %i %pi        2 %i %pi          2 %i %pi         4 %i %pi
--------        --------        - --------       - --------
5               5                 5                5
36 %e         + 36 %e         - 60 %e           + 4 %e           + 4
+ --------------------------------------------------------------------
4 %i %pi         2 %i %pi            2 %i %pi
--------         --------          - --------
5                5                   5             2
(625 %e         + 625 %e         - 1250 %e          ) (x - 1)
4 %i %pi          4 %i %pi         2 %i %pi           2 %i %pi           4 %i %pi
--------          --------         --------         - --------         - --------
5                 5                5                  5                  5
- (8 %e        )/((500 %e         - 125 %e         - 125 %e           - 125 %e
4 %i %pi
--------
3         5
- 125) (x - 1) ) + %e
4 %i %pi         2 %i %pi           2 %i %pi           4 %i %pi
--------         --------         - --------         - --------
5                5                  5                  5
/((500 %e         - 125 %e         - 125 %e           - 125 %e           - 125)
4
(x - 1) )
(%i4) tex(O);
$${{41992\,e^{{{4\,i\,\pi}\over{5}}}+42160\,e^{{{2\,i\,\pi}\over{5}}} +42076\,e^ {- {{2\,i\,\pi}\over{5}} }+41824\,e^ {- {{4\,i\,\pi }\over{5}} }+42328}\over{\left(625\,e^{{{4\,i\,\pi}\over{5}}}-625\,e ^{{{2\,i\,\pi}\over{5}}}+1875\,e^ {- {{4\,i\,\pi}\over{5}} }-1875 \right)\,\left(e^{{{4\,i\,\pi}\over{5}}}\,x-1\right)}}+{{1082\,e^{{{ 4\,i\,\pi}\over{5}}}+1018\,e^{{{2\,i\,\pi}\over{5}}}+1114\,e^ {- {{2 \,i\,\pi}\over{5}} }+1114\,e^ {- {{4\,i\,\pi}\over{5}} }+1082}\over{ \left(-1250\,e^{{{2\,i\,\pi}\over{5}}}+625\,e^ {- {{2\,i\,\pi}\over{ 5}} }+625\,e^ {- {{4\,i\,\pi}\over{5}} }\right)\,\left(e^{{{4\,i\, \pi}\over{5}}}\,x-1\right)^2}}+{{28\,e^{{{4\,i\,\pi}\over{5}}}+20\,e ^{{{2\,i\,\pi}\over{5}}}+12\,e^ {- {{2\,i\,\pi}\over{5}} }+20\,e ^ {- {{4\,i\,\pi}\over{5}} }+20}\over{\left(625\,e^ {- {{2\,i\,\pi }\over{5}} }-625\,e^{{{4\,i\,\pi}\over{5}}}\right)\,\left(e^{{{4\,i \,\pi}\over{5}}}\,x-1\right)^3}}+{{1}\over{\left(-125\,e^{{{4\,i\, \pi}\over{5}}}-125\,e^{{{2\,i\,\pi}\over{5}}}-125\,e^ {- {{2\,i\,\pi }\over{5}} }-125\,e^ {- {{4\,i\,\pi}\over{5}} }+500\right)\,\left(e ^{{{4\,i\,\pi}\over{5}}}\,x-1\right)^4}}-{{-1544\,e^{{{4\,i\,\pi }\over{5}}}-1880\,e^{{{2\,i\,\pi}\over{5}}}-32\,e^ {- {{2\,i\,\pi }\over{5}} }-368\,e^ {- {{4\,i\,\pi}\over{5}} }-956}\over{\left(- 4375\,e^{{{4\,i\,\pi}\over{5}}}-6875\,e^{{{2\,i\,\pi}\over{5}}}+6875 \,e^ {- {{2\,i\,\pi}\over{5}} }+4375\,e^ {- {{4\,i\,\pi}\over{5}} } \right)\,\left(e^{{{2\,i\,\pi}\over{5}}}\,x-1\right)}}+{{42\,e^{{{4 \,i\,\pi}\over{5}}}+170\,e^{{{2\,i\,\pi}\over{5}}}+42\,e^ {- {{2\,i \,\pi}\over{5}} }-54\,e^ {- {{4\,i\,\pi}\over{5}} }+170}\over{\left( -625\,e^{{{4\,i\,\pi}\over{5}}}+1875\,e^{{{2\,i\,\pi}\over{5}}}-625 \,e^ {- {{2\,i\,\pi}\over{5}} }-2500\,e^ {- {{4\,i\,\pi}\over{5}} }+ 1875\right)\,\left(e^{{{2\,i\,\pi}\over{5}}}\,x-1\right)^2}}-{{4\,e ^{{{4\,i\,\pi}\over{5}}}-4\,e^{{{2\,i\,\pi}\over{5}}}-12\,e^ {- {{2 \,i\,\pi}\over{5}} }+4\,e^ {- {{4\,i\,\pi}\over{5}} }-12}\over{ \left(625\,e^{{{4\,i\,\pi}\over{5}}}-625\,e^ {- {{2\,i\,\pi}\over{5 }} }+625\,e^ {- {{4\,i\,\pi}\over{5}} }-625\right)\,\left(e^{{{2\,i \,\pi}\over{5}}}\,x-1\right)^3}}+{{e^ {- {{2\,i\,\pi}\over{5}} } }\over{\left(-125\,e^{{{4\,i\,\pi}\over{5}}}-125\,e^{{{2\,i\,\pi }\over{5}}}+500\,e^ {- {{2\,i\,\pi}\over{5}} }-125\,e^ {- {{4\,i\, \pi}\over{5}} }-125\right)\,\left(e^{{{2\,i\,\pi}\over{5}}}\,x-1 \right)^4}}-{{41824\,e^{{{4\,i\,\pi}\over{5}}}+42076\,e^{{{2\,i\,\pi }\over{5}}}+42160\,e^ {- {{2\,i\,\pi}\over{5}} }+41992\,e^ {- {{4\,i \,\pi}\over{5}} }+42328}\over{\left(625\,e^{{{4\,i\,\pi}\over{5}}}- 625\,e^{{{2\,i\,\pi}\over{5}}}+1875\,e^ {- {{4\,i\,\pi}\over{5}} }- 1875\right)\,\left(x-e^{{{4\,i\,\pi}\over{5}}}\right)}}+{{1114\,e^{ {{4\,i\,\pi}\over{5}}}+1082\,e^{{{2\,i\,\pi}\over{5}}}+1082\,e^ {- {{2\,i\,\pi}\over{5}} }+1114\,e^ {- {{4\,i\,\pi}\over{5}} }+1018 }\over{\left(-1250\,e^{{{2\,i\,\pi}\over{5}}}+625\,e^ {- {{2\,i\,\pi }\over{5}} }+625\,e^ {- {{4\,i\,\pi}\over{5}} }\right)\,\left(x-e^{ {{4\,i\,\pi}\over{5}}}\right)^2}}-{{20\,e^{{{4\,i\,\pi}\over{5}}}+20 \,e^{{{2\,i\,\pi}\over{5}}}+20\,e^ {- {{2\,i\,\pi}\over{5}} }+12\,e ^ {- {{4\,i\,\pi}\over{5}} }+28}\over{\left(625\,e^ {- {{2\,i\,\pi }\over{5}} }-625\,e^{{{4\,i\,\pi}\over{5}}}\right)\,\left(x-e^{{{4\, i\,\pi}\over{5}}}\right)^3}}+{{e^ {- {{4\,i\,\pi}\over{5}} }}\over{ \left(-125\,e^{{{4\,i\,\pi}\over{5}}}-125\,e^{{{2\,i\,\pi}\over{5}}} -125\,e^ {- {{2\,i\,\pi}\over{5}} }-125\,e^ {- {{4\,i\,\pi}\over{5}} }+500\right)\,\left(x-e^{{{4\,i\,\pi}\over{5}}}\right)^4}}-{{32\,e ^{{{4\,i\,\pi}\over{5}}}+956\,e^{{{2\,i\,\pi}\over{5}}}+1544\,e^ {- {{2\,i\,\pi}\over{5}} }+368\,e^ {- {{4\,i\,\pi}\over{5}} }+1880 }\over{\left(-4375\,e^{{{4\,i\,\pi}\over{5}}}-6875\,e^{{{2\,i\,\pi }\over{5}}}+6875\,e^ {- {{2\,i\,\pi}\over{5}} }+4375\,e^ {- {{4\,i\, \pi}\over{5}} }\right)\,\left(x-e^{{{2\,i\,\pi}\over{5}}}\right)}}+ {{170\,e^{{{4\,i\,\pi}\over{5}}}+42\,e^{{{2\,i\,\pi}\over{5}}}+42\,e ^ {- {{2\,i\,\pi}\over{5}} }+170\,e^ {- {{4\,i\,\pi}\over{5}} }-54 }\over{\left(-625\,e^{{{4\,i\,\pi}\over{5}}}+1875\,e^{{{2\,i\,\pi }\over{5}}}-625\,e^ {- {{2\,i\,\pi}\over{5}} }-2500\,e^ {- {{4\,i\, \pi}\over{5}} }+1875\right)\,\left(x-e^{{{2\,i\,\pi}\over{5}}} \right)^2}}-{{-4\,e^{{{4\,i\,\pi}\over{5}}}+12\,e^{{{2\,i\,\pi }\over{5}}}+4\,e^ {- {{2\,i\,\pi}\over{5}} }-4\,e^ {- {{4\,i\,\pi }\over{5}} }+12}\over{\left(625\,e^{{{4\,i\,\pi}\over{5}}}-625\,e ^ {- {{2\,i\,\pi}\over{5}} }+625\,e^ {- {{4\,i\,\pi}\over{5}} }-625 \right)\,\left(x-e^{{{2\,i\,\pi}\over{5}}}\right)^3}}+{{e^ {- {{4\,i \,\pi}\over{5}} }}\over{\left(-125\,e^{{{4\,i\,\pi}\over{5}}}-125\,e ^{{{2\,i\,\pi}\over{5}}}+500\,e^ {- {{2\,i\,\pi}\over{5}} }-125\,e ^ {- {{4\,i\,\pi}\over{5}} }-125\right)\,\left(x-e^{{{2\,i\,\pi }\over{5}}}\right)^4}}-{{120\,e^{{{4\,i\,\pi}\over{5}}}+120\,e^{{{2 \,i\,\pi}\over{5}}}-132\,e^ {- {{2\,i\,\pi}\over{5}} }+36\,e^ {- {{4 \,i\,\pi}\over{5}} }+36}\over{\left(625\,e^{{{4\,i\,\pi}\over{5}}}+ 625\,e^{{{2\,i\,\pi}\over{5}}}-1250\,e^ {- {{2\,i\,\pi}\over{5}} } \right)\,\left(x-1\right)}}+{{36\,e^{{{4\,i\,\pi}\over{5}}}+36\,e^{ {{2\,i\,\pi}\over{5}}}-60\,e^ {- {{2\,i\,\pi}\over{5}} }+4\,e^ {- {{ 4\,i\,\pi}\over{5}} }+4}\over{\left(625\,e^{{{4\,i\,\pi}\over{5}}}+ 625\,e^{{{2\,i\,\pi}\over{5}}}-1250\,e^ {- {{2\,i\,\pi}\over{5}} } \right)\,\left(x-1\right)^2}}-{{8\,e^{{{4\,i\,\pi}\over{5}}}}\over{ \left(500\,e^{{{4\,i\,\pi}\over{5}}}-125\,e^{{{2\,i\,\pi}\over{5}}}- 125\,e^ {- {{2\,i\,\pi}\over{5}} }-125\,e^ {- {{4\,i\,\pi}\over{5}} }-125\right)\,\left(x-1\right)^3}}+{{e^{{{4\,i\,\pi}\over{5}}} }\over{\left(500\,e^{{{4\,i\,\pi}\over{5}}}-125\,e^{{{2\,i\,\pi }\over{5}}}-125\,e^ {- {{2\,i\,\pi}\over{5}} }-125\,e^ {- {{4\,i\, \pi}\over{5}} }-125\right)\,\left(x-1\right)^4}}$$
(%o4)                                false
(%i5) 
Run Example
P:30-(Q1+Q2+Q3);
(%o1)                         - Q3 - Q2 - Q1 + 30
(%i2) REV3:P*Q3;
(%o2)                      (- Q3 - Q2 - Q1 + 30) Q3
(%i3) MR3:diff(REV3,Q3);
(%o3)                        - 2 Q3 - Q2 - Q1 + 30
(%i4) COST3:Q3^2/3;
2
Q3
(%o4)                                 ---
3
(%i5) MC2:diff(COST3,Q3);
2 Q3
(%o5)                                ----
3
(%i6) sol3:solve(MR3=MC3,Q3);
Q2 + Q1 + MC3 - 30
(%o6)                     [Q3 = - ------------------]
2
(%i7) br3:sol3[1];
Q2 + Q1 + MC3 - 30
(%o7)                      Q3 = - ------------------
2
(%i8) Q3:rhs(br3);
Q2 + Q1 + MC3 - 30
(%o8)                        - ------------------
2
(%i9) P:30-(Q1+Q2+Q3);
Q2 + Q1 + MC3 - 30
(%o9)                  ------------------ - Q2 - Q1 + 30
2
(%i10) REV2:P*Q2;
Q2 + Q1 + MC3 - 30
(%o10)              Q2 (------------------ - Q2 - Q1 + 30)
2
(%i11) MR2:diff(REV1,Q1);
(%o11)                                 0
(%i12) COST2:Q2^2/2;
2
Q2
(%o12)                                ---
2
(%i13) MC2:diff(COST2,Q2);
(%o13)                                Q2
(%i14) sol2:solve(MR2=MC2,Q2);
(%o14)                             [Q2 = 0]
(%i15) br2:sol2[1];
(%o15)                              Q2 = 0
(%i16) Q2:rhs(br2);
(%o16)                                 0
(%i17) ev (Q3, sol2);
Q1 + MC3 - 30
(%o17)                          - -------------
2
(%i18) P:30-(Q1+Q2+Q3);
Q2 + Q1 + MC3 - 30
(%o18)                   ------------------ - Q1 + 30
2
(%i19) REV1:P*Q1;
Q2 + Q1 + MC3 - 30
(%o19)                 Q1 (------------------ - Q1 + 30)
2
(%i20) MR1:diff(REV1,Q1);
Q2 + Q1 + MC3 - 30   3 Q1
(%o20)                  ------------------ - ---- + 30
2             2
(%i21) COST1:Q1^2;
2
(%o21)                                Q1
(%i22) MC1:diff(COST1,Q1);
(%o22)                               2 Q1
(%i23) Sol1:solve(MR1=MC1,Q1);
Q2 + MC3 + 30
(%o23)                       [Q1 = -------------]
6
(%i24) ev(Q2,sol1);
(%o24)                                 0
(%i25) ev(Q1,sol2);
(%o25)                                Q1
(%i26) 

Help for Rhs