[IPython-dev] Fortran Magic for IPython
Thu Sep 12 13:35:35 CDT 2013
El 12/09/13 15:25, Ondřej Čertík escribió:
> I developed Fortran magic for IPython:
> Follow the link in the README for an example notebook. Travis
> suggested this idea to me yesterday in a pub. ;)
> You should be able to run everything from:
> Some notes:
> * the syntax highlighting is wrong for Fortran, both in code cells an
> markdown cells
> * it'd be nice to automatically wrap via Cython some subroutines to
> Python with %%fwrap magic, currently I just execute the code with the
> %%fortran magic
> * it'd be nice to allow to link my Fortran library in, so that I can
> interactively test subroutines in it. So I use my current build system
> for my library, and just tell the %%fortran magic to link it + paths
> to *.mod files, so that I can import modules. That should be quite
> robust/simple to do. The only requirement is to use the same compiler.
> * what is the best way to setup different compilers and compiler
> options in the %%fortran magic? The code is here:
> it's really simple so far.
> * all cells are currently independent. I don't think it makes sense to
> try to somehow append and execute code together from multiple cells.
> But it might make sense to reuse modules defined in different cells
> * Eventually I'd love to contribute a PR against IPython notebook with
> this extension, but for now I am just polishing it in the above
> I would appreciate any feedback.
> IPython-dev mailing list
Ondrej, some days ago Martin publish a fortran magic, he also makes a PR
to give codemirror support for Fortran, maybe both can join forces... ;-)
More information about the IPython-dev