Makes some computing and
draws graph(s), from a non-graphical language,
such as Fortran or C.
This is a prototype example of using
'base64' encoding. It was chosen to eliminate remaining
temporary graphic files (here, '.png'), which would otherwise
have to be removed afterwards. The base64-encoded graphs
are produced here via a call do the Linux 'base64' command,
which obtains the encoded file from the image file itself
(then deleted). The recourse to the system call
solved the absence of an equivalent routine
in the language used (Fortran 90+).
Plots one (the first) or two graphs
of simple functions —'sin' and 'cos'—, for illustration,
together.with some computational results. |