# Call C/C++ Code

Let's say, I wrote matrix.c which is a C file containing several functions. Can I call any of the functions defined in matrix.c from Sage? What special compilation do I need for matrix.c?

Call C/C++ Code

add a comment

4

3

Probably you will want to use Cython to do this - it's a good way to integrate C libraries with Sage (as well as to create C code from within Sage).

You may also want to search this site for Cython for more tips.

Asked: **
2011-06-15 18:14:22 -0500
**

Seen: **1,051 times**

Last updated: **Jun 15 '11**

Other than "Jupyter Notebook", is there any other way to use Sage?

Interactivelinearprogramming gives the wrong answer

Use os SOS2 in Linear Optimization

Call pure python code from SAGE

Linear programming displaying Latex formated equations

How to create a "sage program" with command line input

The annulus problem in linear programming

Copyright Sage, 2010. Some rights reserved under creative commons license. Content on this site is licensed under a Creative Commons Attribution Share Alike 3.0 license.