Is it possible to use Mathematica's computing capabilities from other languages? I need to do some complex operations (not necessarily symbolic, btw), and it'd be pretty sweet to be able to just call Mathematica's functions or running Mathematica's code right from my python/c#'s program.
是否可以使用Mathematica的其他语言的计算能力?我需要做一些复杂的操作(不一定是象征性的,顺便说一句),能够直接从我的python / c#程序中调用Mathematica的函数或运行Mathematica的代码是非常可爱的。
Is it possible?
可能吗?
5 个解决方案
#1
5
Looks like there is a MathLink API you can use from C#, c or Java, have you checked this out?
看起来你可以在C#,c或Java中使用MathLink API,你有没有看过这个?
http://reference.wolfram.com/mathematica/guide/MathLinkAPI.html
#3
4
Perhaps the easiest way is to make the Mathematica program its own self-contained script and just call it as a system call or pipe stuff to/from it via stdin/stdout. Here's how to do that:
也许最简单的方法是使Mathematica程序成为自己独立的脚本,并通过stdin / stdout将其称为系统调用或管道内容。以下是如何做到这一点:
Call a Mathematica program from the command line, with command-line args, stdin, stdout, and stderr
从命令行调用Mathematica程序,使用命令行args,stdin,stdout和stderr
#4
1
I haven't used it, but this looks interesting. Looks like you can call Mathematica code directly from your C# app using .NET/Link (a product by Wolfram).
我没有用它,但这看起来很有趣。看起来您可以使用.NET / Link(Wolfram的产品)直接从您的C#应用程序调用Mathematica代码。
#5
1
Yes but there are some subtleties. I covered Mathematica .NET interoperability in my book F# for Scientists but dropped the subject for its successor F# for Technical Computing.
是的,但有一些细微之处。我在我的F#for Scientists一书中介绍了Mathematica .NET的互操作性,但放弃了技术计算的继任者F#的主题。
#1
5
Looks like there is a MathLink API you can use from C#, c or Java, have you checked this out?
看起来你可以在C#,c或Java中使用MathLink API,你有没有看过这个?
http://reference.wolfram.com/mathematica/guide/MathLinkAPI.html
#2
#3
4
Perhaps the easiest way is to make the Mathematica program its own self-contained script and just call it as a system call or pipe stuff to/from it via stdin/stdout. Here's how to do that:
也许最简单的方法是使Mathematica程序成为自己独立的脚本,并通过stdin / stdout将其称为系统调用或管道内容。以下是如何做到这一点:
Call a Mathematica program from the command line, with command-line args, stdin, stdout, and stderr
从命令行调用Mathematica程序,使用命令行args,stdin,stdout和stderr
#4
1
I haven't used it, but this looks interesting. Looks like you can call Mathematica code directly from your C# app using .NET/Link (a product by Wolfram).
我没有用它,但这看起来很有趣。看起来您可以使用.NET / Link(Wolfram的产品)直接从您的C#应用程序调用Mathematica代码。
#5
1
Yes but there are some subtleties. I covered Mathematica .NET interoperability in my book F# for Scientists but dropped the subject for its successor F# for Technical Computing.
是的,但有一些细微之处。我在我的F#for Scientists一书中介绍了Mathematica .NET的互操作性,但放弃了技术计算的继任者F#的主题。