The context operations of FcaFlint are based on Relation Algebra. Crosses in the ".cxt" format correspond to 1s in Relation Algebra. (For background on Relation Algebra with FCA see this introduction). Assuming two files "ex1.cxt" and "ex2.cxt":

Operation | Explanation |
---|---|

dual(ex1.cxt) | Objects and attributes are switched. Lattice is upside down. |

invers(ex1.cxt) | Invers context: 0s become 1s; 1s become 0s. |

union(ex1.cxt, ex2.cxt) | Union: context has 1s where one of the input contexts has a 1. |

inters(ex1.cxt, ex2.cxt) | Intersection: context has 1s where both of the input contexts have a 1. |

compos(ex1.cxt, ex2.cxt) | Relational composition. |

appos(ex1.cxt, ex2.cxt) | Apposition: ex1 on the left of ex2. |

subpos(ex1.cxt, ex2.cxt) | Subposition: ex2 underneath of ex1. |

equal(ex1.cxt, ex2.cxt) | Compares two matrices. Prints "Matrices are equal" or "Matrices are not equal". |

trans(ex1.cxt) | Transitive closure of composition. |

<ONE> | Context which contains all 1s. |

<NUL> | Context which contains all 0s. |

<DIA> | Context which contains 1s on the diagonal, 0s otherwise. |

<AID> | Context which contains 0s on the diagonal, 1s otherwise. |

Examples:

fcaflint "inters(ex1.cxt,invers((ex1.cxt))" output.cxt | |

fcaflint "inters(ex1.cxt,compos(ex1.cxt,ex2.cxt))" output.cxt | |

fcaflint "equal(ex1.cxt,(dual(dual(ex1.cxt))))" output.cxt | prints: "Matrices are equal" |

fcaflint "invers(<ONE>)" output.cxt | prints: "Result is NUL matrix" |

fcaflint file.bat output.cxt | Reads the operations from a batch file "file.bat". The operations can be formatted using any amount of white space, tabs, newlines. The file should not contain any double quotes. |

Notes:

If other file types than "cxt" are requested, FcaFlint will call FcaStone, which is expected to be in "/usr/local/bin/". If FcaStone is installed in a different location, the line $fcastonelocation = "/usr/local/bin/fcaflint" should be edited in FcaFlint.

-F | This option provides slightly more checking with respect to the compatibility of the sets of objects and attributes. Warnings are produced if the sets do not match. The reasoning behind this option is further described in the papers given in the References below. Without "-F", formal contexts are considered purely as matrices (corresponding to an "unnamed perspective"). With "-F", the names of the objects and attributes are considered as well. The full version of the named perspective as described in the papers is not yet available, but planned for future releases. |

-n | No input file: reads from STDIN instead of a file. The command-line should contain something like "format.cxt" instead of the name of the input file to indicate the type of the input data. This option is certain to work for "cxt" files, but it may not work for other file types on some operating systems or with older Perl distributions. If the input consists of more than one file, the character sequence "|!|" must be inserted between the files. The "-n" option implies "-s". |

-N | No output file: writes to STDOUT instead of a file. The command-line should contain something like "format.cxt" instead of the name of the output file to indicate the type of the output data. The "-N" option implies "-s". |

-s | Silent mode: suppresses warnings about output files being overwritten if files with such names already exist. |

- Priss, Uta. "An Introduction to using Relation Algebra with FCA". Available at http://www.upriss.org.uk/papers/relalgintro.pdf.
- Priss, Uta. "Relation Algebra Operations on Formal Contexts". In: Proceedings of the 17th International Conference on Conceptual Structures, ICCS'09, Springer Verlag. (Pdf © Springer-Verlag)
- Priss, Uta. "The FcaFlint Software for Relation Algebra Operations on FCA Contexts." In: Conceptual Structures Tool Interoperability Workshop (CS-TIW 2009), Moscow, Russia. (Pdf)

- FCA Homepage.
- Relation Algebra and FCA.
- FcaStone software.

fcastone.sourceforge.net www.upriss.org.uk