source: trunk/omh/wish_list.omh @ 3674

Last change on this file since 3674 was 3674, checked in by bradbell, 5 years ago

merge to branch: trunk
from repository: https://github.com/coin-or/CppAD
start hash code: fe0bc2b6886b5fb80dc912dfb22e6c7f6e8c0545
end hash code: d54457d7204aae2cedec24a81bc6a97b1ec67d89

commit d54457d7204aae2cedec24a81bc6a97b1ec67d89
Author: Brad Bell <bradbell@…>
Date: Fri Apr 24 04:12:50 2015 -0700

wish_list.omh: add expm1 and log1p to wish list, remove some old spelling exceptions.

  • Property svn:keywords set to Id
File size: 8.4 KB
Line 
1$Id: wish_list.omh 3674 2015-04-24 11:14:21Z bradbell $
2/* --------------------------------------------------------------------------
3CppAD: C++ Algorithmic Differentiation: Copyright (C) 2003-15 Bradley M. Bell
4
5CppAD is distributed under multiple licenses. This distribution is under
6the terms of the
7                    Eclipse Public License Version 1.0.
8
9A copy of this license is included in the COPYING file of this distribution.
10Please visit http://www.coin-or.org/CppAD/ for information on other licenses.
11-------------------------------------------------------------------------- */
12$begin WishList$$
13$spell
14        Recomputation
15        expm
16        jacobian
17        nz
18        RevSparseJac
19        optimizer
20        Rel
21        Gt
22        Eq
23        CondExpLt
24        Checkpointing
25        grep
26        recomputed
27        afun
28        iterator
29        std
30        cos
31        Adolc
32        xml
33        hpp
34        CppAD
35        Atan
36        cppad
37        atanh
38        asinh
39        acosh
40$$
41
42$section The CppAD Wish List$$
43$index wish list$$
44$index new, features$$
45$index features, new$$
46
47$head Standard Math Functions$$
48The following functions are part of the C++11 standard math library
49and could be added to CppAD:
50$code atanh$$, $code asinh$$, $code acosh$$, $code expm1$$, $code log1p$$
51
52$subhead atan2$$
53The $cref/atan2/Atan2/$$ function could be made faster by adding
54a special operator for it.
55
56$head Adolc$$
57$index adolc$$
58Create a documentation page that shows how to convert Adolc commands to
59CppAD commands.
60
61$head BenderQuad$$
62See the $cref/problem/BenderQuad/Problem/$$ with the
63current $code BenderQuad$$ specifications.
64
65$head Checkpointing$$
66$index checkpoint$$
67It would be more flexible to also have a
68$cref/checkpoint constructor/checkpoint/constructor/$$
69that passed in an $cref ADFun$$ object instead of a algorithm.
70Perhaps the syntax would be
71$codei%
72        checkpoint %afun%(%name%, %ad_fun%, %copy%)
73%$$
74where $icode copy$$ would determine if a separate copy of $icode ad_fun$$
75was made or if a pointer was used.
76Note that if a pointer is used, it becomes invalid when the destructor
77for $icode ad_fun$$ is called.
78
79$head Conditional Expressions$$
80
81$subhead Nesting$$
82If one $cref/optimizes/optimize/$$ the code
83$codep
84        x = CondExpLt(left_x, right_x, true_x, false_x)
85        y = CondExpGt(left_y, right_y, true_y, false_y)
86        z = CondExpEq(left_z, right_z, x, y)
87$$
88only two of the expressions
89$code true_x$$, $code false_x$$, $code true_y$$, $code false_y$$
90will be evaluated
91(two will be skipped depending on the result of $code left_z == right_z$$).
92Not all of the expressions corresponding to
93$code left_x$$, $code right_x$$, $code left_y$$, $code right_y$$ need to be
94evaluate, but they are.
95The optimizer could be improved to skip two more expressions
96(depending on the result of $code left_z == right_z$$).
97
98$subhead Sparsity$$
99The $cref/optimizer/optimize/$$ uses
100$cref/atomic reverse jacobian sparsity/atomic_rev_sparse_jac/$$
101to determine which arguments affect the value of the results
102for the atomic functions (which include $cref checkpoint$$ functions).
103While the partials of
104$codei%
105        %z% = CondExp%Rel%( %left%, %right%, %if_true%, %if_false% )
106%$$
107with respect to $icode left$$ and $icode right$$ always evaluates to zero,
108the value of $icode z$$ does depend on the value of $icode left$$ and
109$icode right$$.
110The $cref checkpoint$$ functions use the value true for
111$cref/nz_compare/RevSparseJac/nz_compare/$$ when computing
112reverse jacobian sparsity patterns.
113This enables the optimizer to properly track the dependencies.
114An $cref atomic_option$$ should be added so this is only
115done when the optimizer is using the sparsity pattern for this purpose.
116
117$head Forward Mode Recomputation$$
118$index forward$$
119If the results of $cref forward_order$$ have already been computed and are still
120stored in the $cref ADFun$$ object (see $cref size_order$$),
121then they do not need to be recomputed and the results can just be returned.
122
123$head Iterator Interface$$
124$index iterator$$
125All of the CppAD simple vector interfaces should also have an
126iterator version for the following reasons:
127$list number$$
128It would not be necessary to copy information to simple vectors
129when it was originally stored in a different type of container.
130$lnext
131It would not be necessary to reallocate memory for a result that is
132repeatedly calculated
133(because an iterator for the result container would be passed in).
134$lend
135
136$head Library$$
137$index compile, speed AD<double>$$
138$index speed, compile AD<double>$$
139$index AD<double>, compile speed$$
140One could build a CppAD library for use with the type $code AD<double>$$.
141This would speed up compilation for the most common usage where
142the $icode Base$$ type is $code double$$.
143
144$head Multiple Directions$$
145$index speed, forward$$
146$index forward, speed$$
147$list number$$
148Extend the $cref forward_dir$$ routine so they can do multiple orders
149as well as multiple directions at the same time.
150$lnext
151Extend the $cref atomic$$ functions so they can use multiple directions
152and multiple orders at the same time
153(currently they compute one direction and one order at a time).
154$lnext
155Extend the $cref Reverse$$ routines so they can handle one reverse direction
156for multiple forward directions, or multiple reverse directions for
157one forward direction.
158$lend
159
160$head Numeric Limits$$
161$index testing, machine epsilon$$
162$index machine epsilon, testing$$
163Use a multiple of $code std::numeric_limits<double>::epsilon()$$ instead
164$code 1e-10$$ for a small number in correctness checks; e.g.,
165see $cref tan.cpp$$.
166
167$head Operation Sequence$$
168$index sequence, operation$$
169$index operation, sequence$$
170It is possible to detect if the
171AD of $icode Base$$
172$cref/operation sequence/glossary/Operation/Sequence/$$
173does not depend on any of the
174$cref/independent variable/glossary/Tape/Independent Variable/$$ values.
175This could be returned as an extra
176$cref seq_property$$.
177
178$head Optimization$$
179$index optimize, tape$$
180$index tape, optimize$$
181
182$subhead Comparison Changes$$
183The comparison operators used to not be taped when
184$cref/NDEBUG/Faq/Speed/NDEBUG/$$ was defined.
185They are now taped so that the $cref compare_change$$ interface
186works even for compiler optimize code.
187This caused a significant slow down in the
188$cref cppad_det_lu.cpp$$ speed test (with no options specified).
189Perhaps there should be an option to skip the comparison taping.
190
191$subhead Expression Hashing$$
192During expression sequence $cref/optimization/optimize/$$,
193hash codes are used to detect expressions that have already
194been computed.
195Perhaps this should be done during the original forward mode recording.
196
197$subhead Variable Pairs$$
198Suppose that $icode x$$ is a variable
199and $codei%sin(%x%)%$$ is used in an expression.
200The extra expression $codei%cos(%x%)%$$ is also computed
201during a $cref Forward$$ calculation.
202This is because the derivative of the original expression
203is expressed in terms of the values of the other expression.
204In general,
205the representation of the derivative of an expression to order $icode p$$
206may include the derivative of another expression to order $icode%p%-1%$$.
207In our example, if only the value $codei%sin(%x%)%$$
208is requested, it is not necessary to compute $codei%cos(%x%)%$$.
209We should remove the computation of extra expressions derivatives that are
210not need to compute the requested derivative of the original expression.
211
212$head Preprocessor Symbols$$
213$index preprocessor$$
214Make sure all the user API preprocessor symbols are list in
215the $cref preprocessor$$ section.
216
217$head Software Guidelines$$
218
219$subhead Boost$$
220The following is a list of some software guidelines taken from
221$href%http://www.boost.org/development/requirements.html#Guidelines%boost%$$.
222These guidelines are not followed by the current CppAD source code,
223but perhaps they should be:
224
225$list number$$
226Names (except as noted below)
227should be all lowercase, with words separated by underscores.
228For example, acronyms should be treated as ordinary names
229(xml_parser instead of XML_parser).
230
231$lnext
232Template parameter names should begin with an uppercase letter.
233
234$lnext
235Use spaces rather than tabs.
236Currently, CppAD uses a tabs stops at column multiples of 5.
237Five columns were chosen to avoid high levels of indenting and to allow for
238$codep
239        if( expression )
240                statement
241        else    statement
242$$
243with a tab after the else.
244Automatic conversion to actual spaces should be easy.
245
246$lend
247
248$head Tracing$$
249$index operation, sequence tracing$$
250$index sequence, operation tracing$$
251$index tracing, operation sequence$$
252Add tracing the operation sequence to the user API and documentation.
253Tracing the operation sequence is currently done by changing the CppAD
254source code. Use the command
255$codep
256        grep '^# *define *CPPAD_.*_TRACE' cppad/local/*.hpp
257$$
258to find all the possible tracing flags.
259
260$end
Note: See TracBrowser for help on using the repository browser.