Octopus
heap_oct_m Module Reference

Data Types

type  heap_t
 

Functions/Subroutines

subroutine heap_init (heap, list, sizes)
 
subroutine heap_end (heap)
 
subroutine heap_merge (heap, merged, index_map)
 
subroutine build_minheap (heap)
 
recursive subroutine minheapify (heap, i)
 
subroutine swap (heap, i, j)
 
subroutine swap_int (a, i, j)
 
logical function is_smaller (heap, i, j)
 

Function/Subroutine Documentation

◆ heap_init()

subroutine heap_oct_m::heap_init ( class(heap_t), intent(inout)  heap,
integer(int64), dimension(:), intent(in), target  list,
integer, dimension(:), intent(in)  sizes 
)
private
Parameters
[in,out]heapthe heap type
[in]listthe list of numbers to be merged
[in]sizesthe sizes of the arrays

Definition at line 135 of file heap.F90.

◆ heap_end()

subroutine heap_oct_m::heap_end ( class(heap_t), intent(inout)  heap)
private

Definition at line 178 of file heap.F90.

◆ heap_merge()

subroutine heap_oct_m::heap_merge ( class(heap_t), intent(inout)  heap,
integer(int64), dimension(:), intent(inout)  merged,
integer, dimension(:), intent(inout), optional  index_map 
)
private
Parameters
[in,out]index_mapindex map for sorting another data array

Definition at line 189 of file heap.F90.

◆ build_minheap()

subroutine heap_oct_m::build_minheap ( class(heap_t), intent(inout)  heap)
private

Definition at line 228 of file heap.F90.

◆ minheapify()

recursive subroutine heap_oct_m::minheapify ( class(heap_t), intent(inout)  heap,
integer, intent(in)  i 
)
private

Definition at line 240 of file heap.F90.

◆ swap()

subroutine heap_oct_m::swap ( class(heap_t), intent(inout)  heap,
integer, intent(in)  i,
integer, intent(in)  j 
)
private

Definition at line 269 of file heap.F90.

◆ swap_int()

subroutine heap_oct_m::swap_int ( integer, dimension(:), intent(inout)  a,
integer, intent(in)  i,
integer, intent(in)  j 
)
private

Definition at line 280 of file heap.F90.

◆ is_smaller()

logical function heap_oct_m::is_smaller ( class(heap_t), intent(inout)  heap,
integer, intent(in)  i,
integer, intent(in)  j 
)
private

Definition at line 293 of file heap.F90.