MathGroup Archive 2002

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: executing 'ProductLog' from an external program (C code or shell)

  • To: mathgroup at smc.vnet.net
  • Subject: [mg38375] Re: [mg38330] executing 'ProductLog' from an external program (C code or shell)
  • From: Sseziwa Mukasa <mukasa at jeol.com>
  • Date: Fri, 13 Dec 2002 04:09:29 -0500 (EST)
  • Sender: owner-wri-mathgroup at wolfram.com

On Thursday, December 12, 2002, at 01:35 AM, Matt Flax wrote:

> Hello,
> I have the following in mathematica :
> x[z_]:=1000Log[10]-ProductLog[z]
>
> I would like to be able to execute this from a shell or C code. CForm
> just outputs :
> CForm[1000Log[10] - ProductLog[z]]
> 1000*Log(10) - ProductLog(z)
>
> Is it possible to compile 'ProductLog' to a C library or even an
> executable which I can then use in C code ?
>
>

You can use Mathlink to write a C program which calls the Mathematica 
kernel and returns the result.  If you are using UNIX you can then 
write a script which calls the Mathlink program with the appropriate 
arguments to start the kernel, I have some example code for this if you 
want.  I'm not sure how this works on Windows or Mac OS 9.

Regards,

Sseziwa



  • Prev by Date: Re: too many {{}}'s for listplot
  • Next by Date: Re: too many {{}}'s for listplot
  • Previous by thread: Re: executing 'ProductLog' from an external program (C code or shell)
  • Next by thread: inconsistent hardware requirements in 4.2