The tag has no usage guidance.

learn more… | top users | synonyms

2
votes
1answer
142 views

Using Minuit2 to minimize a Mathematica function

FindMinimum is great, but sometimes it is difficult to get an idea of the uncertainties and intermediate evaluation diagnostics. How to define a function in ...
0
votes
1answer
45 views

MathLink to C++ member function

The task is to compile, link and install in Mathematica (9.0, Linux 64 bit) some functions defined in C++. These functions are defined within classes. I have access to the header which forward define ...
0
votes
1answer
35 views

Restricting the evaluation of variables [closed]

Hopefully you understand my question. I m calculating inverse kinematics of a robot and each subsequent value is dependant on the one before. For simple porting into c++ I would like something like ...
12
votes
2answers
182 views

What is the best way to transfer arbitrary-precision reals using WSTP?

I'm developing a Mathematica package, inside of which there is a number-crunching function. It uses a list of arbitrary-precision numbers as input and it takes a lot of time to do its job. So I've ...
1
vote
0answers
67 views

Issue with WSTP

I'm trying to get Pythonika to work once again - with the latest version of the WSTP. The changes required are not many, basically just three: Change ML to WS Change mprep to wsprep Change mcc to ...
3
votes
2answers
201 views

What is the best way to work with complex number array in librarylink function in terms of C++ and Eigen?

I want to use C++ Eigen library in Mathematica Librarylink function. Currently, I have no problem dealing with real arrays. But I don't know what is the best way to deal with complex array in ...
5
votes
1answer
119 views

Initializing and keeping track of a large c++ object and reusing it from inside Mathematica

I have a c++ library function that calculates a distance between two vectors given an underlying matrix. ...
1
vote
0answers
69 views

How to simplify writing MathLink code? [closed]

This wonderful question inspired me to ask the analogue for MathLink, which is now known as Wolfram Symbolic Transfer Protocol (WSTP). The basic example addTwo is over complicated and under useful.
2
votes
1answer
49 views

Discard an entire (sub)expression on a MathLink link

Suppose that an expression like f[something, 12] was sent to a MathLink link, and we need to read off only the second part of ...
0
votes
1answer
136 views

Convert code from C++ to Mathematica [closed]

I need to know how to convert the following code in C++ to Mathematica. ...
3
votes
0answers
50 views

Importing binary structured C++ data file

I am trying to import a binary data file. It seems that BinaryReadList would be appropriate? However the data file is composed of c++ structures like this: ...
7
votes
0answers
102 views

How can I wrap a C++ object in WSTP?

I am trying to wrap a sophisticated C/C++ API in Mathematica using WSTP, but can't work out how to return a pointer to a C/C++ data structure. This object was created on the C/C++ side of the wrapper, ...
3
votes
1answer
141 views

Handling error in WSTP program C/C++

I have a program, written in C++, which uses WSTP to communicate with Mathematica 10 (i.e., linked using Install["name_program"]). How should my code report an ...
0
votes
0answers
67 views

Linking to C++ files [duplicate]

I have written mathematica file that does manipulations on a certain set of points. I would like to access code that someone else has written for a least square fit in C++. How do I access this C++ ...
1
vote
1answer
215 views

Read expression from Mathematica via Mathlink C++

This is a simple C++ program to send an expression to the_Mathematica_ Kernel and get its response. ...
0
votes
1answer
279 views

Random numbers in C++ and Mathematica gives wrong results? [closed]

I have the following strange phenomenon which puzzles me!: I have a piecewise constant probability density given as ...
0
votes
1answer
4k views

Error message LNK2019, unresolved external symbol _output referenced in function __tr0

I've successfully compiled the simple addtwo function predefined in Mathematica as per: MathLink dependencies: "LNK2019: unresolved external symbol _MLMain" I am now attempting to write an ...
1
vote
1answer
122 views

Hide MathKernel Tab on Taskbar when using C++ [duplicate]

I am connecting to MathKernel.exe using C++ via MathLink on Windows. Hence, to create the link, this is what I use: ...
1
vote
1answer
74 views

MLEvaluate() Function Gives Error

I am trying to link my C++ program to Mathematica Kernel. I am trying to use the MLEvaluate() evaluate but I receive an error while compilation. My codes are as below: ...
0
votes
0answers
51 views
2
votes
1answer
470 views

Creating a C++ project with Visual Studio 2010

I am trying to create a GUI using Microsoft Visual Studio C++ 2010 by calling Mathematica in my codes. I have done everything step by step as mentioned here Then I wrote this code as mentioned in ...
18
votes
1answer
834 views

Calling Mathematica from Visual Studio - example

I am trying to set up a connection between Visual Studio 10 and Mathematica 8.0 on a Windows system. I found several sources of information on the Wolfram website, but I get entirely lost. Most of the ...
0
votes
1answer
281 views

Making a C++ callable .lib or .dll file from a Mathematica notebook [duplicate]

MATLAB supports conversions of their function files into C++ callable libraries. I was wondering if the same feature is also available in Mathemathica? If yes, can you please guide me where I can ...
6
votes
2answers
655 views

How to convert data types in a LibraryLink wrapper

I have a dynamic library which I want to load into Mathematica using LibraryLink. I don't have access to the source code of the library, so I need a C wrapper to do the job. In the C wrapper, I would ...
2
votes
1answer
209 views

Executing C programs within mathematica [duplicate]

I have a requirement for executing a C program within Mathematica. The user will provide the inputs and the expected results on a front end. Mathematica runs the C file, obtains the result for the ...
0
votes
1answer
619 views

using Mathematica's matrix multiplication in C++

Is there any way that I can utilize Mathematica's matrix multiplication in a C++ program? I'm making a 3D graphics engine (for class) in C++ and I would really like to use Mathematica for all of my ...
9
votes
2answers
470 views

MathLink and C++ vector container

The Problem. I have a C++ class that does some computations, and returns a C++ vector object (the length of which can possibly vary with each run). I want to store each of these vectors as a list in ...