improved the right axes layout math