# [−][src]Crate bonsai

Implements various index arithmetic for perfect binary trees.

## Functions

expand_tree_index | Return a node's family. |

general_index_to_subtree | Translate the general index |

is_in_subtree | Determine if |

last_power_of_two | Return the last power of two for |

left_most_leaf | Return the first leaf of a tree described by |

log_base_two | Return the log of |

next_power_of_two | Return the next power of two for |

relative_depth | Return the depth between two general indicies. |

right_most_leaf | Return the last leaf of a tree described by |

root_from_depth | Return the subtree root for |

sibling_index | Return the index of a node's sibling. |

subtree_index_to_general | Translate the subtree index |