The University of Queensland, School of Mathematics and Physics, Qld 4072, Australia.
Ann Bot. 2011 Oct;108(6):1025-41. doi: 10.1093/aob/mcr121. Epub 2011 Jul 1.
Functional-structural plant models (FSPMs) are used to integrate knowledge and test hypotheses of plant behaviour, and to aid in the development of decision support systems. A significant amount of effort is being put into providing a sound methodology for building them. Standard techniques, such as procedural or object-oriented programming, are not suited for clearly separating aspects of plant function that criss-cross between different components of plant structure, which makes it difficult to reuse and share their implementations. The aim of this paper is to present an aspect-oriented programming approach that helps to overcome this difficulty.
The L-system-based plant modelling language L+C was used to develop an aspect-oriented approach to plant modelling based on multi-modules. Each element of the plant structure was represented by a sequence of L-system modules (rather than a single module), with each module representing an aspect of the element's function. Separate sets of productions were used for modelling each aspect, with context-sensitive rules facilitated by local lists of modules to consider/ignore. Aspect weaving or communication between aspects was made possible through the use of pseudo-L-systems, where the strict-predecessor of a production rule was specified as a multi-module.
The new approach was used to integrate previously modelled aspects of carbon dynamics, apical dominance and biomechanics with a model of a developing kiwifruit shoot. These aspects were specified independently and their implementation was based on source code provided by the original authors without major changes.
This new aspect-oriented approach to plant modelling is well suited for studying complex phenomena in plant science, because it can be used to integrate separate models of individual aspects of plant development and function, both previously constructed and new, into clearly organized, comprehensive FSPMs. In a future work, this approach could be further extended into an aspect-oriented programming language for FSPMs.
功能结构植物模型(FSPMs)用于整合植物行为的知识和检验假说,并帮助开发决策支持系统。目前正在投入大量精力为其构建提供合理的方法。标准技术,如过程式或面向对象编程,不适合清晰地分离植物功能的各个方面,这些方面在植物结构的不同组件之间纵横交错,这使得它们的实现难以重复使用和共享。本文的目的是提出一种面向方面的编程方法,以帮助克服这一困难。
使用基于 L 系统的植物建模语言 L+C 来开发基于多模块的面向方面的植物建模方法。植物结构的每个元素都由一系列 L 系统模块表示(而不是单个模块),每个模块代表元素功能的一个方面。使用单独的生产集来对每个方面进行建模,通过使用局部模块列表来促进上下文敏感规则,可以考虑/忽略模块。通过使用伪 L 系统实现方面编织或方面之间的通信,其中生产规则的严格前序指定为多模块。
新方法用于将先前建模的碳动态、顶端优势和生物力学方面与猕猴桃芽发育模型集成。这些方面是独立指定的,它们的实现基于原始作者提供的源代码,没有进行重大更改。
这种新的面向方面的植物建模方法非常适合研究植物科学中的复杂现象,因为它可以用于将先前构建的和新的植物发育和功能各个方面的单独模型集成到组织清晰、全面的 FSPMs 中。在未来的工作中,这种方法可以进一步扩展为面向方面的 FSPMs 编程语言。