Townhouses don't offer a lot of space, yard wise. However, that doesn't mean you can't take advantage of the little patio or small patch or grass you have. Landscaping the back yard of a townhouse is just like any other small space landscaping. Keep everything in proportion and you can do almost as much as you could with a full back yard.
With only a small space, you can have a Zen area in which to chill out and relax. Buy some simply shaped containers to fill with bamboo and maybe an ornamental Asian fruit tree, such as a small flowering cherry or a Japanese persimmon tree. If you don't want grass, you can set out rocks or sand, for Zen mediation, and plant suitable plants among them.
If you like water but don't have room for a pool, consider a small pond. Fill it with fish and lily pads and surround it with cattails and marsh mallow or water-loving irises, like sweet flag, and you have a water garden to enjoy on the hot days of summer. If you don't have room for a pond in the ground, make a raised pond or container water garden. Add a waterfall for movement and aeration.
If you like function over form, grow a small vegetable garden in your townhouse back yard. Many vegetables grow well in containers, like tomatoes and peppers, and you can have a whole container filled to the brim with herbs. Not only is it beautiful, but you will be able to eat it all as well.
Even with such a small space you can have an English garden. Grow English ivy on a trellis against the townhouse and plant traditional English garden plants, like lavender and hollyhocks, along a fence or wall. Put up a wooden fence to keep it all in place.