PETE: The Portable Expression Template Engine
By Scott Haney, James Crotinger, Steve Karmesin and and Stephen Smith, October 01, 1999
PETE, short for "Portable Expression Template Engine," is a C++ framework that lets users easily add expression-template functionality to container classes and perform complex expression manipulations.
Oct99: Programmer's Toolchest
vector<double>::iterator iterA = A.begin();
vector<int>::const_iterator iterB = B.begin();
vector<double>::const_iterator iterC = C.begin();
while (iterA != A.end())
{
*iterA += -*iterB + 2 * *iterC;
++iterA; ++iterB; ++iterC;
}
Example 1: Efficient evaluation of A += -B + 2 * C.
Copyright © 1999, Dr. Dobb's Journal