Documentation

Std.Data.DTreeMap.Internal.Balanced

Balanced predicate #

This file defines what it means for a tree map to be balanced. This definition is encoded in the Balanced predicate.

Predicate for local balance at a node of the tree. We don't provide API for this, preferring instead to use automation to dispatch goals about balance.

Equations
Instances For
    inductive Std.DTreeMap.Internal.Impl.Balanced {α : Type u} {β : αType v} :
    Impl α βProp

    Predicate that states that the stored size information in a tree is correct and that it is balanced.

    Instances For
      theorem Std.DTreeMap.Internal.Impl.balanced_inner_iff {α : Type u} {β : αType v} {sz : Nat} {k : α} {v : β k} {l r : Impl α β} :
      theorem Std.DTreeMap.Internal.Impl.balanced_one_leaf_leaf {α : Type u} {β : αType v} {k : α} {v : β k} :
      theorem Std.DTreeMap.Internal.Impl.Balanced.one_le {α : Type u} {β : αType v} {sz : Nat} {k : α} {v : β k} {l r : Impl α β} (h : (Impl.inner sz k v l r).Balanced) :
      1 sz
      theorem Std.DTreeMap.Internal.Impl.Balanced.eq {α : Type u} {β : αType v} {sz : Nat} {k : α} {v : β k} {l r : Impl α β} :
      (Impl.inner sz k v l r).Balancedsz = l.size + 1 + r.size
      theorem Std.DTreeMap.Internal.Impl.Balanced.left {α : Type u} {β : αType v} {sz : Nat} {k : α} {v : β k} {l r : Impl α β} :
      (Impl.inner sz k v l r).Balancedl.Balanced
      theorem Std.DTreeMap.Internal.Impl.Balanced.right {α : Type u} {β : αType v} {sz : Nat} {k : α} {v : β k} {l r : Impl α β} :
      (Impl.inner sz k v l r).Balancedr.Balanced
      theorem Std.DTreeMap.Internal.Impl.Balanced.at_root {α : Type u} {β : αType v} {sz : Nat} {k : α} {v : β k} {l r : Impl α β} :