Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Special pages
Niidae Wiki
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
Subset sum problem
(section)
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
=== Schroeppel and Shamir === In 1981, [[Richard Schroeppel|Schroeppel]] and [[Adi Shamir|Shamir]] presented an algorithm<ref>{{Cite journal|last1=Schroeppel|first1=Richard|last2=Shamir|first2=Adi|date=1981-08-01|title=A {{math|''T'' {{=}} ''O''(2<sup>''n''/2</sup>)}}, {{math|''S'' {{=}} ''O''(2<sup>''n''/4</sup>)}} algorithm for certain NP-complete problems|url=https://epubs.siam.org/doi/abs/10.1137/0210033|journal=SIAM Journal on Computing|volume=10|issue=3|pages=456β464|doi=10.1137/0210033|issn=0097-5397}}</ref> based on Horowitz and Sanhi, that requires similar runtime - <math>O( 2^{n/2}\cdot (n/4))</math>, much less space - <math>O(2^{n/4})</math>. Rather than generating and storing all subsets of ''n''/2 elements in advance, they partition the elements into 4 sets of ''n''/4 elements each, and generate subsets of ''n''/2 element pairs dynamically using a [[min heap]], which yields the above time and space complexities since this can be done in <math>O(k^{2}\log(k))</math> and space <math>O(k)</math> given 4 lists of length k. Due to space requirements, the HS algorithm is practical for up to about 50 integers, and the SS algorithm is practical for up to 100 integers.<ref name=":0" />
Summary:
Please note that all contributions to Niidae Wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Encyclopedia:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Search
Search
Editing
Subset sum problem
(section)
Add topic