Chapter 10 Multiplicaton of Algebraical Expressions

Example 10_1 pgno:120

In [3]:
x=('x')#is a poly nomial function with degree zero for my convinence i assume it to be one poly(0,'x');poly(0,'x');
p1=('2*x+5');
p2=('3*x+4');
ans='p1*p2'
print '6*x**2+23*x+20'
6*x**2+23*x+20

Example 10_2 pgno:121

In [4]:
x=('x')#is a poly nomial function with degree zero for my convinence i assume it to be one poly(0,'x');poly(0,'x');poly(0,'x');
p1=('3*x+7');
p2=('2*x+1');
p3='p1*p2';
print "6*x**2+17*x+7"
print "product=",p3
6*x**2+17*x+7
product= p1*p2

Example 10_3 pgno:121

In [8]:
x=('x')#is a poly nomial function with degree zero for my convinence i assume it to be one poly(0,'x');poly(0,'x');poly(0,'x');poly(0,'x');
p1=('7*x-5');
p2=('2*x+3');
p3='p1*p2';
print "14*x**2+11*x-15"
print "product=",p3
14*x**2+11*x-15
product= p1*p2

Example 10_4 pgno:121

In [6]:
x=('x')#is a poly nomial function with degree zero for my convinence i assume it to be one poly(0,'x');poly(0,'x');poly(0,'x');poly(0,'x');poly(0,'x');
p1=('3*x-2');
p2=('4*x-7');
p3='p1*p2';
print"12*x**2-29*x+14"
print "product=",p3
12*x**2-29*x+14
product= p1*p2

Example 10_5 pgno:121

In [7]:
x=('x')#is a poly nomial function with degree zero for my convinence i assume it to be one poly(0,'x');poly(0,'x');poly(0,'x');poly(0,'x');
p1=('x+2');
p2=('x**2-x+1');
p3='p1*p2';#on collecting like terms
print "x**3+x**2+x+2"
print "product=",p3
x**3+x**2+x+2
product= p1*p2

Example 10_6 pgno:121

In [11]:
#(a+b)*(a^2-ab+b^2)
#on collecting like terms
print('a^3+b^3')
a^3+b^3