   "Inverts context ctx, that is $(G,M,I)$ gets $(G,M,(G\\times M)\\setminus I)$."
   [ctx]
   (make-context-nc (objects ctx) (attributes ctx) (set-of [g m] [g (objects ctx)
-								 m (attributes ctx)
-								 :when (not ((incidence ctx) [g m]))])))
+                                                                 m (attributes ctx)
+                                                                 :when (not ((incidence ctx) [g m]))])))
 
 (defn context-union
   "Returns context union of ctx1 and ctx2."
   [ctx1 ctx2]
   (let [new-objs (union (set-of [g_1 1] [g_1 (objects ctx1)])
-			(set-of [g_2 2] [g_2 (objects ctx2)]))
-	new-atts (union (set-of [m_1 1] [m_1 (attributes ctx1)])
-			(set-of [m_2 2] [m_2 (attributes ctx2)]))
-	new-inz  (set-of [[g idx-g] [m idx-m]]
-			 [[g idx-g] new-objs
-			  [m idx-m] new-atts
-			  :when (or ((incidence ctx1) [g m])
-				    ((incidence ctx2) [g m]))])]
+                        (set-of [g_2 2] [g_2 (objects ctx2)]))
+        new-atts (union (set-of [m_1 1] [m_1 (attributes ctx1)])
+                        (set-of [m_2 2] [m_2 (attributes ctx2)]))
+        new-inz  (set-of [[g idx-g] [m idx-m]]
+                         [[g idx-g] new-objs
+                          [m idx-m] new-atts
+                          :when (or ((incidence ctx1) [g m])
+                                    ((incidence ctx2) [g m]))])]
     (make-context-nc new-objs new-atts new-inz)))
 
 (defn context-intersection
   "Returns context intersection of ctx1 and ctx2."
   [ctx1 ctx2]
   (make-context-nc (intersection (objects ctx1) (objects ctx2))
-		   (intersection (attributes ctx1) (attributes ctx2))
-		   (intersection (incidence ctx1) (incidence ctx2))))
+                   (intersection (attributes ctx1) (attributes ctx2))
+                   (intersection (incidence ctx1) (incidence ctx2))))
 
 (defn context-composition
   "Returns context composition of ctx-1 and ctx-2, that is

  "Reduces context ctx assuming it is clarified."
  [ctx]
  (let [uda     (up-down-arrows ctx),
	new-obj (set (map first uda)),
	new-att (set (map second uda))]
    (make-context-nc new-obj new-att (incidence ctx))))

(defn reduce-context-objects

  [ctx order-on-objects order-on-attributes]
  (let [str #(if (= % nil) "nil" (str %))

        attributes (vec (sort order-on-objects (attributes ctx)))
        objects    (vec (sort order-on-attributes (objects ctx)))
        incidence  (incidence ctx)

        max-att (reduce #(max %1 (count (str %2))) 0 attributes)
        max-obj (reduce #(max %1 (count (str %2))) 0 objects)]
    (with-str-out
      (ensure-length "" max-obj " ") " |" (for [att attributes]
                                            [(print-str att) " "]) "\n"
      (ensure-length "" max-obj "-") "-+" (for [att attributes]
                                            (ensure-length "" (inc (count (print-str att))) "-")) "\n"
      (for [obj objects]
        [(ensure-length (print-str obj) max-obj)
         " |"
         (for [att attributes]
           [(ensure-length (if (incidence [obj att]) "x" ".")
                           (count (print-str att)))
            " "])
         "\n"]))))

(defmethod print-method Formal-Context [ctx out]
  (.write ^java.io.Writer out
