hadoop-common-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Shi Yu <sh...@uchicago.edu>
Subject Re: Factorial in Map-Reduce
Date Thu, 14 Oct 2010 22:59:29 GMT
I don't think so. If the problem was to find the super large prime 
number it could be a nice Map/reduce task, but simply calculating the 
factorial is a monotonically complexity increasing task. If it is split 
into multiple tasks, how to shuffle the complexity ?  To multiply the 
head and the tail first, then move to the center? Some easy tasks will 
be finished earlier and just hang there waiting for the complicated 
ones. Later, the reducer part still need to take much burden to multiply 
all the numbers back, which probably won't gain much efficiency through 
the Map/Reduce fashion.

In contrast, the prime number task is doable, because it could be easily 
segmented into different zones and be reported back to the reducer.

Shi


On 2010-10-14 17:36, Greg Roelofs wrote:
> factorial of number


Mime
View raw message