How can Android be utilized in computational science pipelines?

For example, if one wanted to produce a visualization for an Android mobile device. Similarly to how people are using browsers and JS to do visualizations and interactive apps even.

I'm thinking that support for numerical codes in Java is poor compared to C/C++, which would make me think that a way to utilize C/C++ code would be to run these in a server and just poll results for displaying on a Kotlin app or something. But is this all there is to this?

  • 2
    $\begingroup$ Android is just an operating system (in fact, it is a variation of Linux). You can run programs written in any programming language on it. What makes you think that Android is different than any other operating system (Linux, Mac, Windows)? $\endgroup$ Aug 15, 2022 at 14:59
  • $\begingroup$ @WolfgangBangerth Because for GUI one must use Java/Kotlin, which is not a predominant combo for numerical computations: scicomp.stackexchange.com/a/41618/17316. Thus the question is, how are these utilized for Android? Which is also the title of the question rephrased. Further one can see plenty of GIS apps etc. use browsers and JS, not C++ (GDAL, PDAL, ...) or something. Although, looking at GDAL may hint that JNI is still the way: trac.osgeo.org/gdal/wiki/BuildingForAndroid. But I was interested in other approaches such as polling servers or clusters for data. $\endgroup$
    – mavavilj
    Aug 15, 2022 at 15:06
  • 1
    $\begingroup$ To which the answer may be "separate visualization and computation, and use web sockets". $\endgroup$
    – mavavilj
    Aug 15, 2022 at 17:49
  • $\begingroup$ Yes, or cross-language function calls, or any other way for different languages to communicate. $\endgroup$ Aug 15, 2022 at 20:40
  • $\begingroup$ @WolfgangBangerth Yes, but what are some standard practices? Is it always just JNI? What else is out there for e.g. R or Fortran? What about parallel computing? What about write once, run everywhere? $\endgroup$
    – mavavilj
    Aug 16, 2022 at 10:28


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.