Macaulay2 » Documentation
Packages » Tableaux :: applyPositions
next | previous | forward | backward | up | index | toc

applyPositions -- apply a function to all positions of boxes in a tableau

Description

i1 : T = skewTableau(new Partition from {6,3,2}, new Partition from {2}, toList(0..8))

             ┌───┬───┬───┬───┐
o1 =         │ 0 │ 1 │ 2 │ 3 │
     ┌───┬───┼───┼───┴───┴───┘
     │ 4 │ 5 │ 6 │            
     ├───┼───┼───┘            
     │ 7 │ 8 │                
     └───┴───┘                

o1 : SkewTableau
i2 : applyPositions(T, thePosition -> thePosition)

                     ┌───────┬───────┬───────┬───────┐
o2 =                 │ (0,2) │ (0,3) │ (0,4) │ (0,5) │
     ┌───────┬───────┼───────┼───────┴───────┴───────┘
     │ (1,0) │ (1,1) │ (1,2) │                        
     ├───────┼───────┼───────┘                        
     │ (2,0) │ (2,1) │                                
     └───────┴───────┘                                

o2 : SkewTableau
i3 : applyPositions(T, thePosition -> thePosition#1 - thePosition#0)

               ┌────┬────┬────┬────┐
o3 =           │ 2  │ 3  │ 4  │ 5  │
     ┌────┬────┼────┼────┴────┴────┘
     │ -1 │ 0  │ 1  │               
     ├────┼────┼────┘               
     │ -2 │ -1 │                    
     └────┴────┘                    

o3 : SkewTableau
i4 : applyPositions(T, thePosition -> (T_thePosition)^2)

               ┌────┬────┬────┬────┐
o4 =           │ 0  │ 1  │ 4  │ 9  │
     ┌────┬────┼────┼────┴────┴────┘
     │ 16 │ 25 │ 36 │               
     ├────┼────┼────┘               
     │ 49 │ 64 │                    
     └────┴────┘                    

o4 : SkewTableau

See also

Ways to use applyPositions:

  • applyPositions(SkewTableau,Function)

For the programmer

The object applyPositions is a method function.


The source of this document is in Tableaux/documentation.m2:828:0.