Update function get_CA( )

The updated version is more than 30 times faster than the old one (~90s
for the test community vs. ~2900s using the old code).