• 제목/요약/키워드: Merge sort

검색결과 18건 처리시간 0.019초

매개변수 환경설정에 따른 타조의 외부합병정렬 성능 연구 (External Merge Sorting in Tajo with Variable Server Configuration)

  • 이종백;강운학;이상원
    • 정보과학회 논문지
    • /
    • 제43권7호
    • /
    • pp.820-826
    • /
    • 2016
  • 거대한 데이터로부터 가치 있는 정보를 추출해 내는 빅데이터 기술의 필요성은 나날이 커지고 있다. 빅데이터 분석을 위해 사용되는 하둡 시스템은 맵리듀스를 통해 데이터를 처리하였으나, 맵리듀스 프레임워크는 코드 재사용성의 한계, 질의 최적화 기술의 부재 등의 단점을 보인다. 이를 극복하기 위해 SQL-on-Hadoop이라 불리는 하둡 기반의 SQL 질의 처리 기술이 주목받고 있다. SQL-on-Hadoop 기술 중 타조(Tajo)는 국내 개발진이 주축이 되어 개발되었다. 타조는 데이터 분석을 위해 외부합병정렬 알고리즘을 사용하며, 정렬 연산에 영향을 주는 매개변수로 정렬 버퍼 사이즈와 팬-아웃을 가진다. 본 논문은 타조의 정렬 연산에 영향을 미치는 매개변수인 정렬 버퍼 사이즈와 팬-아웃 값에 따른 정렬의 성능 차이를 보인다. 또한 측정한 성능에 대하여 정렬 버퍼 사이즈가 증가함에 따른 CPU 캐시 미스의 비율 증가, 팬-아웃에 따른 합병 단계 수의 변화가 성능 차이의 원인임을 보인다.

Analysis and Comparison of Sorting Algorithms (Insertion, Merge, and Heap) Using Java

  • Khaznah, Alhajri;Wala, Alsinan;Sahar, Almuhaishi;Fatimah, Alhmood;Narjis, AlJumaia;Azza., A.A
    • International Journal of Computer Science & Network Security
    • /
    • 제22권12호
    • /
    • pp.197-204
    • /
    • 2022
  • Sorting is an important data structure in many applications in the real world. Several sorting algorithms are currently in use for searching and other operations. Sorting algorithms rearrange the elements of an array or list based on the elements' comparison operators. The comparison operator is used in the accurate data structure to establish the new order of elements. This report analyzes and compares the time complexity and running time theoretically and experimentally of insertion, merge, and heap sort algorithms. Java language is used by the NetBeans tool to implement the code of the algorithms. The results show that when dealing with sorted elements, insertion sort has a faster running time than merge and heap algorithms. When it comes to dealing with a large number of elements, it is better to use the merge sort. For the number of comparisons for each algorithm, the insertion sort has the highest number of comparisons.

데이터베이스에서의 시간 시스템에 관한 연구 (A study of Time Management System in Data Base)

  • 최진탁
    • 산업경영시스템학회지
    • /
    • 제21권48호
    • /
    • pp.185-192
    • /
    • 1998
  • A new algorithm is proposed in this paper which efficiently performs join in the temporal database. The main idea is to sort the smaller relation and to partition the larger relation, and the proposed algorithm reduces the cost of sorting the larger relation. To show the usefulness of the algorithm, the cost is analyzed with respect to the number of accesses to secondary storage and compared with that of Sort-Merge algorithm. Through the comparisons, we present and verify the conditions under which the proposed algorithm always outperforms the Sort-Merge algorithm. The comparisons show that the proposed algorithm achieves 10∼30% gain under those conditions.

  • PDF

Parallel FFT and Quick-Merge Sort on the Reflective Memory Networked Computers and a Cluster of Work-stations

  • Lee, Changhun;Kwon, Wook-Hyun
    • 제어로봇시스템학회:학술대회논문집
    • /
    • 제어로봇시스템학회 2002년도 ICCAS
    • /
    • pp.94.1-94
    • /
    • 2002
  • This paper is concerned with parallel FFT and Quick-Merge Sort. They are implemented on computers interconnected by VMIC 5579 reflective memory and a cluster of workstations (PCs) interconnected via Fast Ethernet. Message passing interface (MPI) parallel library is used for communication in a cluster of workstations. An improved parallel FFT is also presented to decrease an execution time in the case of a small number of hosts. Distributed shared memory (DSM), VMIC 5579 reflective memory (RM), a cluster of workstations (COW) and message passing interface (MPI) parallel library are described.

  • PDF

X-Hypercubes의 연결성과 그 응용 (Conncetiveity of X-Hypercubes and Its Applications)

  • 권경희
    • 한국정보처리학회논문지
    • /
    • 제1권1호
    • /
    • pp.92-98
    • /
    • 1994
  • Hypercubes와 유사한 구조를 가진 X-hypercubes는 hypercubes와 같은수의 node와 edge를 갖고 있다.그러나 node들을 연결한는 방법을 약간 바꾸어 줌으로써 X-hypercubes내의 node들간의 통신시의 delay는 hypercubes 의 그것보다 훨씬 적어지는 것을 기대할 수 있다. 본 논문에서는 X-hypercubes를 새롭게 정의함으로써 두 node들 간의 연결에 관한 조건들을 명확히 해준다.이 정의에 대한 응용으로서,본 논문은 hypercubes 를 X-hypercubes로 그리고 X-hypercubes 를 hypercubes로 embedding시키는 algorthm을 보여준다.이는 이들 두 network에서 운용되는 program 들이 최소한 overhead만으로써 서로 호완될 수 있음을 말해준다.또한 본 논문은 hypercubes 에서의 bitionic merge sort를 simulate함으로써,X-hypercubes에서 운용될 수 있는 bitonic merge sort도 보여주고 있다.

  • PDF

A Fast Sorting Strategy Based on a Two-way Merge Sort for Balancing the Capacitor Voltages in Modular Multilevel Converters

  • Zhao, Fangzhou;Xiao, Guochun;Liu, Min;Yang, Daoshu
    • Journal of Power Electronics
    • /
    • 제17권2호
    • /
    • pp.346-357
    • /
    • 2017
  • The Modular Multilevel Converter (MMC) is particularly attractive for medium and high power applications such as High-Voltage Direct Current (HVDC) systems. In order to reach a high voltage, the number of cascaded submodules (SMs) is generally very large. Thus, in the applications with hundreds or even thousands of SMs such as MMC-HVDCs, the sorting algorithm of the conventional voltage balancing strategy is extremely slow. This complicates the controller design and increases the hardware cost tremendously. This paper presents a Two-Way Merge Sort (TWMS) strategy based on the prediction of the capacitor voltages under ideal conditions. It also proposes an innovative Insertion Sort Correction for the TWMS (ISC-TWMS) to solve issues in practical engineering under non-ideal conditions. The proposed sorting methods are combined with the features of the MMC-HVDC control strategy, which significantly accelerates the sorting process and reduces the implementation efforts. In comparison with the commonly used quicksort algorithm, it saves at least two-thirds of the sorting execution time in one arm with 100 SMs, and saves more with a higher number of SMs. A 501-level MMC-HVDC simulation model in PSCAD/EMTDC has been built to verify the validity of the proposed strategies. The fast speed and high efficiency of the algorithms are demonstrated by experiments with a DSP controller (TMS320F28335).

유전 알고리즘을 이용한 정렬 알고리즘의 최악의 인스턴스 탐색 (Finding the Worst-case Instances of Some Sorting Algorithms Using Genetic Algorithms)

  • 전소영;김용혁
    • 한국정보과학회:학술대회논문집
    • /
    • 한국정보과학회 2010년도 한국컴퓨터종합학술대회논문집 Vol.37 No.1(B)
    • /
    • pp.1-5
    • /
    • 2010
  • 정렬 알고리즘에서 사용한 원소 간 비교횟수를 기준으로, 비교횟수가 많게 되는 순열을 최악의 인스턴스(worst-case instance)라 명명하고 이를 찾기 위해 유전 알고리즘(genetic algorithm)을 사용하였다. 잘 알려진 퀵 정렬(quick sort), 머지 정렬(merge sort), 힙 정렬(heap sort), 삽입 정렬(insertion sort), 쉘 정렬(shell sort), 개선된 퀵 정렬(advanced quick sort)에 대해서 실험하였다. 머지 정렬과 삽입 정렬에 대해 탐색한 인스턴스는 최악의 인스턴스에 거의 근접하였다. 퀵 정렬은 크기가 증가함에 따라 최악의 인스턴스 탐색이 어려웠다. 나머지 정렬에 대해서 찾은 인스턴스는 최악의 인스턴스인지 이론적으로 보장할 수 없지만, 임의의 1,000개 순열을 정렬해서 얻은 비교횟수들의 평균치보다는 훨씬 높았다. 본 논문의 최악의 인스턴스를 탐색하는 시도는 알고리즘의 성능 검증을 위한 테스트 데이터를 생성한다는 점에서 의미가 크다.

  • PDF

A New Method for Efficient in-Place Merging

  • Kim, Pok-Son;Arne Kutzner
    • 한국지능시스템학회:학술대회논문집
    • /
    • 한국퍼지및지능시스템학회 2003년도 ISIS 2003
    • /
    • pp.392-394
    • /
    • 2003
  • There is a well-known simple, stable standard merge algorithm, which uses only linear time but for the price of double space. This extra space consumption has been often remarked as lack of the standard merge sort algorithm that covers a merge process as central operation. In-place merging is a way to overcome this lack and so is a topic with a long tradition of inspection in the area of theoretical computer science. We present an in-place merging algorithm that rear-ranges the elements to be merged by rotation, a special form of block interchanging. Our algorithm is novel, due to its technique of determination of the rotation-areas. Further it has a short and transparent definition. We will give a presentation of our algorithm and prove that it needs in the worst case not more than twice as much comparisons as the standard merge algorithm. Experimental work has shown that our algorithm is efficient and so might be of high practical interest.

  • PDF

GPGPU 기반 조인 연산 병렬화 성능 비교 (Performance Comparison of Join Operations Parallelization by using GPGPU)

  • 이종섭;이상백;이규철
    • 데이타베이스연구회지:데이타베이스연구
    • /
    • 제34권3호
    • /
    • pp.28-44
    • /
    • 2018
  • 데이터베이스 시스템 관계 연산자 중에서 연산 비용이 가장 비싼 연산은 조인 연산이다. 일반적으로 CPU 기반의 조인 연산의 경우에는 하나의 코어를 사용하거나 많게는 16개 정도의 코어를 사용하여 병렬 처리를 해서 병렬화에 따른 성능 향상이 크지 않다. 이에 반해, GPGPU(General-Purpose computing on Graphics Processing Units)는 수천 개의 프로세싱 유닛을 통한 병렬 처리가 가능해서 조인 연산 수행 시간을 크게 단축할 수 있다. 본 논문에서는 GPGPU 기반에서 조인 연산 병렬화를 구현하기 위해 NVIDIA의 CUDA SDK가 사용되며, CPU 기반과 GPGPU 기반에서의 조인 연산 성능을 측정한다. 사용되는 조인 연산은 NLJ (Nested Loop Join), SMJ (Merge Join), HJ (Hash Join)이며, GPGPU 장비는 TITAN Xp, GTX 1080 Ti 및 GTX 1080을 사용한다. CPU 기반과 GPGPU 기반의 성능을 비교하고, GPGPU 기반의 조인 연산과 이전 연구의 성능과의 성능을 비교한다. 마지막으로, 실험 결과는 GPGPU 기반의 성능이 CPU 기반의 성능보다 6~328 배 빠른 성능을 보였고 향후 연구의 방향성에 대하여 토의한다.

ETL상에서 파일 시스템을 이용한 대용량 데이터 처리 기법 (Processing Large Date Using File System On ETL)

  • 정윤철
    • 한국정보과학회:학술대회논문집
    • /
    • 한국정보과학회 2008년도 한국컴퓨터종합학술대회논문집 Vol.35 No.1 (C)
    • /
    • pp.127-131
    • /
    • 2008
  • 관계형 DBMS의 보급이 확대되면서 대형 운영시스템 구축 시에 인덱스를 사용하는 관계형 DB의 사용이 증가하고 있다. 이에 따라 Sort의 용도가 대폭 축소되고 DB에서 직접 대형 결산작업이 주로 처리되게 되었다. 그러나 대형 결산 작업 처리시 사용되는 대용량의 데이터의 경우 ETL(Extract Transformation Loading) 작업 시에는 오히려 파일 시스템을 사용하는 경우보다 성능이 저하되는 문제가 발생하기 시작했다. 본 논문에서는 ETL 작업 시 DBMS에 존재하는 대용량 데이터 처리하는 경우에 파일 시스템 상에서 flat 파일을 이용하여 처리 속도를 향상 시키고, 이와 동시에 리소스부하 문제를 해결할 수 있는 방안을 제시했다. 보다 세부적으로 DBMS에서 사용되는 sort, Join, Merge, Summary, 각종 사용자 함수 등의 다양한 기능들을 flat 파일에 적용하는 방법을 제시하였다. 또한 실험을 통해 ETL 작업 시 제안하는 기법이 처리 속도 개선과 리소스 활용성을 향상 시킴을 증명하였다.

  • PDF