Questions about interfacing Mathematica and Java, particularly using J/Link.

learn more… | top users | synonyms (1)

4
votes
1answer
197 views

Add new JDBC Driver to connect MM to SQL database

I cannot open a SQLConnection to a SQL vectorwise database and I assume the JDBC driver is the problem. A JAR file was provided to me - the only info additionally provided to me was the java class: ...
4
votes
1answer
62 views

Is it possible to get the locations and dimensions of all boxes in a StandardForm expression renderation?

I can select all the boxes in a StandardForm rendered expression, like I've selected the left parenthesis in the picture above. Is it possible to get the positions and dimensions of all of these ...
4
votes
1answer
141 views

How to make a widget float?

Is there an option or way to make a GUIKit window remain in on top of other application's windows? ...
0
votes
0answers
45 views

Does Mathematica create a security risk by running Java on my Mac?

I checked inside the package that is the Mathematica App on the Mac. It has a bunch of .jar files, so I assume that it is running Java. Does this open up any security threats that I should be aware ...
1
vote
1answer
127 views

Problem with loading a Jar file in Workbench

I'm trying to load a Jar file in a Workbench project using (after importing "JLink`" in the package declaration): ReinstallJava[ClassPath->"pathToMyJar"]]; In ...
4
votes
1answer
65 views

Running Java with Wolfram Workbench on a parallel kernel

I'm trying to load my package on a parallel kernel while debugging in Wolfram Workbench 2.0. My project is set up as a Java project and parts of it use Java functions located in jar files. The java ...
9
votes
1answer
233 views

Connect Frontend to Kernel Started by JVM via JLink

I have a MathKernel started and controlled via JLink from a JVM. The $CommandLine for this kernel is: ...
1
vote
0answers
72 views

using Mathematica library in Java

I am trying to build a Math expression calculator in Java. Is any way for using Mathematica libraries in Java program without ...
0
votes
0answers
22 views

how can sent data to Mathematica and get result in java? [duplicate]

I try to develop an math script calculator in java. My script has advance math functions and I can't calculate them in java.(for example limit, plot, ... ) Is any way for sending script to ...
4
votes
1answer
178 views

How can I integrate Open-CV with Mathematica?

I would like to run Open-CV functions from within Mathematica, can anyone figure out how to do this?
6
votes
1answer
407 views

How can I connect to the IB TWS platform from Mathematica?

TWS is the trading platform of Interactive Brokers. Accessing it programmatically could be useful for various purposes. How could I access it from Mathematica ?
2
votes
1answer
99 views

How to get a audio file's duration time in Mathematica?

I have a *.avi file and if I want to know the file's duration time: I can use this code to get the result: Import["test.avi", "Duration"] or the code to get the ...
2
votes
1answer
46 views

JLink does not preserve the input cell number

I use JLink for connecting to the Mathematica kernel and evaluate some expressions. The In[] prompt is not continuous - it has step 3. I.e. the first expression is In[1] and after the evaluation the ...
5
votes
0answers
81 views

IntelliJIdea front-end plugin with JLink [closed]

I did some proof-of-concept work on having Mathematica Front-End (MathSessionPane) in the IntelliJ Idea as a plugin https://github.com/dubrousky/Mathematica-REPL. It uses JLink as a runtime dependency ...
1
vote
0answers
46 views

Using GUI with JLink

How to handle Input/Manipulate expressions using JLink? Say I want to handle the $Input[]$ expression sent via JLink to the MathKernel. Currently the my app blocks on waiting the response. How this ...
9
votes
1answer
111 views

Installing LinkSnooper on Windows

I tried to install LinkSnooper on my Windows 7 computer, as described in the documentation and here. According to the answer of @Todd Gayley, I entered the following string in the field MLOpen: ...
0
votes
0answers
42 views

JLink-Java Console cann't show Chinese characters

My version is mathematica 10 on windows 8.1 x64 中文 Chinese character can't be shown in the console correctly. Any methods to overcome this problem? It seems the ...
1
vote
0answers
166 views

InstallJava::fail error when importing an image with a Raspberry Pi

I'm trying to import an image in Mathematica on my Raspberry Pi. The code is simple but I get an error when importing: ...
3
votes
1answer
115 views

Creating a generic empty list with JLink

I'm trying to reproduce a Java code in Mathematica using JLink, I'm making calls to an API in a JAR file. For one of the function call an empty list of a given type is needed but I don't know the ...
6
votes
1answer
235 views

How to find out the current memory on the JVM?

I want to find out the amount of memory available in the Java Virutal Machine. I tried: ...
9
votes
0answers
158 views

J/Link doesn't work with Java 8?

I have some code that successfully uses J/Link (well... until today when something I was doing something with it that crashed the JVM, so), and I recently tried running it under Java 8. I then get a ...
5
votes
3answers
1k views

Failed to connect remote Mathematica kernel using J/Link

I'm trying to connect to a remote Mathematica 8 kernel (on a Windows machine) using J/Link. On the client machine, I put the JLinkNativeLibrary.dll file in ...
1
vote
0answers
34 views

How to call a java method that takes a boolean (not Boolean)?

I'm trying to call a method on a java object that takes a single boolean argument - note boolean (native or primative) not Boolean (Object or Reference type). ...
8
votes
6answers
758 views

Installing RLink on Linux

I'm trying to install RLink here. Needs["RLink`"] InstallR[] After downloading it throws an error: ...
8
votes
0answers
336 views

Problems running Mathematica 10 with Workbench 2 Windows 7 64 bit

My Workbench runs perfectly using Mathematica 9, however simple things which run just using the Mathematica 10 front end won't run when using Mathematica 10 and Workbench 2. These simple two lines of ...
0
votes
0answers
63 views

Lightweight Grid preferences screen stopped working after v10 install

I am getting the following error when I try to open the Lightweight Grid "Preferences" tab... ...
3
votes
0answers
42 views

Create custom mappings of Mathematica Expressions => Java Objects?

I would like to call a JLink-based java function from Mathematica with a Mathematica Span[] object as shorthand, like so... ...
1
vote
0answers
49 views

Is there any metadata-holding mechanisms in Mathematica programming similar to Java annotations?

I'm re-implementing some tools previously implemented in Java in Wolfram Language. Is there any metadata-holding mechanisms in Mathematica programming similar to Java annotations?
10
votes
3answers
4k views

Connect to SQLite database

I am trying to connect to a SQLite database and since there is no officially supported driver; I decided to use the sqlite-jdbc driver and port the respective code into Mathematica. However, the ...
5
votes
1answer
212 views

Using J/Link with Wolfram Programming Cloud

Is it possible to use J/Link in a Wolfram Programming Cloud notebook? I need it to load and use 3rd-party .jars.
22
votes
4answers
3k views

Efficiently determining if 3D points are within a surface composed of polygons

This is the 2nd part of a previous question which I edited to make into 2 separate questions: Extracting polygons from 3D contour plot surface As an extension of my earlier question involving simple ...
1
vote
0answers
44 views

Clojuratica setup in Windows

I have been trying to setup Clojuratica on Windows using instructions from Clojure Data Analysis Cookbook and http://drcabana.org/2012/10/23/installation-and-configuration-of-clojuratica/ Each time I ...
4
votes
0answers
69 views

Possible JLink memory leak (during) object creation

Using MMA 9.0.1 on win7-64. When creating a large number of java objects I noticed memory being consumed in huge quantities (several Gb). This memory is returned/deallocated after my call ...
3
votes
2answers
146 views

Passing an internal static class in JLink?

I am trying to get started with the Stanford NER tools tools in Mathematica, and am having difficulty translating the demo they provide into JLink. The relevant code in the demo is: ...
0
votes
0answers
56 views

Evaluating expressions stored in notebook from Java

The Mathematica kernel can generally open a notebook and evaluate the functions present in the notebook using UsingFrontEnd Command. Example: ...
2
votes
0answers
91 views

Graphics always rendered twice with SimpleFrontEnd example?

I am looking at the Java SimpleFrontEnd example provided by Mathematica. Everything goes well except it always renders graphics twice. Can anyone help me with ...
3
votes
1answer
266 views

Mathematica 9, Mavericks, Java

I've been trying to get a clear story regarding the interaction of these three components before upgrading my system from Lion to Mavericks --- I can't afford a Mathematica disaster. What I think is ...
8
votes
2answers
228 views

Working with Java hashmaps from Mathematica

I'm using J/Link to access data from an external Java program. The data are represented as a ConcurrentHashMap (see the official specification here). ...
2
votes
1answer
83 views

JLink function not producing result

I have a simple JLink function as follows: ...
2
votes
1answer
146 views

Clojuratica setup

I am trying to get Clojuratica set up (MMa v 9 free trial) (on a Mac running Mavericks) I am following the instructions in "Clojure Data Analysis Cookbook" but have also followed the instructions: ...
2
votes
1answer
252 views

Java Heap Space Error on data insertion over SQL Server

I'm trying to insert 2-milliion lines into a SQL Database, and get this error: JDBC::error: Java heap space The insert is a standart Mathematica SQL statement: ...
9
votes
2answers
1k views

Using J/Link to decode Google Maps Polyline strings

I would like to use this java code inside Mathematica using J/Link. It converts Google Maps API Encoded Polylines to a list of points. I tried the Mathematica tutorial but got lost. There is the Java ...
6
votes
1answer
140 views

J/Link: Callback from J/Link into Java when Mathematica process terminates?

Is it possible to get a callback from J/Link into java when the (remote) link closes or the Mathematica process is terminated (killed) altogether?
1
vote
1answer
392 views

Calling Mathematica from Java

I'm trying to write a Java program that uses Mathematica code, but when I compile it, a window appears asking for MathLink. I enter ...
6
votes
1answer
133 views

LinkSnooper troubles on Windows

I'm trying to get LinkSnooper up and working on a Windows 7 machine to monitor the interaction between the Mathematica front end and MathLink. I'm facing great troubles following the instructions ...
2
votes
2answers
120 views

J/Link: getArray2() returns wrong array

I want to convert a matrix from Mathematica to an int[][] in Java. I use the code below: ...
2
votes
1answer
113 views

J/Link: InstallJava[..] or ReinstallJava[..] hangs when used with a link to a remote jvm running Install.main

While I am able to use InstallJava[] (or ReinstallJava[] for that matter) with a TCP/IP link to a JVM running on the same system ...
9
votes
1answer
215 views

How secure is J/Link?

Are there security concerns with using J/Link? If so, is there any way to encrypt the data passed between Mathematica and Java? If Mathematica and the JVM are running on the same machine, is there any ...
4
votes
0answers
248 views

How to improve gesture detection by JLink for the LeapMotion controller

Building on this thread (where I cannot add anything anymore somehow) and with this nice answer I kind of got swipe detection to work, but it is not very responsive. How to improve (in the sense of ...
4
votes
2answers
215 views

J/Link: How to run a thread inside Mathematica

In the J/Link User Guide there is no example on how to use java.lang.Thread, from inside Mathematica. I'd like to know if is possible to start a thread from a ...