Algorithm 746: PCOMP—a Fortran code for automatic differentiation

Algorithm 746: PCOMP—a Fortran code for automatic differentiation
复制标题

算法 746:PCOMP — 用于自动微分的 Fortran 代码

DOI:
--
复制
发表时间:
1995
期刊:
TOMS
影响因子:
--
通讯作者:
K. Schittkowski
K. Schittkowski
中科院分区:
--
文献类型:
--
作者:
M. Dobmann;M. Liepelt;K. Schittkowski

文献摘要

被引文献

相似文献

自动微分是所有需要导数的数值算法的有趣和重要的工具,例如,在非线性规划,最优控制,参数估计和微分方程。其基本思想是不仅要避免数值近似,这是昂贵的CPU时间,并包含舍入误差,但也手工编码的差异。本文介绍了前向和后向累加法,并描述了一个计算机程序PCCOMP的数值实现。所使用的方法的主要目的是提供一个灵活的和可移植的Fortran代码的实际应用。底层语言是用形式语法描述的,是Fortran的一个子集,有一些扩展。除了生成中间代码并且可以独立于评估例程执行的解析器之外,还有用于直接计算函数和梯度值的其他子例程,这些子例程可以直接从用户程序调用。另一方面,可以生成函数和梯度计算的Fortran代码,这些代码可以单独编译和链接。
Automatic differentiation is an interesting and important tool for all numerical algorithms that require derivatives, e.g., in nonlinear programming, optimal control, parameter estimation, and differential equations. The basic idea is to avoid not only numerical approximations, which are expensive with respect to CPU time and contain round-off errors, but also hand-coded differentiation. This article introduces the forward and backward accumulation methods and describes the numerical implementation of a computer code with the name PCOMP. The main intention of the approach used is to provide a flexible and portable Fortran code for practical applications. The underlying language is described in terms of a formal grammar and is a subset of Fortran with a few extensions. Besides a parser that generates an intermediate code and that can be executed independently from the evaluation routines, there are other subroutines for the direct computation of function and gradient values, which can be called directly from a user program. On the other hand, it is possible to generate a Fortran code for function and gradient evaluation that can be compiled and linked separately.