androidprolog

Android and Prolog


I have built an expert system in Prolog. Is there a way I can incorporate the Prolog code into my Android application so that the application takes arguments passes them to the Prolog expert system, and the expert system returns the answer to the Android application?


Solution

  • I've done something similar to this a long time ago.

    It wasn't related to Android, but it was agnostic to that.

    I used sockets to communicate with Prolog. Prolog would read the input, do its job and return the answer. The other application (in my experience) was using C++ and OpenGL, and it worked very well.

    Using sockets in Android shouldn't be your problem. Unfortunately this was many years ago, and I don't believe I have the Prolog's source code to show you how to do it, but one option is: use sockets :)

    Good luck! (I will try to find that source code, but I don't expect to find it!)