摘要
随着互联网技术的发展,软件系统的规模也在日益扩大,软件功能的变化使得软件网络的结构呈现差异化。软件网络的分形结构体现出软件网络整体和局部对象类之间依赖调用的自相似性,可以从代码层面上对软件系统结构以及功能进行分析。文中对软件网络分形结构特征进行研究:首先,综合类之间的依赖关系,对软件网络进行加权;然后利用基于网络中心性的盒子算法计算加权软件网络结构的分形维度,以分析其分形结构特征;最后,利用上述方法对spring和struts2这两款具有代表性的java软件框架进行分析。实验表明,这两款软件以及它们的子模块都具有分形结构特征,软件网络的分形维数随着模块功能复杂程度的增加而增加,功能综合性较强的软件网络分形维数要大于功能专一的软件网络;并且在版本演化过程中,软件网络的分形维数随着软件功能的丰富也呈现上升的趋势。
With the development of the Internet technology,the scale of software architecture is growing beyond the requirements,and the software function changes the structure of software network.The fractal structure of the software network reflects the self-similarity of the modules and the whole software network,and can analyze the architecture of software from the code level.This paper researched the fractal characteristic of software networks.First,the software networks are weighted by the complex relationships between the classes.Further more,a network centrality based box algorithm is utilized to calculate the fractal dimension of the software network.At last,two representative software of spring and struts2 are analyzed through experiments,and the results show that the both two framework and their modules have fractal features and the fractal dimension of the software network increases with the complexity of the module.The fractal dimension of the software network with more comprehensive functions is bigger than that of the software network with special functions.Also the fractal dimension increases with the evolution of the software version in which the software function is gradually improved.
引文
[1] WILFREDO T.Software Fault Tolerance:A Tutorial[J].Pomales,2000,1(2):220-232.
[2] BRIAND L C,DALY J W,WST J.A Unified Framework for Cohesion Measurement in Object-Oriented Systems[J].IEEE Transactions on Software Engineering,2002,25(1):91-121.
[3] MYERS C R.Software systems as complex networks:structure,function,and evolvability of software collaboration graphs[J].Physical Review E Statistical Nonlinear&Soft Matter Physics,2003,68(2):046116.
[4] DONG Y,QI G N.The scale-free feature and evolving model of largescale software systems[J].Acta Physica Sinica,2006,55(8):3799-3804.(in Chinese)闫栋,祁国宁.大规模软件系统的无标度特性与演化模型[J].物理学报,2006,55(8):3799-3804.
[5] HAN M C,LI D Y,LIU C Y.Networked characteristics in software and its contribution to software quality[J].Computer Engineering&Applications,2006,42(20):29-32.
[6] MA Y T,HE K Q,LI B,et al.Empirical Study on the Characteristics of Complex Networks in Networked Software[J].Journal of Software,2011,22(3):381-407.
[7] GAO Y,PENG Y,XIE F,et al.Software Metrics for complex networks[J].Journal of Tsinghua University(Science and Technology),2012,52(10):1474-1481.(in Chinese)高洋,彭勇,谢丰,等.基于复杂网络的软件结构度量[J].清华大学学报(自然科学版),2012,52(10):1474-1481.
[8] CHONG C Y,LEE S P.Analyzing maintainability and reliability of object-oriented software using weighted complex network[J].Journal of Systems&Software,2015,110(C):28-53.
[9] WANG B Y,LV J H.Software Networks Nodes Impact Analysis of Complext Software Systems[J].Journal of Software,2013,24(12):2814-2829.(in Chinese)汪北阳,吕金虎.复杂软件系统的软件网络结点影响分析[J].软件学报,2013,24(12):2814-2829.
[10]KUANG L,ZHENG B J,LI D Y,et al.A fractal and scale-free model of complex networks with hub attraction behaviors[J].Science China Information Sciences,2015,58(1):1-10.
[11]CONCAS G,LOCCI M F,MARCHESI M,et al.Fractal dimension in software networks[J].Europhysics Letters,2006,76(6):1221-1227.
[12]CONCAS G,MARCHESI M,MURGIA A,et al.Assessing traditional and new metrics for object-oriented systems[C]∥Proceedings of the 2010ICSE Workshop on Emerging Trends in Software Metrics.ACM,2010:24-31.
[13]TURNU I,CONCAS G,MARCHESI M,et al.The fractal dimension of software networks as a global quality metric[J].Information Sciences,2013,245(10):290-303.
[14]CHIDAMBER S R,KEMERER C F.A metrics suite for object oriented design[J].IEEE Transactions on Software Engineering,1994,20(11):197-211.