\begin{algorithm}
        \caption{D-ary Heap}
        \begin{algorithmic}
        \STATE \COMMENT{calculate the parent index of $i$}
        \PROCEDURE{D-Parent}{$i$}
            \RETURN $\lfloor (i - 2) / d + 1\rfloor$
        \ENDPROCEDURE
        \STATE
        \STATE \COMMENT{calculate the kth child of node of index $i$}
        \PROCEDURE{D-Child}{$i, k$}
            \RETURN $d * (i - 1) + k + 1$
        \ENDPROCEDURE
        \end{algorithmic}
        \end{algorithm}