Priority Queue

버전 1.0.2 (2.36 KB) 작성자: Andrew Woodward
A simple priority queue designed for use with 1xN matlab vectors where the comparator column can be defined during construction.
다운로드 수: 554
업데이트 2018/10/29

라이선스 보기

A simple priority queue designed for use with 1xN matlab vectors where the comparator column can be defined during construction. Utilizes a minheap to ensure quick operations even with queues of larger size (100,000 elements). The following methods are currently implemented: insert, remove, peek, size, clear, contains, elements. Insert allows for 1xN vectors where the only requirement for N is that it must be greater or equal to the comparator column defined during initialization. Remove will remove and return the first element of the queue, or any matching vectors if an input vector is given. Peek returns the first element of queue without removing. Contains returns 1 if a specified vector is found in the queue, 0 otherwise. Elements returns the full queue cell array.

인용 양식

Andrew Woodward (2026). Priority Queue (https://kr.mathworks.com/matlabcentral/fileexchange/69142-priority-queue), MATLAB Central File Exchange. 검색 날짜: .

MATLAB 릴리스 호환 정보
개발 환경: R2015b
모든 릴리스와 호환
플랫폼 호환성
Windows macOS Linux
카테고리
Help CenterMATLAB Answers에서 Linear Algebra에 대해 자세히 알아보기
버전 게시됨 릴리스 정보
1.0.2

bug fix in remove

1.0.1

fixed the bubble down operation in remove

1.0.0