corrected tests for assignment method according to the new representation of Factor [refs #137]
completely changed assignment method according to new representation and also reducing the execution time by half [refs #137]
fixed reduce method according to the new representation of Factor [refs #137]
Merge pull request #169 from ankurankan/dev

Changes in Factor class according to the new representation