úÎ!\S}‰      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~€‚ƒ „ … † ‡ ˆ (C) 2018-18 Edward Wastell!MIT -style (see the file LICENSE)!Edward Wastell <ed@wastell.co.uk> provisionalNone &'-0QSTVi+‰ sized-gridXMagic is stole from Constraints, and I don't really understand it, but it is needed for Š‹ sized-gridA type constraint for getting SingIŒ sized-gridA singleton type for Bools sized-gridZGive a runtime representation of a type level number being less than or equal than anotherŽ sized-grid A Dict prove that m - 1 + 1 is m sized-gridAlso don't understandŠ sized-gridARuntime proof that n - m is an insance of KnownNat if n and m are ‰‹‘Œ’“ŽŠNone&'+,-0;<=>?FQSTViÉ sized-gridlAn Ordinal can only hold m different values, ususally corresponding to 0 .. m - 1. We store it here using a ”L of a type level number and use constraints to keep the required invariants.zDesprite represeting a number, Ordinal is not an instance of Num and many functions (such as negate) would only be partial sized-gridEConvert a normal integral to an ordinal. If it is outside the range ( 0or= m), Nothing is returned. sized-grid&Transform an ordinal to a given numberNone,-7;<=FQSTVi$ò sized-gridKEverything that can be uses as a Coordinate. The only required function is  and the type instance of (: the rest can be derived automatically.’This is kind * -> Constraint for ease of use later. There is some argument that it should be of kind (Nat -> *) -> Constraint and we could remove ", but that has other complications sized-grid2The maximum number of values that a Coord can take sized-gridWAs each coord represents a finite number of states, it must be isomorphic to an Ordinal sized-grid#The origin. If c is an instance of •, this should be mempty sized-grid Retrive a ” of the size sized-grid'The largest possible number expressable sized-grid2Enumerate all possible values of a coord, in orderNone,-0;<=FKSTVi' sized-grid8A coordinate with periodic boundaries, as if on a taurusNone -0<FKSTVi(z, sized-grid$A coordinate that clamps its numbers,-.,-.None,-6;<=>?FSTVi;ª= sized-grid2All Diffs of the members of the list must be equal> sized-gridMThe number of elements a coord can have. This is equal to the product of the  of each element? sized-gridApply –d to each element of a type level list. This is required as type families can't be partially applied.@ sized-gridOThe type of difference between two coords. A n-dimensional coord should have a – of an n-tuple of Integers . We use —F and our 1-tuple. Unfortuantly, each instance is manual at the moment.A sized-gridA multideminsion coordinateD sized-gridLength of a type level listF sized-gridaGet the first element of a coord. Thanks to type level information, we can write this as a total ˜G sized-gridA ˜ into the the tail of AH sized-grid-Turn a single element into a one dimensional AI sized-gridAdd a new element to a A#. This increases the dimensionalityJ sized-grid%Generate all possible coords in orderK sized-grid Convert a A to its position in a vectorL sized-gridECalculate the Moore neighbourhood around a point. Includes the centerM sized-gridJCalculate the von Neuman neighbourhood around a point. Includes the centerN sized-grid$Swap x and y for a coord in 2D space=>?@ABCDEFGHIJKLMNDABCEFGHI@?J>K=LMNNone-345<>?FKSTViHÉ_ sized-grid2A Constraint that all grid sizes are instances of KnownNat` sized-gridGiven a grid type, give back a series of nested lists repesenting the grid. The lists will have a number of layers equal to the dimensionality.a sized-grid/All but the first elements of a type level listb sized-grid&The first element of a type level listc sized-gridA multi dimensional sized gridf sized-grid Convert a vector into a list of Vector:s, where all the elements of the list have the given size.g sized-grid~Convert a grid to a series of nested lists. This removes type level information, but it is sometimes easier to work with listsh sized-gridrConvert a series of nested lists to a grid. If the size of the grid does not match the size of lists this will be ™ _`abcdefghi cdeba`_fghiNone 345;<=>?KM]z sized-grid Similar to c], but this has a focus on a certain square. Becuase of this we loose some instances, such as š, but we gain a › and œR instance. We can convert between a focused and unfocused list using facilites in IsGridz{}|z{}| None ;<=>?AQVR#ƒ sized-gridConversion between c and z and access grids at a A„ sized-gridPGet the element at a grid location. This is a lens because we know it must exist… sized-grid&Convert to, or run a function over, a c† sized-grid&Convert to, or run a function over, a zƒ†…„ƒ†…„NoneRy;,-.=>?@ABCDEFGHIJKLMN_`abcdefghiz{|}ƒ„…†      !"#$%&'(()*+,-./01234567889:;<=>?@ABCDEFGHIJKLLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmmnopqrstuvwxyz{|}~€‚ƒƒ„…†‡ˆ‰Š ‹ Œ Ž ‘ ’ “ ” • – — ‘ ˜ ™ š›œ›žŸ ¡¢›£¤¥¦§›ž¨›ž©ª«¬ª­®¯)sized-grid-0.1.1.1-BHFvK1jw3JbEzyOcmzXWd5 SizedGridSizedGrid.OrdinalSizedGrid.Coord.ClassSizedGrid.Coord.PeriodicSizedGrid.Coord.HardWrapSizedGrid.CoordSizedGrid.Grid.GridSizedGrid.Grid.FocusedSizedGrid.Grid.ClassSizedGrid.Internal.Type+generics-sop-0.3.2.0-5JX38dNigUk7e65oSELmomGenerics.SOP.ConstraintAllComposeGenerics.SOP.SingSListIGenerics.SOP.BasicFunctorsIOrdinal numToOrdinal ordinalToNum$fFromJSONKeyOrdinal$fToJSONKeyOrdinal$fFromJSONOrdinal$fToJSONOrdinal $fEnumOrdinal$fBoundedOrdinal$fRandomOrdinal $fOrdOrdinal $fEqOrdinal $fShowOrdinalIsCoord CoordSized asOrdinal zeroPosition sCoordSized maxCoordSize allCoordLike$fIsCoordOrdinalPeriodic unPeriodic$fAffineSpacePeriodic$fAdditiveGroupPeriodic$fMonoidPeriodic$fSemigroupPeriodic$fIsCoordPeriodic$fEnumPeriodic $fEqPeriodic$fShowPeriodic $fOrdPeriodic$fFromJSONKeyPeriodic$fFromJSONPeriodic$fToJSONKeyPeriodic$fToJSONPeriodic$fRandomPeriodicHardWrap unHardWrap$fAffineSpaceHardWrap$fMonoidHardWrap$fSemigroupHardWrap$fIsCoordHardWrap $fEqHardWrap$fShowHardWrap $fOrdHardWrap$fFromJSONKeyHardWrap$fToJSONKeyHardWrap$fFromJSONHardWrap$fToJSONHardWrap$fBoundedHardWrap$fEnumHardWrap$fRandomHardWrap AllDiffSame MaxCoordSizeMapDiff CoordDiffCoordunCoordLength _WrappedCoord coordHead coordTail singleCoord appendCoordallCoord coordPosition moorePointsvonNeumanPoints tranposeCoord$fField5CoordCoordee'$fField4CoordCoorddd'$fField3CoordCoordcc'$fField2CoordCoordbb'$fField1CoordCoordaa' $fRandomCoord$fAdditiveGroupCoord $fMonoidCoord$fSemigroupCoord$fFromJSONCoord $fToJSONCoord $fShowCoord $fOrdCoord $fEqCoord$fAffineSpaceCoord$fGenericCoordAllGridSizeKnown CollapseGridTailHeadGridunGridsplitVectorBySize collapseGrid gridFromList transposeGrid$fTraversableWithIndexCoordGrid$fFoldableWithIndexCoordGrid$fFunctorWithIndexCoordGrid$fRepresentableGrid$fDistributiveGrid $fMonadGrid$fApplicativeGrid$fFromJSONGrid $fToJSONGrid$fEqGrid $fShowGrid $fFunctorGrid$fFoldableGrid$fTraversableGrid $fEq1Grid $fShow1Grid FocusedGrid focusedGridfocusedGridPosition$fComonadStoreCoordFocusedGrid$fComonadFocusedGrid$fFunctorFocusedGrid$fFoldableFocusedGrid$fTraversableFocusedGridIsGrid gridIndexasGrid asFocusedGrid$fIsGridcsFocusedGrid$fIsGridcsGridMagictakeNatSBoolISBool sLessThan takeAddIsIdmagicsBoolSFalseSTruebase Data.ProxyProxyGHC.BaseMonoid(vector-space-0.13-LnwRQB1SPrcFwEOnl9b9pXData.AffineSpaceDiffData.Functor.IdentityIdentity"lens-4.16.1-1DnEcnkEZUR2WJnw5aYOpzControl.Lens.TypeLensNothing Applicative$comonad-5.0.4-6hD6ILy3BZ8K91c2FGjjxTControl.ComonadComonadControl.Comonad.Store.Class ComonadStore