Comb sort: Difference between revisions

From formulasearchengine
Jump to navigation Jump to search
 
Line 1: Line 1:
{{other uses2|Alphabeta}}
Are that you searching for shade leaflets, color flyers, four color postcard, coloring flyers orshade leaflets?<br>Then you're examining the ideal knowledge. Printing In Color Singapore is often a corporation that might connect your whole needs when talkingrelating tostamping. Color printing products accepted as particularly proper and powerful on the same exact time. A person is virtually always seduced by the exquisite and singing shades, thus, making this crucial the products a specific postcard or brochures.<br><br>
{{Tree search algorithm}}


'''Alpha–beta pruning''' is a [[search algorithm]] that seeks to decrease the number of nodes that are evaluated by the [[Minimax#Minimax algorithm with alternate moves|minimax algorithm]] in its [[game tree|search tree]]. It is an adversarial search algorithm used commonly for machine playing of two-player games ([[Tic-tac-toe]], [[Chess]], [[Go (board game)|Go]], etc.). It stops completely evaluating a move when at least one possibility has been found that proves the move to be worse than a previously examined move. Such moves need not be evaluated further. When applied to a standard minimax tree, it returns the same move as minimax would, but prunes away branches that cannot possibly influence the final decision.<ref name="RN10">{{Cite book
Running a business, you get more likes should react really fast that should be affordable. get more likes Buy Facebook Likes for the established fb accounts that would bait prospects to take a look inside your fan page. When you have great enthusiasts, you will get a very good website existence. You will appreciate that buy facebook fans we have a considerable alteration of the outcome of your online business likes on facebook once you've increased your visitors. facebook page likes You will be entirely stunned when most people setup inquiring relating to the services get facebook likes or assistance buy facebook fans that you are currently providing. get facebook likes Overnite, facebook likes you will find out which your sales and profits could go up.<br><br>This will reduce the risk during the time you start this new opportunity. Most business people will tell you that, it will be better for you to start your untried venture as a supplemental income stream. Down the road, if you are happy with the results, you can choose if you will change to your new career as your future career.<br><br>There's been lots of discussion surrounding internet marketing. Anybody considering trading in their own individual internet business startup must think about a couple of things. It'll cost you under beginning a physical retail enterprise. For instance, you might be considering selling an info product inside a specific niche. You might simply need to buy a monthly server space, a website title and hang up an internet site. If you adored this write-up and you would such as to obtain additional facts regarding [http://lalasercenter.zendesk.com/entries/54452680-Practical-Online-Business-Solutions-An-Intro cara bisnis online shop bagi pemula] kindly see our web site. You will have to establish your program and market your offer to some specific market.<br><br>If you are preparing your product or service for pickup or shipping put in a special effect for the packing. A small touch such as a personalized note or perhaps an extra merchandise example, tends to make clients think that you care so you paid out particular awareness of their buy. This will likely convert them into perform repeatedly clients.<br><br>Transmit warns for you to prospective clients on the photos, not to mention integrate your good advertising platform from your snap shots. Yourrrre able to know one way to accomplish advertising and marketing actual story by connecting images; almost located in selection of some sort of PPT demonstration. You may even get modern and additionally express individuals how they could varyingly occurs products or services. You should to get some rudimentary know-how about taking photos ahead of when producing Instagram Followers. Additionally, it makes it possible for hashtags if you want to enhance web connection and update by working with Tweeting, where you can a lot more specific with regards to ideas.<br><br>Though, those numbers don't put down much room for go-getting pursuits. It will make more sense in outsourcing this requirement to ensure continuous sustainability and lasting scalability. If you treasured this article therefore you would like to obtain more info regarding hosting minecraft kindly visit our site. It also facilitates somebody to publish their own personal information resource to any other internet user. Also, it will give you you with a reasonable solutions for your business guarantee with your quality of service. Once your domain is registered, then you are going to need to direct your domains to a hosting service company.<br><br>6. Persuade visitors to buy your product by "becoming a fortune teller". Tell them what'll happen with their life in the future if they buy or don't buy. This is a type of "reverse-testimonial" that works well.<br><br>The plus point of starting an online business is your business will open 24 hours a day, 7 days a week and 365 days a year even when you are in a sleep, your [http://Search.Un.org/search?ie=utf8&site=un_org&output=xml_no_dtd&client=UN_Website_en&num=10&lr=lang_en&proxystylesheet=UN_Website_en&oe=utf8&q=business&Submit=Go business] could be making you money and waking up richer and richer every day is a great feeling. The internet makes it very, very easy and inexpensive for people to start an online home based business these days.<br><br>Learn the secrets of successful online marketing and strategies in order to beat the competition. One of the best ways to ensure your success in the online business is by using a proven program. If you want to be successful you will need to get people who are able to help you in the areas that you are weak. This is the single most common reason why people fail at their online business. Nobody is an expert in all aspects of running a business yet many people who start their own business expect to be.<br><br>Sunshine coast website design is just a local website design company that gives a broad array of Website Design alternatives focusing on design of quality web sites for today's demanding internet industry.<br>Site design is very important as it shows the potential of the company it represents. Supreme quality site design is vital for organizations and corporate organizations to advertise their online business and to market products to the clients. Businesses who wish to make the most of the web world today are bound to adjust their web site with the aid of Site Design Companies.
| first = Stuart J.
| last = Russell
| first2 = Peter
| last2 = Norvig
| title = Artificial Intelligence: A Modern Approach
| url = http://aima.cs.berkeley.edu/
| year = 2010
| edition = 3rd
| publisher = Pearson Education, Inc.
| publication-place = Upper Saddle River, New Jersey
| isbn = 0-13-604259-7
| author-link=Stuart J. Russell
| author2-link=Peter Norvig
| page=167
| postscript = <!-- Bot inserted parameter. Either remove it; or change its value to "." for the cite to end in a ".", as necessary. -->{{inconsistent citations}}
}}</ref>
 
==History==
[[Allen Newell]] and [[Herbert A. Simon]] who used what [[John McCarthy (computer scientist)|John McCarthy]] calls an "approximation"<ref name="JMC">{{cite web
  | author = McCarthy, John
  | title = Human Level AI Is Harder Than It Seemed in 1955
  | date = LaTeX2HTML 27 November 2006
  | url = http://www-formal.stanford.edu/jmc/slides/wrong/wrong-sli/wrong-sli.html
  | accessdate = 2006-12-20
}}</ref> in 1958 wrote that alpha–beta "appears to have been reinvented a number of times".<ref name=NS>{{cite journal
| author=Newell, Allen and Herbert A. Simon
| title=Computer Science as Empirical Inquiry: Symbols and Search
| journal=Communications of the ACM
| volume=19 |issue= 3
|date=March 1976
| url=http://archive.computerhistory.org/projects/chess/related_materials/text/2-3.Computer_science_as_empirical_inquiry/2-3.Computer_science_as_empirical_inquiry.newell_simon.1975.ACM.062303007.pdf
|format=PDF| accessdate=2006-12-21
}}</ref> [[Arthur Samuel]] had an early version and Richards, Hart, Levine and/or Edwards found alpha–beta independently in the [[United States]].<ref name="AIM30">{{cite web
  | author = Edwards, D.J. and Hart, T.P.
  | title = The Alpha–beta Heuristic (AIM-030)
  | publisher = Massachusetts Institute of Technology
  | date = 4 December 1961 to 28 October 1963
  | url = http://hdl.handle.net/1721.1/6098
  | accessdate = 2006-12-21
}}</ref> McCarthy proposed similar ideas during the [[Dartmouth Conference]] in 1956 and suggested it to a group of his students including [[Alan Kotok]] at MIT in 1961.<ref name="AIM41">{{cite web | last=Kotok | first=Alan | title=MIT Artificial Intelligence Memo 41 | date=XHTML 3 December 2004 | url=http://www.kotok.org/AI_Memo_41.html | accessdate=2006-07-01}}</ref> [[Alexander Brudno]] independently discovered the alpha–beta algorithm, publishing his results in 1963.<ref name=Marsland>{{cite web
  | author = [http://www.cs.ualberta.ca/~tony/ Marsland, T.A.]
  | title = Computer Chess Methods (PDF) from Encyclopedia of Artificial Intelligence. S. Shapiro (editor)
  | publisher = J. Wiley & Sons
  |date=May 1987
  | pages = 159–171
  | url = http://www.cs.ualberta.ca/~tony/OldPapers/encyc.mac.pdf
  |format=PDF| accessdate = 2006-12-21
}}</ref> [[Donald Knuth]] and Ronald W. Moore refined the algorithm in 1975<ref name=Knuth-Moore>* {{cite journal
  | author = Knuth, D. E., and Moore, R. W.
  | title = An Analysis of Alpha–Beta Pruning
  | journal = Artificial Intelligence
  |volume=6 |issue=4
  | year = 1975
  | pages = 293–326
  | accessdate =
  | url = http://www.fileserve.com/file/ZgR5t3j/An_Analysis_of_Alpha-Beta_Pruning.pdf
  | doi = 10.1016/0004-3702(75)90019-3
}}
:* Reprinted as Chapter 9 in {{cite book
| last = Knuth
| first = Donald E.
| title = Selected Papers on Analysis of Algorithms
| year = 2000
| publisher = Stanford, California: Center for the Study of Language and Information - CSLI Lecture Notes, no. 102
| url = http://www-cs-faculty.stanford.edu/~knuth/aa.html
| isbn = 1-57586-212-3
| oclc = 222512366
}}</ref><ref name=Abramson>{{cite journal
| author=Abramson, Bruce
| title=Control Strategies for Two-Player Games
| journal=ACM Computing Surveys
|date=June 1989
| url=http://www.theinformationist.com/pdf/constrat.pdf/
| accessdate=2008-08-20
| doi=10.1145/66443.66444
| volume=21
| issue=2
| pages=137
}} {{Dead link|date=September 2010|bot=H3llBot}}</ref> and [[Judea Pearl]] proved its optimality in 1982.<ref>{{cite journal|last=Pearl|first=Judea|title=The Solution for the Branching Factor of the Alpha–beta Pruning Algorithm and its Optimality|journal=Communications of the ACM|date=August 1982|volume=25|issue=8|pages=559–564}}</ref>
 
== Improvements over naive minimax ==
[[Image:AB pruning.svg|thumb|400px|An illustration of alpha–beta pruning. The grayed-out subtrees need not be explored (when moves are evaluated from left to right), since we know the group of subtrees as a whole yields the value of an equivalent subtree or worse, and as such cannot influence the final result. The max and min levels represent the turn of the player and the adversary, respectively.]]
The benefit of alpha–beta pruning lies in the fact that branches of the search tree can be eliminated. This way, the search time can be limited to the 'more promising' subtree, and a deeper search can be performed in the same time. Like its predecessor, it belongs to the [[branch and bound]] class of algorithms. The optimization reduces the effective depth to slightly more than half that of simple minimax if the nodes are evaluated in an optimal or near optimal order (best choice for side on move ordered first at each node).
 
With an (average or constant) [[branching factor]] of ''b'', and a search depth of ''d'' [[Ply (game theory)|plies]], the maximum number of leaf node positions evaluated (when the move ordering is [[wiktionary:pessimal|pessimal]]) is [[Big O notation|''O'']](''b''*''b''*...*''b'') = ''O''(''b''<sup>''d''</sup>) – the same as a simple minimax search. If the move ordering for the search is optimal (meaning the best moves are always searched first), the number of leaf node positions evaluated is about ''O''(''b''*1*''b''*1*...*''b'') for odd depth and ''O''(''b''*1*''b''*1*...*1) for even depth, or <math>O(b^{d/2}) = O(\sqrt{b^d})</math>. In the latter case, where the ply of a search is even, the effective branching factor is reduced to its [[square root]], or, equivalently, the search can go twice as deep with the same amount of computation.<ref>{{Russell Norvig 2003}}</ref> The explanation of ''b''*1*''b''*1*... is that all the first player's moves must be studied to find the best one, but for each, only the best second player's move is needed to refute all but the first (and best) first player move – alpha–beta ensures no other second player moves need be considered. When nodes are ordered at random,
the average number of nodes evaluated is roughly
<math>O(b^{3d/4})</math>.<ref name="JMC" />
 
[[File:Minmaxab.gif|thumb|400px|An animated pedagogical example that attempts to be human-friendly by substituting initial infinite (or arbitrarily large) values for emptiness and by avoiding using the [[negamax]] coding simplifications.]]
Normally during alpha–beta, the subtrees are temporarily dominated by either a first player advantage (when many first player moves are good, and at each search depth the first move checked by the first player is adequate, but all second player responses are required to try to find a refutation), or vice versa. This advantage can switch sides many times during the search if the move ordering is incorrect, each time leading to inefficiency. As the number of positions searched decreases exponentially each move nearer the current position, it is worth spending considerable effort on sorting early moves. An improved sort at any depth will exponentially reduce the total number of positions searched, but sorting all positions at depths near the root node is relatively cheap as there are so few of them.  In practice, the move ordering is often determined by the results of earlier, smaller searches, such as through [[Iterative deepening depth-first search|iterative deepening]].
 
The algorithm maintains two values, alpha and beta, which represent the minimum score that the maximizing player is assured of and the maximum score that the minimizing player is assured of respectively. Initially alpha is negative infinity and beta is positive infinity. As the recursion progresses the "window" becomes smaller. When beta becomes less than alpha, it means that the current position cannot be the result of best play by both players and hence need not be explored further.
 
Additionally, this algorithm can be trivially modified to return an entire [[Variation (game tree)#Principal variation|principal variation]] in addition to the score. Some more aggressive algorithms such as [[MTD(f)]] do not easily permit such a modification.
 
==Pseudocode==
 
'''function''' alphabeta(node, depth, α, β, maximizingPlayer)
    '''if''' depth = 0 '''or''' node is a terminal node
        '''return''' the heuristic value of node
    '''if''' maximizingPlayer
        '''for each''' child of node
            α := max(α, alphabeta(child, depth - 1, α, β, FALSE))
            '''if''' β ≤ α
                '''break''' ''(* β cut-off *)''
        '''return''' α
    '''else'''
        '''for each''' child of node
            β := min(β, alphabeta(child, depth - 1, α, β, TRUE))
            '''if''' β ≤ α
                '''break''' ''(* α cut-off *)''
        '''return''' β
''(* Initial call *)''
alphabeta(origin, depth, -[[Infinity|∞]], +[[Infinity|∞]], TRUE)
 
== Heuristic improvements ==
Further improvement can be achieved without sacrificing accuracy, by using ordering [[heuristic]]s to search parts of the tree that are likely to force alpha–beta cutoffs early. For example, in chess, moves that take pieces may be examined before moves that do not, or moves that have scored highly in [[Iterative deepening depth-first search|earlier passes]] through the game-tree analysis may be evaluated before others. Another common, and very cheap, heuristic is the [[killer heuristic]], where the last move that caused a beta-cutoff at the same level in the tree search is always examined first.  This idea can be generalized into a set of [[refutation table]]s.
 
Alpha–beta search can be made even faster by considering only a narrow search window (generally determined by guesswork based on experience). This is known as ''aspiration search''. In the extreme case, the search is performed with alpha and beta equal; a technique known as ''zero-window search'', ''null-window search'', or ''scout search''. This is particularly useful for win/loss searches near the end of a game where the extra depth gained from the narrow window and a simple win/loss evaluation function may lead to a conclusive result. If an aspiration search fails, it is straightforward to detect whether it failed ''high'' (high edge of window was too low) or ''low'' (lower edge of window was too high). This gives information about what window values might be useful in a re-search of the position.
 
== Other algorithms ==
More advanced algorithms that are even faster while still being able to compute the exact minimax value are known, such as SCOUT,<ref>Pearl, J., "SCOUT: A Simple Game-Searching Algorithm With Proven Optimal Properties," ''Proceedings of the First Annual National Conference on Artificial Intelligence,'' Stanford University, August 18–21, 1980, pp. 143-145.</ref> [[Negascout]] and [[MTD-f]]. 
 
Since the minimax algorithm and its variants are inherently [[depth-first search|depth-first]], a strategy such as [[Iterative deepening depth-first search|iterative deepening]] is usually used in conjunction with alpha–beta so that a reasonably good move can be returned even if the algorithm is interrupted before it has finished execution. Another advantage of using iterative deepening is that searches at shallower depths give move-ordering hints, as well as shallow alpha and beta estimates, that both can help produce cutoffs for higher depth searches much earlier than would otherwise be possible.
 
Algorithms like [[SSS*]], on the other hand, use the [[best first search|best-first]] strategy. This can potentially make them more time-efficient, but typically at a heavy cost in space-efficiency.<ref>{{citation|doi=10.1146/annurev.cs.02.060187.002315|title=Search techniques|journal=Annual Review of Computer Science|volume=2|pages=451–467|year=1987|first1=Judea|last1=Pearl|author1-link=Judea Pearl|first2=Richard|last2=Korf|quote=Like its A* counterpart for single-player games, SSS* is optimal in terms of the average number of nodes examined; but its superior pruning power is more than offset by the substantial storage space and bookkeeping required.}}</ref>
 
== See also ==
* [[Pruning (algorithm)]]
* [[Branch and bound]]
* [[Minimax]]
* [[Combinatorial optimization]]
* [[Negamax]]
* [[Transposition table]]
 
== References ==
* {{cite book | author=George T. Heineman, Gary Pollice, and Stanley Selkow | title= Algorithms in a Nutshell | publisher=[[Oreilly Media]] | year=2008 | chapter=Chapter 7: Path Finding in AI | pages = 217–223 | isbn=978-0-596-51624-6 }}
* [[Judea Pearl]], ''Heuristics'', Addison-Wesley, 1984
<references/>
 
== External links ==
* http://www.emunix.emich.edu/~evett/AI/AlphaBeta_movie/sld001.htm
* http://sern.ucalgary.ca/courses/CPSC/533/W99/presentations/L1_5B_McCullough_Melnyk/
* http://sern.ucalgary.ca/courses/CPSC/533/W99/presentations/L2_5B_Lima_Neitz/search.html
* http://www.maths.nott.ac.uk/personal/anw/G13GAM/alphabet.html
* http://chess.verhelst.org/search.html
* http://www.frayn.net/beowulf/index.html
* http://hal.inria.fr/docs/00/12/15/16/PDF/RR-6062.pdf
* [http://ksquared.de/gamevisual/launch.php?agent=2 Minimax (with or without alpha–beta pruning) algorithm visualization - game tree solving (Java Applet), for balance or off-balance trees]
* [http://homepage.ufp.pt/~jtorres/ensino/ia/alfabeta.html Demonstration/animation of minimax game search algorithm with alpha–beta pruning (using html5, canvas, javascript, css)]
{{Game theory}}
 
{{DEFAULTSORT:Alpha-Beta Pruning}}
[[Category:Game artificial intelligence]]
[[Category:Graph algorithms]]
[[Category:Optimization algorithms and methods]]
[[Category:Search algorithms]]
[[Category:Articles with example pseudocode]]
 
{{Link GA|de}}

Latest revision as of 13:49, 6 January 2015

Are that you searching for shade leaflets, color flyers, four color postcard, coloring flyers orshade leaflets?
Then you're examining the ideal knowledge. Printing In Color Singapore is often a corporation that might connect your whole needs when talkingrelating tostamping. Color printing products accepted as particularly proper and powerful on the same exact time. A person is virtually always seduced by the exquisite and singing shades, thus, making this crucial the products a specific postcard or brochures.

Running a business, you get more likes should react really fast that should be affordable. get more likes Buy Facebook Likes for the established fb accounts that would bait prospects to take a look inside your fan page. When you have great enthusiasts, you will get a very good website existence. You will appreciate that buy facebook fans we have a considerable alteration of the outcome of your online business likes on facebook once you've increased your visitors. facebook page likes You will be entirely stunned when most people setup inquiring relating to the services get facebook likes or assistance buy facebook fans that you are currently providing. get facebook likes Overnite, facebook likes you will find out which your sales and profits could go up.

This will reduce the risk during the time you start this new opportunity. Most business people will tell you that, it will be better for you to start your untried venture as a supplemental income stream. Down the road, if you are happy with the results, you can choose if you will change to your new career as your future career.

There's been lots of discussion surrounding internet marketing. Anybody considering trading in their own individual internet business startup must think about a couple of things. It'll cost you under beginning a physical retail enterprise. For instance, you might be considering selling an info product inside a specific niche. You might simply need to buy a monthly server space, a website title and hang up an internet site. If you adored this write-up and you would such as to obtain additional facts regarding cara bisnis online shop bagi pemula kindly see our web site. You will have to establish your program and market your offer to some specific market.

If you are preparing your product or service for pickup or shipping put in a special effect for the packing. A small touch such as a personalized note or perhaps an extra merchandise example, tends to make clients think that you care so you paid out particular awareness of their buy. This will likely convert them into perform repeatedly clients.

Transmit warns for you to prospective clients on the photos, not to mention integrate your good advertising platform from your snap shots. Yourrrre able to know one way to accomplish advertising and marketing actual story by connecting images; almost located in selection of some sort of PPT demonstration. You may even get modern and additionally express individuals how they could varyingly occurs products or services. You should to get some rudimentary know-how about taking photos ahead of when producing Instagram Followers. Additionally, it makes it possible for hashtags if you want to enhance web connection and update by working with Tweeting, where you can a lot more specific with regards to ideas.

Though, those numbers don't put down much room for go-getting pursuits. It will make more sense in outsourcing this requirement to ensure continuous sustainability and lasting scalability. If you treasured this article therefore you would like to obtain more info regarding hosting minecraft kindly visit our site. It also facilitates somebody to publish their own personal information resource to any other internet user. Also, it will give you you with a reasonable solutions for your business guarantee with your quality of service. Once your domain is registered, then you are going to need to direct your domains to a hosting service company.

6. Persuade visitors to buy your product by "becoming a fortune teller". Tell them what'll happen with their life in the future if they buy or don't buy. This is a type of "reverse-testimonial" that works well.

The plus point of starting an online business is your business will open 24 hours a day, 7 days a week and 365 days a year even when you are in a sleep, your business could be making you money and waking up richer and richer every day is a great feeling. The internet makes it very, very easy and inexpensive for people to start an online home based business these days.

Learn the secrets of successful online marketing and strategies in order to beat the competition. One of the best ways to ensure your success in the online business is by using a proven program. If you want to be successful you will need to get people who are able to help you in the areas that you are weak. This is the single most common reason why people fail at their online business. Nobody is an expert in all aspects of running a business yet many people who start their own business expect to be.

Sunshine coast website design is just a local website design company that gives a broad array of Website Design alternatives focusing on design of quality web sites for today's demanding internet industry.
Site design is very important as it shows the potential of the company it represents. Supreme quality site design is vital for organizations and corporate organizations to advertise their online business and to market products to the clients. Businesses who wish to make the most of the web world today are bound to adjust their web site with the aid of Site Design Companies.