I have a problem like this with my cat Corkscrew. When I go out of town he's fine and uses his litter box, and he's not alone or anything because my roommate and I plan our trips home so that one of us is always here. But the second I walk in the door he runs to the bathroom and poops right outside the litterbox. It drives me nuts, but now I've come to expect when whenever I get back into town.