当前你的浏览器版本过低,网站已在兼容模式下运行,兼容模式仅提供最小功能支持,网站样式可能显示不正常。
请尽快升级浏览器以体验网站在线编辑、在线运行等功能。
x = P(y) =a0 +a1.y +a2.y2 + ... +am.ym
The number of satisfied customers depends on the price of a product. Again, there is hypothese that this dependence is polynomial. If we denote the price z, we can write
y = Q(x) =b0 +b1.z +b2.z2 + ... +bn.zn
Coeficients ai and bi strongly depend on the season of the year, the moon phase, the purchasing power of customers, inflation rate and hunderds of other parameters. Besides on the kind of product and its quality, of course. In the past there was lot of effort put into the reserarch of these parameters. For various combinations of input parameters, the coeficients are stated in Pyshwejc's marketing tables. It is not thus difficult to find out their values. But the degree of polynoms is usualy very high. It is very difficult to substitute one polynom into the other and to compute the dependency of the profit on the price. This dependency is usually crucial for us to set the right price.
Your goal is to write the program which can substitute the polynom Q into the polynom P and determine the restulting polynom R indicating dependency of the profit on the price:
x = R(z) =c0 +c1.z +c2.z2 + ... +cp.zp
3 0 0 7 -2 1 1 6 6 9 -6 3 3 -3 6 -5 1 0 3 -3 1
7 60 -36 -3 18 -63 123 -156 138 -86 36 -9 1
时间上限 | 内存上限 |
1000 | 30000 |