Prev: NDSolve problem with switching
Next: RSolve problem: won't solve convolution recurrence relation.
From: cynthia wu on 5 Jan 2010 01:47 I created a jar file that runs methods that I have created in Mathematica. The java file has everything(libraries, import) it needs to connect to the Mathematica Kernel and run the methods. My issue is that I am using my jar file in Ruby. I have imported the jlink library, my jar file, and everything else I feel it needs to run my java file. However, I am getting the current error: Fatal error: cannot find the required native library named JLinkNativeLibrary.dll Any suggestions would be greatly appreciated.
From: David Bailey on 6 Jan 2010 05:57 cynthia wu wrote: > I created a jar file that runs methods that I have created in > Mathematica. The java file has everything(libraries, import) it needs > to connect to the Mathematica Kernel and run the methods. > > My issue is that I am using my jar file in Ruby. I have imported the > jlink library, my jar file, and everything else I feel it needs to run > my java file. However, I am getting the current error: > > Fatal error: cannot find the required native library named > JLinkNativeLibrary.dll > > Any suggestions would be greatly appreciated. > JLink communicates with Mathematica via MathLink, which is in a native library (C) - so the error makes perfect sense. Are you writing Java code that will invoke Mathematica code, or are you writing Java code that will be called from Mathematica in the first instance? What do you intend to happen with Ruby - do you intend Ruby to call Java that then calls Mathematica? Note that if you invoke Java from within mathematica, you will be using Java 6 (with Mathematica 7) with a large class path that you can discover using GetClassPath[] You obviously need some items from that path. I hope this at least gives you a few thoughts to follow up on. David Bailey http://www.dbaileyconsultancy.co.uk
From: Patrick Scheibe on 6 Jan 2010 06:01 Hi, the JLink uses MathLink which is a C-Library and the only real link to Mathematica. Everthing in Java seems to use this connection. When you start to use JLink it loads this JLinkNativeLibrary.dll library through JNI, the java native interface (http://en.wikipedia.org/wiki/Java_Native_Interface) and this step obviously fails. You can have a look at the sources if it helps to understand. It is under MathematicaRootPath/SystemFiles/Links/JLink/Source/Java/com/wolfram/jlink in the file NativeLink.java. What you have to do is to find out why java doesn't find this library when it starts. You have this dll under the above mentioned path /usr/local/Wolfram/Mathematica/7.0/SystemFiles/Links/JLink/SystemFiles/Libraries but it should be installed globaly anyway. This is the plan and the information I can provide. The rest is up to you since it is hard to guess what's wrong from here. Maybe you should try first to place the JLinkNativeLibrary.dll directly into the directory of your application if you use Windoze. Good Look. Cheers Patrick On Tue, 2010-01-05 at 01:47 -0500, cynthia wu wrote: > I created a jar file that runs methods that I have created in > Mathematica. The java file has everything(libraries, import) it needs > to connect to the Mathematica Kernel and run the methods. > > My issue is that I am using my jar file in Ruby. I have imported the > jlink library, my jar file, and everything else I feel it needs to run > my java file. However, I am getting the current error: > > Fatal error: cannot find the required native library named > JLinkNativeLibrary.dll > > Any suggestions would be greatly appreciated. >
|
Pages: 1 Prev: NDSolve problem with switching Next: RSolve problem: won't solve convolution recurrence relation. |