Ask Your Question
0

Generation of optimized Fortran code?

asked 2011-06-08 10:07:25 +0100

Omri gravatar image

Hey All,

Is it possible to use Sage to generate Fortran code from its expressions which is optimized? I'm looking for an OSS alternative to the CodeGeneration package of Maple.

I came across a discussion about it from 2008 where it was said that it is a planned feature but I didn't manage to find anything newer about that.

Many thanks, Omri

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2011-06-08 10:58:07 +0100

kcrisman gravatar image

I don't think so.

However, Cython might be just as good for you. It will generate C code based on your Sage code, compile it on the fly, and then you have a C program to use.

Some links:

edit flag offensive delete link more

Comments

Thanks for the quick reply! The reason why I need it is to include it into an already bigger program written in Fortran (I wouldn't have chosen it myself) and I need an optimized code (i.e - many declared variables which contain steps of the calculation, exactly like Maple can produce).

Omri gravatar imageOmri ( 2011-06-08 12:23:13 +0100 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

Stats

Asked: 2011-06-08 10:07:25 +0100

Seen: 516 times

Last updated: Jun 08 '11