I am sorry if I expressed myself a bit clumsyly. Your last statement is exactly what I want:
"What you real want is an algorithm to evenly encircle any pattern of tiles on a grid, partial or full."
P.S.: I know about the links but I had a strange error "permission denied" and I found a post in here that sourced this to the usage of links ... So I removed them ;)