Google Answers Logo
View Question
 
Q: Data structure and algorithm ( No Answer,   1 Comment )
Question  
Subject: Data structure and algorithm
Category: Computers > Algorithms
Asked by: math01-ga
List Price: $5.00
Posted: 16 Jul 2003 07:56 PDT
Expires: 24 Jul 2003 11:04 PDT
Question ID: 231618
Design a divide-and-conquer algorithm for polynomial evaluation and
Show the number of operations required by the algorithm.
Answer  
There is no answer at this time.

Comments  
Subject: Re: Data structure and algorithm
From: mathtalk-ga on 23 Jul 2003 15:44 PDT
 
Hi, math01-ga:

I'm not sure if you are still interested in an answer to this
question, since you expired a few others that went unanswered for a
few days.

"Divide-and-conquer" suggests an algorithm which is suitable for
parallel implmementation.  In particular this phrase is often used for
recursive algorithms that split the input data (presumably the
polynomial coefficients in this case) into two more-or-less equal
subsets for processing, the results of which can then be recombined to
give the final output.

One such scheme that is easy to implement is to separate out the even
and odd degree terms of a polynomial, so that:

P(x) = x*Q(x^2) + E(x^2)

where E(x) is a polynomial of half the degree or less than P(x) which
collects its even terms as E(x^2), and similarly Q(x) is a smaller
degree polynomial such that x*Q(x^2) has all the odd terms of P(x).

The data needed to evaluate E(x^2) and Q(x^2) are disjoint, so this is
especially attractive for a distributed computation in which there
need be little "shared memory" between processors.

I'll let you work out the operation count, if you are still
interested.  Note that the algorithm can be implemented on an ordinary
CPU architecture as a recursive procedure.  The procedure computes x^2
(one multiplication), calls itself twice (on roughly half the size
inputs each time), and finally recombines the subprocedure outputs
using one addition and one multiplication.

From this description the overall operation count is easily found by
induction.

regards, mathtalk-ga

Important Disclaimer: Answers and comments provided on Google Answers are general information, and are not intended to substitute for informed professional medical, psychiatric, psychological, tax, legal, investment, accounting, or other professional advice. Google does not endorse, and expressly disclaims liability for any product, manufacturer, distributor, service or service provider mentioned or any opinion expressed in answers or comments. Please read carefully the Google Answers Terms of Service.

If you feel that you have found inappropriate content, please let us know by emailing us at answers-support@google.com with the question ID listed above. Thank you.
Search Google Answers for
Google Answers  


Google Home - Answers FAQ - Terms of Service - Privacy Policy