Bridging the Closed and Open
How FoxySheep Can Benefit Both Proprietary and Open Technologies for Teaching and Research
Robert Jacobson
rjacobson@rwu.edu
Roger Williams University
JMM 2016
January 7, 2016
Bridging the Closed and Open
How FoxySheep Can Benefit Both Proprietary and Open Technologies for Teaching and Research
http://slides.com/robertjacobson/jmm2016/live
http://slides.com/robertjacobson/jmm2016/live
Follow along on your own device by visiting
Follow along on your own device by visiting
This talk...
- ...an excuse to analyze our current rapid progress in mathematical (research and education) software.
- ...an excuse to share my philosophical ideas about what we should value and prioritize.
- ...an excuse to show off a project I have been working on: FoxySheep.
The
Golden
Age
Of Mathematical Software
Math Communication
and Accessibility
It is easier than ever to communicate with students, teachers, collaborators, and the public about mathematics and education, and communication tools are increasingly accessible to visually impaired and underserved populations.
It is easier than ever to communicate with students, teachers, collaborators, and the public about mathematics and education, and communication tools are increasingly accessible to visually impaired and underserved populations.
Math Communication
and Accessibility
Powerful, free, easy to use document authoring
Overleaf (formerly WriteLaTeX) and ShareLaTeX
MarkDown
SageMath Cloud
iPython
MathJax
Collaborative authoring across the web
Overleaf (formerly WriteLaTeX) and ShareLaTeX
Sage Notebook, SageMath Cloud, iPython
GitHub, BitBucket, and other git solutions
Overleaf (formerly WriteLaTeX) and ShareLaTeX
Sage Notebook, SageMath Cloud, iPython
GitHub, BitBucket, and other git solutions
Online Communities
Increased access to proprietary systems
Free, high quality educational tools and content
MIT OpenCourseWare
MathWorld
Availability of high quality FOSS research and educational software
- The SciPy Python stack
- Sage and SageMathCloud
- GeoGebra
- Octave
- Maxima
...and hundreds more.
What Accounts for This?
Interface Technologies
Entity A
Entity B
Interface Technology
Entity A
Interface Technology
Entity B
Robert
Grandma
Telephone
Python
LAPACK
NumPy
SymPy
R
matplotlib
Maxima
Sage
Authors of LaTeX
The Web
MathJax
Entity A
Interface Technology
Entity B
Symbolic Computation System
Students and Teachers
GeoGebra
Python
Maple code
Maple code generator
C program
Mathematica kernel
WSTP (formerly MathLink)
The economics of interface technologies
- Entails all the advantages of specialization.
- experts are more time efficiency
- experts use other resources (money, students, etc.) more efficiently
- higher quality product
- greater productivity
- greater payoff for the specialist
- greater payoff for the consumer
- Avoids reinventing of the wheel.
- Right tool for the right job!
- Promotes communication, collaboration, and trust among human participants.
FoxySheep
A parser and FullForm emitter for Mathematica code
Image: Andrew Saeger and Veronica Velasco, Factory 43, Seattle, Washington
Parser
FullForm Emitter
StringJoin[Map[StringJoin,ConstantArray["0",
Plus[4,Times[-1,StringLength[s]]]]],s]
StringJoin/@ConstantArray["0",4-StringLength[s]]<>s
Features
- Uses ANTLR4 parser generator
- Grammar is target language independent
- ANTLR4 targets Java, C#, JavaScript, and Python2/3. (C++ in development.)
- Java and Python parser and FullForm emitter
- BSD Licensed — do anything at all with it.
- Developed in the open, open to other contributors.
Potential Uses
- Write a pretty printer for Mathematica code.
- Write a Mathematica code rewriter that inputs code written using nasty language constructs and outputs the same program but using saner notation. (Ever try to read someone else's crazy Mathematica code?)
-
Write a translator from Mathematica code to your favorite computer algebra system.
- "Execute" Mathematica code in Maxima, Maple, Sage, Octave....
- Extend your favorite FOSS computer algebra system to read Mathematica output. Your CAS will then be able to do whatever Mathematic can do.
Entity A
Interface Technology
Entity B
Symbolic Computation System
Students and Teachers
GeoGebra
Python
Maple code
Maple code generator
C program
Mathematica kernel
WSTP (formerly MathLink)
A math software project (Sage, Maxima, etc.)
Mathematica code
FoxySheep
Closed and Open
mutual benefits
Mathematica's output is also valid input. A translator from Mathematica to language X gives bidirectional communication between X language tools and Mathematica.
User-written Mathematica code
FoxySheep
Language X system
Mathematica kernel
This is
Not Theoretical
Many projects have expressed a desire for a Mathematica interface in the form of a parser or translator.
https://github.com/rljacobson/FoxySheep
rjacobson@rwu.edu
https://plus.google.com/+RobertJacobson
rjacobson@rwu.edu
https://plus.google.com/+RobertJacobson
https://github.com/rljacobson/FoxySheep
JMM 2016: Bridging the Closed and Open
By Robert Jacobson
JMM 2016: Bridging the Closed and Open
The proprietary computer algebra system Mathematica is a favorite among many teachers and researchers. Its polished interface and powerful library make it easy for undergraduates and researchers to use. However, its proprietary nature presents difficulties in terms of cost, peer review, reproducibility, etc. Meanwhile, excellent open alternatives exist but have incompatible syntax. FoxySheep is a parser for Mathematica-like syntax that facilitates communication between open mathematical software and Mathematica as well as using Mathematica-like code with open software without proprietary software.
- 940