diff options
Diffstat (limited to 'src/Data/Array/Nested/Permutation.hs')
-rw-r--r-- | src/Data/Array/Nested/Permutation.hs | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/Data/Array/Nested/Permutation.hs b/src/Data/Array/Nested/Permutation.hs index 03d1640..c893dac 100644 --- a/src/Data/Array/Nested/Permutation.hs +++ b/src/Data/Array/Nested/Permutation.hs @@ -281,3 +281,12 @@ lemRankDropLen ZKX (_ `PCons` _) = error "1 <= 0" lemIndexSucc :: Proxy i -> Proxy a -> Proxy l -> Index (i + 1) (a : l) :~: Index i l lemIndexSucc _ _ _ = unsafeCoerceRefl + + +-- * Replication-transpositions + +data RepTrans f sh sh' where + RTNil :: RepTrans f sh '[] + RTUse :: SNat i -> RepTrans f sh sh' -> RepTrans f sh (Index i sh : sh') + RTRep :: f n -> RepTrans f sh sh' -> RepTrans f sh (n : sh') + |