假定已經(jīng)有許多應(yīng)用采用了程序1 - 1 5中所定義的C u r r e n c y類,現(xiàn)在我們想要對(duì)C u r r e n c y類
的描述進(jìn)行修改,使其應(yīng)用頻率最高的兩個(gè)函數(shù)A d d和I n c r e m e n t可以運(yùn)行得更快,從而提高應(yīng)
用程序的執(zhí)行速度。由于用戶僅能通過(guò)p u b l i c部分所提供的接口與C u r r e n c y類進(jìn)行交互,
% A 2D homogeneous convection-diffusion case (u=exp(-ex*deta*x-ex*deta*y) with a square with
% all Dirichlet boundary, note that reaction coefficient is not zero
% by indirect BKM
A 2D homogeneous Helmholtz case (u=sin(x)cos(y) with a square) with
% two Dirichlet edges (x=1,y=1) and two Neumann edges (x=0,y=0)
% by indirect symmetric BKM