|
Programming -
java
|
|
I wrote a JAVA code for Kohonen Map. The code is compatible with both the Windows system and Unix system. I primarily ran the experiment on Suse Linux 10.0, with Java 1.5 SDK. The following command will convert Java code to bytecode
Javac Kohonen.java
The following command will execute the bytecode to produce the results
Java Kohonen
|
|
Last Updated on Monday, 17 May 2010 21:40 |
|
Read more...
|
|
|
Travelling Salesman Problem by ACO |
|
|
|
|
Programming -
java
|
|
I did this project for my class of machine learning at Mississippi State University. It is a simple demonstration of how ant colony optimization technique can be used in routing problems. This is first code i have ever written for ACO, just to understand how things work in the machine learning technique. I have several other techniques used, but ACO was my own exploration out of what we had planned for the course. I translated the code by Eric Rollins written in Python to Java Applet, thanks to Eric, I not needed to reinvent the wheel. The really liked this technique and expect to use this technique in my research at some point of time.
|
|
Last Updated on Monday, 17 May 2010 21:38 |
|
Read more...
|
|
Programming -
java
|
|
The modern browsers do not allow the client side codes like javascript to access other servers from the client side which is known as "Same Origin Policy". The technologies like AJAX whose heart lies on the Javascript, can not access any other server except the same server on which it is hosted on. This policy do not allow even a different port number to be accessed by a webpage on the same host. There has been a lot of talks about the "JSON" technology instead of the universal "XML" technology to be used, but at the moment most of the communication takes place through XML document. For XML communication to happen and the web-services to be accessed, we need to create a proxy server on the same host, which will send the XML request to the "External Server" on the behalf of the AJAX client.
The following code will do the job. just host the code as a servlet and send the XML request to the proxy servlet.
The request to the proxyServlet must have a header ServerAddress set to the final destination of the request.
|
|
Last Updated on Sunday, 28 March 2010 07:24 |
|
See Source Code
|
|
|
Programming -
java
|
|
The client side codes cannot write a file on the client computer, so particularly in web-programming, we need to create a servlet which will send the file to be saved as a downloadable file to the client side. This will envoke the "SAVE AS" dialog of the browser making it possible to save the file in desired name.
|
|
Last Updated on Sunday, 28 March 2010 11:02 |
|
Show Source Code
|
|
|
|
|
|