         return (floor((R + m)*255)*1000000)+(floor((G + m)*255)*1000)+floor((B + m)*255)
     }
     
-    fileprivate func isContrasting(_ color: Double) -> Bool {
+    func isContrasting(_ color: Double) -> Bool {
         let bgLum = (0.2126*r)+(0.7152*g)+(0.0722*b)+12.75
         let fgLum = (0.2126*color.r)+(0.7152*color.g)+(0.0722*color.b)+12.75
         if bgLum > fgLum {

        return fmod(self,1000)
    }
    
    fileprivate var isDarkColor: Bool {
        return (r*0.2126) + (g*0.7152) + (b*0.0722) < 127.5
    }
    
    fileprivate var isBlackOrWhite: Bool {
        return (r > 232 && g > 232 && b > 232) || (r < 23 && g < 23 && b < 23)
    }
    
    fileprivate func isDistinct(_ other: Double) -> Bool {
        let _r = self.r
        let _g = self.g
        let _b = self.b

        }
    }
    
    var uicolor: UIColor {
        return UIColor(red: CGFloat(r)/255, green: CGFloat(g)/255, blue: CGFloat(b)/255, alpha: 1)
    }
    
    var pretty: String {
        return "\(Int(self.r)), \(Int(self.g)), \(Int(self.b))"
    }
}
