Implement CalculateInfluence

Signed-off-by: Tzu-Li Tai <tzulitai@ee.ncku.edu.tw>