Documentation

Projects.Sokoban.Card

theorem Sokoban.point_eq_of_fin {s : State} [hs : s.WF] {p : PointZ} (h : p s.grid) :
p = { x := p.x.toFin, y := p.y.toFin }
theorem Sokoban.x_toFin_width_eq_iff' {s : State} [hs : s.WF] {p₁ p₂ : PointZ} (h₁ : p₁ s.grid) (h₂ : p₂ s.grid) :
p₁.x.toFin = p₂.x.toFin p₁.x = p₂.x
theorem Sokoban.y_toFin_width_eq_iff' {s : State} [hs : s.WF] {p₁ p₂ : PointZ} (h₁ : p₁ s.grid) (h₂ : p₂ s.grid) :
p₁.y.toFin = p₂.y.toFin p₁.y = p₂.y
theorem Sokoban.x_toFin_width_eq_iff {n : } [hn : NeZero n] {s₁ s₂ : State} [hs₁ : s₁.WF] [hs₂ : s₂.WF] {p₁ p₂ : PointZ} (hw₁ : s₁.width = n) (hw₂ : s₂.width = n) (h₁ : p₁ s₁.grid) (h₂ : p₂ s₂.grid) :
p₁.x.toFin = p₂.x.toFin p₁.x = p₂.x
theorem Sokoban.y_toFin_width_eq_iff {n : } [hn : NeZero n] {s₁ s₂ : State} [hs₁ : s₁.WF] [hs₂ : s₂.WF] {p₁ p₂ : PointZ} (hw₁ : s₁.height = n) (hw₂ : s₂.height = n) (h₁ : p₁ s₁.grid) (h₂ : p₂ s₂.grid) :
p₁.y.toFin = p₂.y.toFin p₁.y = p₂.y
structure Sokoban.Card.FinState (w h : ) [NeZero w] [NeZero h] :
Instances For
    @[instance_reducible]
    instance Sokoban.Card.instFintypeFinState {w✝ h✝ : } {inst✝ : NeZero w✝} {inst✝¹ : NeZero h✝} :
    Fintype (FinState w✝ h✝)
    Equations
    def Sokoban.Card.fn (s₀ : State) [hs : s₀.WF] (s : State) :
    Equations
    Instances For
      theorem Sokoban.nonneg_x_of_get {s : State} {x y : } {d : Tile} [hs : s.WF] [h : s.Get { x := x, y := y } d] :
      0 x
      theorem Sokoban.nonneg_y_of_get {s : State} {x y : } {d : Tile} [hs : s.WF] [h : s.Get { x := x, y := y } d] :
      0 y
      theorem Sokoban.x_lt_width_of_get {s : State} {x y : } {d : Tile} [hs : s.WF] [h : s.Get { x := x, y := y } d] :
      x < s.width
      theorem Sokoban.y_lt_height_of_get {s : State} {x y : } {d : Tile} [hs : s.WF] [h : s.Get { x := x, y := y } d] :
      y < s.height
      theorem Sokoban.toFin_eq_of_get? {s s' : State} {p : PointZ} {d : Tile} [hs : s.WF] [hs' : s'.WF] (h₁ : sys.Reachable s s') (h₂ : Map.get? p s'.grid = some d) :
      { x := p.x.toFin, y := p.y.toFin } = p