write a c++ class called polynamial with the following functionality.
1: read the polynomial from a file.
2:addition of two polynomial.
3: multiplication of two polynomial...?
Answers
Answered by
0
Explanation:
Program to add two polynomials
Given two polynomials represented by two arrays, write a function that adds given two polynomials.
Example:
Input: A[] = {5, 0, 10, 6} B[] = {1, 2, 4} Output: sum[] = {6, 2, 14, 6} The first input array represents "5 + 0x^1 + 10x^2 + 6x^3" The second array represents "1 + 2x^1 + 4x^2" And Output is "6 + 2x^1 + 14x^2 + 6x^3"
We strongly recommend to minimize your browser and try this yourself first.
Addition is simpler than multiplication of polynomials. We initialize result as one of the two polynomials, then we traverse the other polynomial and add all terms to the result.
Similar questions
Math,
2 months ago
Math,
2 months ago
Accountancy,
5 months ago
History,
10 months ago
English,
10 months ago