Gain measures of controllability and observability