M. Blum, R. W. Floyd, V. Pratt, R. Rivest, R. Tarjan
{"title":"Linear time bounds for median computations","authors":"M. Blum, R. W. Floyd, V. Pratt, R. Rivest, R. Tarjan","doi":"10.1145/800152.804904","DOIUrl":null,"url":null,"abstract":"New upper and lower bounds are presented for the maximum number of comparisons, f(i,n), required to select the i-th largest of n numbers. An upper bound is found, by an analysis of a new selection algorithm, to be a linear function of n: f(i,n) ≤ 103n/18 < 5.73n, for 1 ≤ i ≤ n. A lower bound is shown deductively to be: f(i,n) ≥ n+min(i,n−i+l) + [log2(n)] − 4, for 2 ≤ i ≤ n−1, or, for the case of computing medians: f([n/2],n) ≥ 3n/2 − 3","PeriodicalId":229726,"journal":{"name":"Proceedings of the fourth annual ACM symposium on Theory of computing","volume":"46 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"1972-05-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"53","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"Proceedings of the fourth annual ACM symposium on Theory of computing","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1145/800152.804904","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 53
Abstract
New upper and lower bounds are presented for the maximum number of comparisons, f(i,n), required to select the i-th largest of n numbers. An upper bound is found, by an analysis of a new selection algorithm, to be a linear function of n: f(i,n) ≤ 103n/18 < 5.73n, for 1 ≤ i ≤ n. A lower bound is shown deductively to be: f(i,n) ≥ n+min(i,n−i+l) + [log2(n)] − 4, for 2 ≤ i ≤ n−1, or, for the case of computing medians: f([n/2],n) ≥ 3n/2 − 3