This part covers the last example I did on JavaCamp. Over 3 videos you have an opportunity to see how to setup your environment, how to develop and compile your .M file to Java Jar file using Matlab JA Builder and how to write simple JSP/Servlet and deploy everything together on Tomcat 6.x
Before you start watching. It’s good to mention an issue with sound. I have recorded these sequences by using recordMyDesktop software. It’s very nice but I got issue with sound record. Actually you will see.
I’m back again as I have promised in my last post. Today i’m gonna show how to setup your Ubuntu 9.04 operating system and Tomcat 6.x for your Matlab JavaEE application development. I hope you are ready. Let’s start with … !
During my googling time I didn’t search any blogpost focused on that topic even from Windows. That was little bit surprise to me. I found only several nice examples which were only on image. No describtion how deploy them. So my enviroin ment setup became to be more chanlenging to me.
I expected you have installed you IDE correctly so I’m skipping this and I start:
Install JDK 1.6 or higher as it’s recommended
Install Matlab 2009b to your $MATLABROOT folder
Setup properly you environment properties. They have to be linked with your Matlab because you will need them for your application compilation. You may set up them to your .bashrc using for example gedit. It’s up to you. You have to setup these variables $LD_LIBRARY_PATH and $XAPPLRESDIR. Here is a help what to specify:
# XAPPLRESDIR access to Matlab graphical functions as plot, figure
Next task is to install Tomcat 6.x. I have used it from Ubuntu repository. Then you should link it with your IDE but I guess it’s simple task for you as you are familiar with.
Very important point connected with Tomcat 6.x usage for Matlab JavaEE applications deployment is to do change in <TOMCAT FOLDER>/conf/context.xml. Just after tag <Context> place following tag with properties <Loader delegate=”true”/>
This is problem caused by org.apache.AnnotationProcessor due to efforts from MYFACES-1246. The statement makes classloading in Tomcat sticking to JavaEE specification. This bug was really stupid.
Now is your system ready to start with JavaSE and JavaEE App development. I will gonna show in next text. Stay tuned I hope you are still involved.
I haven’t written my blog for while because I was analyzing data from Neurology Checkups during this time. I was very busy due to finish several tasks. Now is situation little bit better but still I’m under rush as common.
One night when I was writing Servlet/JSP pages for other project guys from Polish JavaUserGroup asked me to come to give presentation called “Matlab with Java injection”. I know this title is very interesting as a way of Java usage together with Matlab. I love the fact that part of Matlab is written in Java, but there is no nice connection. I understand to reason why ….
It was my second visit of Krakow. It’s funny because together with guys from Krakow we have organized GeeCON conference. This is an example of Internet power. I love skype, email and chatting. Back to the PJUG.
I gave my first presentation here for PJUG. It was great. I was surprised and impressed since the first moment about quality of everything. Atmosphere was so nice and guys looks like they are really interesting and they are educated around. I have to give big compliment in general!
My presentation topic was as you know “Matlab with Java injection”. It was very challenging since the start of using Matlab in that way. You can imagine little less documentation for windows users and similar to Linux. But Linux was worse since my point of view. So that was very challenging to me start work at this in the past. I wrote in the past assimilations for University purposes using Java. That was very different. I found out also one bug after long googling and thinking time connected with Tomcat 6 Annotation check as you will see on the part 2 ….
After I gave this presso it seems like everybody loves such way of JAVA usage. I was really happy I got so many questions . Stay tuned and have a nice day
Last night I need to solve this question. This stuff is very easy to do under JAVA based languages but not so easy under Matlab. I thought for while and then I realized that this is very simple. To generate random number under Matlab you are commonly using function rand(NUMBER). Rand generate array that’s the case. I thought for while and here is the simple solution.
%define size of Ineger number you need
size = 100
iNum = round(rand(1)*100);
% You get number example. iNum = 23
This category gonna be focused on around information which are sometimes useful when you are working with MatLab. My PhD is for me like big stimul. It still focing me to learn new things. Someone is reading any popular magazines focused on current trends in style. My hobby is to learning new technical/financial things … my brains is to hungry to stop with. So this category is about Matlab