2

I'm writing my 4th year project and I am trying to add an external library but for some reason I can't seem to get this running. I have been Googling for days and I still can't seem to fix this problem.

I have tried the following:
1) I have added the jar file to the "libs" folder
2) I have added the jar file as a library
3) I've checked the library off in the "Build Path" > "Order and Export"

Anyone else have any possible suggestions?

dalvikvm(4015)          : Could not find class 'org.ejml.data.DenseMatrix64F', referenced from method com.makarintosh.voweltutor.FormantTracker.findRoots
dalvikvm(4015)          : VFY: unable to resolve new-instance 805 (Lorg/ejml/data/DenseMatrix64F;) in Lcom/makarintosh/voweltutor/FormantTracker;
dalvikvm(4015)          : DexOpt: unable to opt direct call 0x17e3 at 0x05 in Lcom/makarintosh/voweltutor/FormantTracker;.findRoots
AndroidRuntime(4015)    :   at com.makarintosh.voweltutor.FormantTracker.findRoots(FormantTracker.java:157)
AndroidRuntime(4015)    :   at com.makarintosh.voweltutor.FormantTracker.doLPC(FormantTracker.java:122)
AndroidRuntime(4015)    :   at com.makarintosh.voweltutor.Recorder.processData(Recorder.java:61)
AndroidRuntime(4015)    :   at com.makarintosh.voweltutor.Recorder$1.run(Recorder.java:80)

The library I am trying to add is this: https://code.google.com/p/efficient-java-matrix-library/

EDIT
I also forgot to mention that the error seems to occur only with the specified class, "DenseMatrix64F". Although other classes that I am using from the library seem to run just fine.
The error occurs during RUNTIME.

Makar Emelyanov
  • 167
  • 5
  • 16

1 Answers1

2

First, you need to Read the Liberary manual because it is the best reference for your liberary

You have two ways in Android to add liberaries. First, to add a liberary project from Project>Preferences(Properties)> Android> Add Liberary project. Second to have a .Jar file and copy it into your project in Libs directory.

Sometimes you need to Clean and Build the project again after importing your liberary.

Look for this link and examples for your lib, it will help https://code.google.com/p/efficient-java-matrix-library/wiki/EjmlManual

Sami Eltamawy
  • 9,874
  • 8
  • 48
  • 66
  • Thanks for your reply Abd, but I have tried both of those methods and it did not work. Also the manual was no help either. I have also updated the problem after trying to figure out more of the error. It seems like the program can't reach the specified class. Yet other classes I am using from the library don't complain. This only occurs during runtime. – Makar Emelyanov May 04 '13 at 21:04
  • If you can reach the source code of your lib, you can get your class directly and put it into your Main package to work with. I hope you can fix your problem as soon as possible. But If you are sure that your are doing it right. Try to import another Lib to double check that you are doing it right. If the new one works, then the problem with Ejml Liberary – Sami Eltamawy May 04 '13 at 21:08
  • 1
    Hera you are.. download the SRC from here and get your class directly and the related classes https://code.google.com/p/efficient-java-matrix-library/downloads/detail?name=ejml-0.22-src.zip&can=2&q= I hope this helps :) – Sami Eltamawy May 04 '13 at 21:09
  • Unfortunately this did not help me with my predicament. So Question is still on the board. – Makar Emelyanov May 04 '13 at 22:08