# Synopse

Diamond structuring element and elementary 3x3 cross.

• B = iasecross(r=1)
• B: Structuring Element
```01. from numpy import *
02.
03. def iasecross(r=1):
04.     from iasesum import iasesum
05.     from iabinary import iabinary
06.
07.     B = iasesum( iabinary([[0,1,0],
08.                            [1,1,1],
09.                            [0,1,0]]),r)
10.     return B```

# Description

iasecross creates the structuring element B formed by r successive Minkowski additions of the elementary cross (i.e., the 3x3 cross centered at the origin) with itself. If r=0, B is the unitary set that contains the origin. If r=1, B is the elementary cross itself.

# Examples

## Example 1

```1. from ia870 import iasecross, iaseshow
2.
3. b1 = iasecross()
4. print iaseshow(b1)
5. b2 = iasecross(2)
6. print iaseshow(b2)```
```[[False  True False]
[ True  True  True]
[False  True False]]
[[False False  True False False]
[False  True  True  True False]
[ True  True  True  True  True]
[False  True  True  True False]
[False False  True False False]]
```