Opacity calculation
Skeleton for clustering algorithm