\documentclass[a4paper, 10pt]{article}

% a nicer page-geometry than the LaTeX-default
\usepackage[hmargin=3cm, vmargin=3.5cm, top=2.5cm]{geometry}

% activate padding between two paragraphs
\setlength{\parskip}{\medskipamount}
% but don't indent the first line of a new paragraph
\setlength{\parindent}{0pt}

% good math support
\usepackage{amsmath, amsfonts, amssymb}

% UTF-8 support
\usepackage{ucs}
\usepackage[utf8x]{inputenc}


\begin{document}


{\Large\bf Description Logic vs Prolog}\\
{\small\verb|http://saml.rilspace.com/content/description-logic-vs-prolog|}


\bigskip


Pellet, the reasoning system already integrated in [http://www.bioclipse.net Bioclipse], is based on so called "Description Logics". Since I'm integrating a reasoning system of different nature, based on Prolog, for the sake of comparison, it seemed reasonable to read up on what "Description Logics" (DL) actually is, and especially how it relates to Prolog (and Logical Programming in general, though I'll use only the term "Prolog" hereafter, for brevity).

\section{What is Description Logic?} 

After reading most of the 2 first chapters of the [http://books.google.se/books?id=riSeOKw5I6sC&dq=description+logic+handbook&printsec=frontcover&source=bl&ots=T6XuXZQtcc&sig=X_ElfOANoR8m-6QFZmaS8bXCDpY&hl=sv&ei=n-nHSvIji9D5BtvQnTg&sa=X&oi=book_result&ct=result&resnum=1#v=onepage&q=&f=false Description Logic handbook], and a bunch of papers where people actually have implemented Description Logic in Prolog, I still could not formulate what DL really is in a few words. Finally I found such a summary in the intro section of [http://en.wikipedia.org/w/index.php?title=Description_logic&oldid=317067703 Wikipedia article for Description Logic].

If I'd try to summarize DL in one sentence with my own words, it would be something like "A class of knowledge representation languages for defining rules for class- and role membership of instances, using, among others, typical logical operations for value restriction in the rule definitions". (''Note that this is only my first attempt to summarize it, according to my knowledge so far, and it may well change when I learn more''). 

\section{How does Description Logic compare to PROLOG / Logic Programming?}

Prolog is not really comparable to DL. While DL is kind of a language (or a ''family'' of languages) for a specific task, Prolog is more a framework on which such languages potentially be implemented.

Prolog has some characteristics though, resulting in differences between ''typical'' prolog programs, and DL. of which the main ones will be discussed below.

\subsection{Straight-forward translation of DL statements to Prolog}
The typical way of assigning class- or role membership in Prolog, is by giving a set of clauses which all should be true for an instance (two instances for a role) supplied as a parameter, in order for the class- or role membership to apply to that/these instance(s) (This structure is called ''Horn clauses''). It is in general straight-forward to convert DL rules into Horn/Prolog clauses, since the ''horn clause'' form is just a way of structuring logical formulae.

\subsection{Open World- vs Closed World Assumption}
A more serious difference is that while Prolog works according to the ''closed world assumption'', DL works instead according to the ''open world assumption'', which basically means that the statements are supposed to be \textit{generally} true, not only ''true based on facts about the individuals currently stored in the knowledge space'' as is the case for Prolog. 

The ''open world assumption'' in DL makes it possible to handle negations much better than what is typical in Prolog. For example "backward negation" inference is possible; That is, if you have for example  $C{\rightarrow}D$, then it also holds that $\neg{D}{\rightarrow}\neg{C}$. There seems to exist ways to get around this in Prolog though, but more about that another time.

\subsection{Cyclic concept definitions}
Another notable difference is that in DL, concept definitions are always acyclic in the sense that concepts are neither defined in terms of themselves nor in terms of other concepts that indirectly refer to them. This has the benefit of making concepts \textit{expandable}. It's in other words possible to expand all compound concept definitions into a tree which in it's outer branches consists only of simple facts (unary definitions). On the other hand, this limits the expressivity of the language, making it more difficult to express for example cyclic (molecular) structures in a good way. This, AFAIS, shouldn't be taken as a "drawback" of Prolog though, since the programmer could always choose just to avoid cyclic definitions in the Prolog program, in order to enable full expandability. 

\section{Conclusion so far...}

These are the main differences I've encountered in the literature. It seems that you'll always find ways to get around the problems encountered, so the interesting thing might not be primarily what is possible in one or the other language/technique, but rather how to define the exact role of DL and Prolog respectively.

AFAIS it turns out that DL and Prolog ideally play quite complementary roles (supported by the observation that an increasing number of people try to implement DL in Prolog); ''Prolog provides with an efficient and expressively powerful execution platform, while DL provides the necessary structure to build a consistent knowledge representation language upon''.

This is my understanding so far. Feedback is highly welcome.

\end{document}
