Computational complexity question

AI Thread Summary
The algorithm's computational complexity is represented by the expression $(N-1) + \sum_{i=1}^{N-3}(i+1)(N-2)!/{i!}$. In Big O Notation, this simplifies to O(n!), indicating factorial time complexity. The sum contributes significantly to the overall complexity, approximating to (n - 2)!. The coefficients in the sum are negligible, allowing for their exclusion in the final complexity assessment. The discussion confirms the accuracy of this representation.
pemfir
Messages
4
Reaction score
0
how can i represent the computational complexity an algorithm that requires the following number of operations: (please see attached document)

Code:
$(N-1) + \sum_{i=1}^{N-3}(i+1)(N-2)!/{i!}$
 

Attachments

  • computational complexity.JPG
    computational complexity.JPG
    1.9 KB · Views: 426
Mathematics news on Phys.org
In Big O Notation, that would be simply O(n!) I believe, factorial time. The sum group amounts to (n - 2)! with a coefficient 2 + 1.5 + 0.6666 +... which is discarded (so is the -2), and the n - 1 grows so slow relative to the rest that it can be discarded to.
 
thank you very much you are precisely correct
 
Seemingly by some mathematical coincidence, a hexagon of sides 2,2,7,7, 11, and 11 can be inscribed in a circle of radius 7. The other day I saw a math problem on line, which they said came from a Polish Olympiad, where you compute the length x of the 3rd side which is the same as the radius, so that the sides of length 2,x, and 11 are inscribed on the arc of a semi-circle. The law of cosines applied twice gives the answer for x of exactly 7, but the arithmetic is so complex that the...
Is it possible to arrange six pencils such that each one touches the other five? If so, how? This is an adaption of a Martin Gardner puzzle only I changed it from cigarettes to pencils and left out the clues because PF folks don’t need clues. From the book “My Best Mathematical and Logic Puzzles”. Dover, 1994.

Similar threads

Replies
1
Views
1K
Replies
1
Views
1K
Replies
1
Views
1K
Replies
18
Views
2K
3
Replies
108
Views
10K
Replies
1
Views
1K
Back
Top