Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic

Re: Re: Re: Re: Re: Geometric Optimisation and Perl

by Vautrin (Hermit)
on Mar 27, 2004 at 17:04 UTC ( #340280=note: print w/replies, xml ) Need Help??

in reply to Re: Re: Re: Re: Geometric Optimisation and Perl
in thread Geometric Optimisation and Perl

You're right that if it's possible to solve the problem without using Mathematica, XS / Inline::C library wrapping, it is better to try what's available. However, I figured that I would put it out there, so that OP would know that there are other options if the problem gets complex enough.

I'm a big fan of Perl, but to be honest, not every problem is right for it. If the OP can get a more elegant solution by using a technical computing platform like Matlab, or Mathematica (and if they can afford to), he or she may want to. However, if the OP has a reason to use Perl -- perhaps to interface with a CGI script or already existing Tk/Perl application? -- the option is there.

I would also like to point out, that the OP doesn't have to use XS to return the values. If the solution is significantly complex, or the number is to a precision bigger then you can return via XS, or there is another reason to make XS a bad solution, it is possible to send the result over a Unix domain socket or a TCP/IP connection, or through a database, or put it in a file, or any of a number of possible solutions. Sometimes the best way to use a program is via a system() call that invokes a program that sends the data back to the program via a Unix domain socket. Of course, you're still going to have to roll your own protocol, but I figured I would put it out there so that the OP can decide what is best for his/her needs.

Want to support the EFF and FSF by buying cool stuff? Click here.

Log In?

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://340280]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (3)
As of 2022-01-26 12:36 GMT
Find Nodes?
    Voting Booth?
    In 2022, my preferred method to securely store passwords is:

    Results (69 votes). Check out past polls.