Thursday, 24 March 2011

FR Success (I think?)

I've mentioned my struggle with the FR and CW force functions before, and chose to ignore them until I needed them (so I could concentrate on other things such as the multilevel). Recently, as speed is now an issue, I have spent a lot of time attempting to implement these faster forces.

Unfortunately, I had hit a road block; no matter what I tried, I could not get forces that worked well (often one force overpowered another resulting is vertices being thrown huge distances apart and eventually their position becomes infinite [in Java]).

After struggling for long enough, I spoke to my supervisor, who pointed out a flaw in my understanding. You see, I have been going through papers with an understanding that the |x| notation as the absolute value/size/magnitude. So when I came to Fruchterman and Reingolds pseudocode, the line: disp/|disp|, to me, meant get the sign of disp.

if disp = -2.0;  (-2.0)/(2.0) = -1;

Unfortunately my understanding was partially incorrect, in the pseudo code, the notation |x|, or in CW, ||x||, is the normalise function. So for a vector V, ||V|| would be the length of the vector (or using my own previous notation, d).

disp.x/disp = x-axis component of vector

What's almost cruel, is I have used this previously for applying my Eades forces, so should have realised this. Although not implemented in my code yet, I have tested my new understanding on paper, and it appears to work (although I ignore the min(||disp||, t) function as I want to avoid the cooling schedule for now [for testing purposes]).

In other news, I found a useful paper which looks at over 100 network visualisation tools which looks to be useful (published December 2007 so fairly recent). I have also found a peice of software that has implemented my "Big Bang" idea which, in a way, is a confidence boost (something I thought of works, even if not implemented by myself). Details will be added in a later post.

No comments:

Post a Comment