首页 | 本学科首页   官方微博 | 高级检索  
相似文献
 共查询到20条相似文献,搜索用时 31 毫秒
1.
Finding the longest common subsequence (LCS) of two given sequences A=a0a1am−1 and B=b0b1bn−1 is an important and well studied problem. We consider its generalization, transposition-invariant LCS (LCTS), which has recently arisen in the field of music information retrieval. In LCTS, we look for the LCS between the sequences A+t=(a0+t)(a1+t)…(am−1+t) and B where t is any integer. We introduce a family of algorithms (motivated by the Hunt-Szymanski scheme for LCS), improving the currently best known complexity from O(mnloglogσ) to O(Dloglogσ+mn), where σ is the alphabet size and D?mn is the total number of dominant matches for all transpositions. Then, we demonstrate experimentally that some of our algorithms outperform the best ones from literature.  相似文献   

2.
Given a real number sequence A=(a1,a2,…,an), an average lower bound L, and an average upper bound U, the Average-Constrained Maximum-Sum Segment problem is to locate a segment A(i,j)=(ai,ai+1,…,aj) that maximizes i?k?jak subject to . In this paper, we give an O(n)-time algorithm for the case where the average upper bound is ineffective, i.e., U=∞. On the other hand, we prove that the time complexity of the problem with an effective average upper bound is Ω(nlogn) even if the average lower bound is ineffective, i.e., L=−∞.  相似文献   

3.
Let X and Y be two strings of lengths n and m, respectively, and k and l, respectively, be the numbers of runs in their corresponding run-length encoded forms. We propose a simple algorithm for computing the longest common subsequence of two given strings X and Y in O(kl+min{p1,p2}) time, where p1 and p2 denote the numbers of elements in the bottom and right boundaries of the matched blocks, respectively. It improves the previously known time bound O(min{nl,km}) and outperforms the time bounds O(kllogkl) or O((k+l+q)log(k+l+q)) for some cases, where q denotes the number of matched blocks.  相似文献   

4.
Given a sequenceA of lengthM and a regular expressionR of lengthP, an approximate regular expression pattern-matching algorithm computes the score of the optimal alignment betweenA and one of the sequencesB exactly matched byR. An alignment between sequencesA=a1a2 ... aM andB=b1b2... bN is a list of ordered pairs, (i1,j1), (i2j2), ..., (it,jtt) such that ik < ik+1 and jk < jk+1. In this case the alignmentaligns symbols aik and bjk, and leaves blocks of unaligned symbols, orgaps, between them. A scoring schemeS associates costs for each aligned symbol pair and each gap. The alignment's score is the sum of the associated costs, and an optimal alignment is one of minimal score. There are a variety of schemes for scoring alignments. In a concave gap penalty scoring schemeS={, w}, a function (a, b) gives the score of each aligned pair of symbolsa andb, and aconcave function w(k) gives the score of a gap of lengthk. A function w is concave if and only if it has the property that, for allk > 1, w(k + 1) –w(k) w(k) –w(k –1). In this paper we present an O(MP(logM + log2 P)) algorithm for approximate regular expression matching for an arbitrary and any concavew. This work was supported in part by the National Institute of Health under Grant RO1 LM04960.  相似文献   

5.
We investigate the periodic nature of the positive solutions of the fuzzy difference equation , where k, m are positive integers, A0, A1, are positive fuzzy numbers and the initial values xi, i = −d, −d + 1, … , −1, d = max{km}, are positive fuzzy numbers. In addition, we give conditions so that the solutions of this equation are unbounded.  相似文献   

6.
For a given sequence a=(a1,…,an) of numbers, a global rounding is an integer sequence b=(b1,…,bn) such that the rounding error |iI(aibi)| is less than one in all intervals I⊆{1,…,n}. We give a simple characterization of the set of global roundings of a. This allows to compute optimal roundings in time O(nlogn) and generate a global rounding uniformly at random in linear time under a non-degeneracy assumption and in time O(nlogn) in the general case.  相似文献   

7.
Given a sorted sequence A = a1, a2, ..., an of items from a totally ordered universe, along with an arbitrary sequence Q = q1, q2, ..., qm (1 ≤ mn) of queries, the multiple search problem involves computing for every qj (1 ≤ jm) the unique ai for which ai−1qj < ai. In this paper we propose a time-optimal algorithm to solve the multiple search problem on meshes with multiple broadcasting. More specifically, on a [formula] × [formula] mesh with multiple broadcasting, our algorithm runs in [formula] time which is shown to be time-optimal. We also present some surprising applications of the multiple search algorithm to computer graphics, image processing, robotics, and computational geometry.  相似文献   

8.
Given q+1 strings (a text t of length n and q patterns m1,…,mq) and a natural number w, the multiple serial episode matching problem consists in finding the number of size w windows of text t which contain patterns m1,…,mq as subsequences, i.e., for each mi, if mi=p1,…,pk, the letters p1,…,pk occur in the window, in the same order as in mi, but not necessarily consecutively (they may be interleaved with other letters). Our main contribution here is an algorithm solving this problem on-line in time O(nq) with an MP-RAM model (which is a RAM model equipped with extra operations).  相似文献   

9.
A unit cube in k-dimension (or a k-cube) is defined as the Cartesian product R1×R2×?×Rk, where each Ri is a closed interval on the real line of the form [ai,ai+1]. The cubicity of G, denoted as cub(G), is the minimum k such that G is the intersection graph of a collection of k-cubes. Many NP-complete graph problems can be solved efficiently or have good approximation ratios in graphs of low cubicity. In most of these cases the first step is to get a low dimensional cube representation of the given graph.It is known that for a graph G, . Recently it has been shown that for a graph G, cub(G)?4(Δ+1)lnn, where n and Δ are the number of vertices and maximum degree of G, respectively. In this paper, we show that for a bipartite graph G=(AB,E) with |A|=n1, |B|=n2, n1?n2, and Δ=min{ΔA,ΔB}, where ΔA=maxaAd(a) and ΔB=maxbBd(b), d(a) and d(b) being the degree of a and b in G, respectively, cub(G)?2(Δ+2)⌈lnn2⌉. We also give an efficient randomized algorithm to construct the cube representation of G in 3(Δ+2)⌈lnn2⌉ dimensions. The reader may note that in general Δ can be much smaller than Δ.  相似文献   

10.
Approximation algorithms for covering/packing integer programs   总被引:1,自引:0,他引:1  
Given matrices A and B and vectors a, b, c and d, all with non-negative entries, we consider the problem of computing . We give a bicriteria-approximation algorithm that, given ε∈(0,1], finds a solution of cost O(ln(m)/ε2) times optimal, meeting the covering constraints (Ax?a) and multiplicity constraints (x?d), and satisfying Bx?(1+ε)b+β, where β is the vector of row sums βi=∑jBij. Here m denotes the number of rows of A.This gives an O(lnm)-approximation algorithm for CIP—minimum-cost covering integer programs with multiplicity constraints, i.e., the special case when there are no packing constraints Bx?b. The previous best approximation ratio has been O(ln(maxjiAij)) since 1982. CIP contains the set cover problem as a special case, so O(lnm)-approximation is the best possible unless P=NP.  相似文献   

11.
Let V be a finite set of n elements and F={X1,X2,…,Xm} a family of m subsets of V. Two sets Xi and Xj of F overlap if XiXj≠∅, Xj?Xi≠∅, and Xi?Xj≠∅. Two sets X,YF are in the same overlap class if there is a series X=X1,X2,…,Xk=Y of sets of F in which each XiXi+1 overlaps. In this note, we focus on efficiently identifying all overlap classes in time. We thus revisit the clever algorithm of Dahlhaus [E. Dahlhaus, Parallel algorithms for hierarchical clustering and applications to split decomposition and parity graph recognition, J. Algorithms 36 (2) (2000) 205-240] of which we give a clear presentation and that we simplify to make it practical and implementable in its real worst case complexity. An useful variant of Dahlhaus's approach is also explained.  相似文献   

12.
13.
Hatem M. Bahig 《Computing》2006,78(2):161-172
An addition chain for a natural number n is a sequence 1=a 0<a 1< . . . <a r =n of numbers such that for each 0<ir, a i =a j +a k for some 0≤kj<i. An improvement by a factor of 2 in the generation of all minimal (or one) addition chains is achieved by finding sufficient conditions for star steps, computing what we will call nonstar lower bound in a minimal addition and omitting the sorting step.  相似文献   

14.
P. Brucker  L. Nordmann 《Computing》1994,52(2):97-122
Thek-track assignment problem is a scheduling problem withn jobs andk machines. Each machinej has a certain operational period (track) which starts at timea j and ends at timeb j . Each jobi has a specific start times i and a specific finish timet i . A schedule is an assignment of certain jobs to machines such that the intervals [s i ,t i [assigned to the same machinej do not overlap and fit into track [a j ,b j [. We are interested in a schedule which maximizes the number of assigned jobs. AO(n k?1 k!k k+1 )-algorithm which solves this problem is presented. Furthermore it is shown that the more general problem, in which for each track only a given set of jobs can be scheduled on that track, can be solved inO(n k k!k k )-time.  相似文献   

15.
Two online algorithms for the ambulance systems   总被引:1,自引:1,他引:0       下载免费PDF全文
  相似文献   

16.
This paper proposes the concept of generalized L systems, GL systems for short, which can describe asynchronized concurrent phenomena. We have proved that the GL systems are proper extensions of the traditional L systems. We have also defined a classification of GL systems and proved a sufficient and necessary condition for the equivalence of two subclasses of GL systems: two GPD0L (a class of deterministic GL systems) systems L[m 1, m 2, …, m j ] and L[n 1, n 2, …, n k ] are equivalent, iff k = j and there exists a common divisor g of all m l and a common divisor h of all n l such that ? i: m i/g = n i/h.  相似文献   

17.
In this paper, a fully parallel method for finding some or all finite eigenvalues of a real symmetric matrix pencil (A, B) is presented, where A is a symmetric tridiagonal matrix and B is a diagonal matrix with b1 > 0 and bi ≥ 0, i = 2,3,…,n. The method is based on the homotopy continuation with rank 2 perturbation. It is shown that there are exactly m disjoint, smooth homotopy paths connecting the trivial eigenvalues to the desired eigenvalues, where m is the number of finite eigenvalues of (A, B). It is also shown that the homotopy curves are monotonic and easy to follow.  相似文献   

18.
19.
Consider a vector-valued stationary random process {Yk}−∞, from which the estimates, R0, R1, …, RN, of the covariance matrices EYkYki, i=0, 1, 1, …, N, can be made.  相似文献   

20.
The problem of scheduling resources for tasks with variable requirements over time can be stated as follows. We are given two sequences of vectors A=A 1,…,A n and R=R 1,…,R m . Sequence A represents resource availability during n time intervals, where each vector A i has q elements. Sequence R represents resource requirements of a task during m intervals, where each vector R i has q elements. We wish to find the earliest time interval i, termed latency, such that for 1≤km, 1≤jq: A i+k−1 j R k j , where A i+k−1 j and R k j are the jth elements of vectors A i+k−1 and R k , respectively. One application of this problem is I/O scheduling for multimedia presentations. The fastest known algorithm to compute the optimal solution of this problem has computation time (Amir and Farach, in Proceedings of the ACM-SIAM symposium on discrete algorithms (SODA), San Francisco, CA, pp. 212–223, 1991; Inf. Comput. 118(1):1–11, 1995). We propose a technique that approximates the optimal solution in linear time: . We evaluated the performance of our algorithm when used for multimedia I/O scheduling. Our results show that 95% of the time, our solution is within 5% of the optimal.  相似文献   

设为首页 | 免责声明 | 关于勤云 | 加入收藏

Copyright©北京勤云科技发展有限公司  京ICP备09084417号