Codebase list cppad / debian/2017.00.00.8-1 doc / atomic_option.xml
debian/2017.00.00.8-1

Tree @debian/2017.00.00.8-1 (Download .tar.gz)

atomic_option.xml @debian/2017.00.00.8-1raw · history · blame

<?xml version='1.0'?>
<html xmlns='http://www.w3.org/1999/xhtml'
      xmlns:math='http://www.w3.org/1998/Math/MathML'
>
<head>
<title>Set Atomic Function Options</title>
<meta http-equiv='Content-Type' content='text/html' charset='utf-8'/>
<meta name="description" id="description" content="Set Atomic Function Options"/>
<meta name="keywords" id="keywords" content=" set atomic function options syntax atomic_sparsity pack_sparsity_enum bool_sparsity_enum set_sparsity_enum "/>
<style type='text/css'>
body { color : black }
body { background-color : white }
A:link { color : blue }
A:visited { color : purple }
A:active { color : purple }
</style>
<script type='text/javascript' language='JavaScript' src='_atomic_option_xml.js'>
</script>
</head>
<body>
<table><tr>
<td>
<a href="http://www.coin-or.org/CppAD/" target="_top"><img border="0" src="_image.gif"/></a>
</td>
<td><a href="atomic_ctor.xml" target="_top">Prev</a>
</td><td><a href="atomic_afun.xml" target="_top">Next</a>
</td><td>
<select onchange='choose_across0(this)'>
<option>Index-&gt;</option>
<option>contents</option>
<option>reference</option>
<option>index</option>
<option>search</option>
<option>external</option>
</select>
</td>
<td>
<select onchange='choose_up0(this)'>
<option>Up-&gt;</option>
<option>CppAD</option>
<option>AD</option>
<option>ADValued</option>
<option>atomic</option>
<option>atomic_base</option>
<option>atomic_option</option>
</select>
</td>
<td>
<select onchange='choose_down3(this)'>
<option>ADValued-&gt;</option>
<option>Arithmetic</option>
<option>unary_standard_math</option>
<option>binary_math</option>
<option>CondExp</option>
<option>Discrete</option>
<option>numeric_limits</option>
<option>atomic</option>
</select>
</td>
<td>
<select onchange='choose_down2(this)'>
<option>atomic-&gt;</option>
<option>checkpoint</option>
<option>atomic_base</option>
</select>
</td>
<td>
<select onchange='choose_down1(this)'>
<option>atomic_base-&gt;</option>
<option>atomic_ctor</option>
<option>atomic_option</option>
<option>atomic_afun</option>
<option>atomic_forward</option>
<option>atomic_reverse</option>
<option>atomic_for_sparse_jac</option>
<option>atomic_rev_sparse_jac</option>
<option>atomic_for_sparse_hes</option>
<option>atomic_rev_sparse_hes</option>
<option>atomic_base_clear</option>
<option>atomic_get_started.cpp</option>
<option>atomic_norm_sq.cpp</option>
<option>atomic_reciprocal.cpp</option>
<option>atomic_set_sparsity.cpp</option>
<option>atomic_tangent.cpp</option>
<option>atomic_eigen_mat_mul.cpp</option>
<option>atomic_eigen_mat_inv.cpp</option>
<option>atomic_eigen_cholesky.cpp</option>
<option>atomic_mat_mul.cpp</option>
</select>
</td>
<td>atomic_option</td>
<td>
<select onchange='choose_current0(this)'>
<option>Headings-&gt;</option>
<option>Syntax</option>
<option>atomic_sparsity</option>
<option>---..pack_sparsity_enum</option>
<option>---..bool_sparsity_enum</option>
<option>---..set_sparsity_enum</option>
</select>
</td>
</tr></table><br/>



<center><b><big><big>Set Atomic Function Options</big></big></b></center>
<br/>
<b><big><a name="Syntax" id="Syntax">Syntax</a></big></b>

<br/>

<code><i><font color="black"><span style='white-space: nowrap'>afun</span></font></i><font color="blue"><span style='white-space: nowrap'>.option(</span></font><i><font color="black"><span style='white-space: nowrap'>option_value</span></font></i><font color="blue"><span style='white-space: nowrap'>)</span></font></code>

These settings do not apply to individual 
<code><i><font color="black"><span style='white-space: nowrap'>afun</span></font></i></code>
 calls,
but rather all subsequent uses of the corresponding atomic operation
in an <a href="adfun.xml" target="_top"><span style='white-space: nowrap'>ADFun</span></a>
 object.

<br/>
<br/>
<b><big><a name="atomic_sparsity" id="atomic_sparsity">atomic_sparsity</a></big></b>
<br/>
Note that, if you use <a href="optimize.xml" target="_top"><span style='white-space: nowrap'>optimize</span></a>
, these sparsity patterns are used
to determine the <a href="dependency.cpp.xml" target="_top"><span style='white-space: nowrap'>dependency</span></a>
 relationship between
argument and result variables.

<br/>
<br/>
<b><a name="atomic_sparsity.pack_sparsity_enum" id="atomic_sparsity.pack_sparsity_enum">pack_sparsity_enum</a></b>
<br/>
If 
<code><i><font color="black"><span style='white-space: nowrap'>option_value</span></font></i></code>
 is 
<code><font color="blue"><span style='white-space: nowrap'>atomic_base&lt;</span></font><i><font color="black"><span style='white-space: nowrap'>Base</span></font></i><font color="blue"><span style='white-space: nowrap'>&gt;::pack_sparsity_enum</span></font></code>
,
then the type used by 
<code><i><font color="black"><span style='white-space: nowrap'>afun</span></font></i></code>
 for
<a href="glossary.xml#Sparsity Pattern" target="_top"><span style='white-space: nowrap'>sparsity&#xA0;patterns</span></a>
,
(after the option is set) will be

<code><font color="blue"><span style='white-space: nowrap'><br/>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;typedef&#xA0;CppAD::vectorBool&#xA0;</span></font><i><font color="black"><span style='white-space: nowrap'>atomic_sparsity</span></font></i><font color="blue"><span style='white-space: nowrap'><br/>
</span></font></code>
If 
<code><i><font color="black"><span style='white-space: nowrap'>r</span></font></i></code>
 is a sparsity pattern
for a matrix 
<math xmlns="http://www.w3.org/1998/Math/MathML" display="inline"><mrow>
<mi mathvariant='italic'>R</mi>
<mo stretchy="false">&#x02208;</mo>
<msup><mi mathvariant='italic'>B</mi>
<mrow><mi mathvariant='italic'>p</mi>
<mo stretchy="false">&#x000D7;</mo>
<mi mathvariant='italic'>q</mi>
</mrow>
</msup>
</mrow></math>

:

<code><i><font color="black"><span style='white-space: nowrap'>r</span></font></i><font color="blue"><span style='white-space: nowrap'>.size()&#xA0;==&#xA0;</span></font><i><font color="black"><span style='white-space: nowrap'>p</span></font></i><font color="blue"><span style='white-space: nowrap'>&#xA0;*&#xA0;</span></font><i><font color="black"><span style='white-space: nowrap'>q</span></font></i></code>
.

<br/>
<br/>
<b><a name="atomic_sparsity.bool_sparsity_enum" id="atomic_sparsity.bool_sparsity_enum">bool_sparsity_enum</a></b>
<br/>
If 
<code><i><font color="black"><span style='white-space: nowrap'>option_value</span></font></i></code>
 is 
<code><font color="blue"><span style='white-space: nowrap'>atomic_base&lt;</span></font><i><font color="black"><span style='white-space: nowrap'>Base</span></font></i><font color="blue"><span style='white-space: nowrap'>&gt;::bool_sparsity_enum</span></font></code>
,
then the type used by 
<code><i><font color="black"><span style='white-space: nowrap'>afun</span></font></i></code>
 for
<a href="glossary.xml#Sparsity Pattern" target="_top"><span style='white-space: nowrap'>sparsity&#xA0;patterns</span></a>
,
(after the option is set) will be

<code><font color="blue"><span style='white-space: nowrap'><br/>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;typedef&#xA0;CppAD::vector&lt;bool&gt;&#xA0;</span></font><i><font color="black"><span style='white-space: nowrap'>atomic_sparsity</span></font></i><font color="blue"><span style='white-space: nowrap'><br/>
</span></font></code>
If 
<code><i><font color="black"><span style='white-space: nowrap'>r</span></font></i></code>
 is a sparsity pattern
for a matrix 
<math xmlns="http://www.w3.org/1998/Math/MathML" display="inline"><mrow>
<mi mathvariant='italic'>R</mi>
<mo stretchy="false">&#x02208;</mo>
<msup><mi mathvariant='italic'>B</mi>
<mrow><mi mathvariant='italic'>p</mi>
<mo stretchy="false">&#x000D7;</mo>
<mi mathvariant='italic'>q</mi>
</mrow>
</msup>
</mrow></math>

:

<code><i><font color="black"><span style='white-space: nowrap'>r</span></font></i><font color="blue"><span style='white-space: nowrap'>.size()&#xA0;==&#xA0;</span></font><i><font color="black"><span style='white-space: nowrap'>p</span></font></i><font color="blue"><span style='white-space: nowrap'>&#xA0;*&#xA0;</span></font><i><font color="black"><span style='white-space: nowrap'>q</span></font></i></code>
.

<br/>
<br/>
<b><a name="atomic_sparsity.set_sparsity_enum" id="atomic_sparsity.set_sparsity_enum">set_sparsity_enum</a></b>
<br/>
If 
<code><i><font color="black"><span style='white-space: nowrap'>option_value</span></font></i></code>
 is 
<code><i><font color="black"><span style='white-space: nowrap'>atomic_base&lt;</span></font></i><font color="blue"><span style='white-space: nowrap'>Base</span></font><i><font color="black"><span style='white-space: nowrap'>&gt;::set_sparsity_enum</span></font></i></code>
,
then the type used by 
<code><i><font color="black"><span style='white-space: nowrap'>afun</span></font></i></code>
 for
<a href="glossary.xml#Sparsity Pattern" target="_top"><span style='white-space: nowrap'>sparsity&#xA0;patterns</span></a>
,
(after the option is set) will be

<code><font color="blue"><span style='white-space: nowrap'><br/>
&#xA0;&#xA0;&#xA0;&#xA0;&#xA0;typedef&#xA0;CppAD::vector&lt;&#xA0;std::set&lt;size_t&gt;&#xA0;&gt;&#xA0;</span></font><i><font color="black"><span style='white-space: nowrap'>atomic_sparsity</span></font></i><font color="blue"><span style='white-space: nowrap'><br/>
</span></font></code>
If 
<code><i><font color="black"><span style='white-space: nowrap'>r</span></font></i></code>
 is a sparsity pattern
for a matrix 
<math xmlns="http://www.w3.org/1998/Math/MathML" display="inline"><mrow>
<mi mathvariant='italic'>R</mi>
<mo stretchy="false">&#x02208;</mo>
<msup><mi mathvariant='italic'>B</mi>
<mrow><mi mathvariant='italic'>p</mi>
<mo stretchy="false">&#x000D7;</mo>
<mi mathvariant='italic'>q</mi>
</mrow>
</msup>
</mrow></math>

:

<code><i><font color="black"><span style='white-space: nowrap'>r</span></font></i><font color="blue"><span style='white-space: nowrap'>.size()&#xA0;==&#xA0;</span></font><i><font color="black"><span style='white-space: nowrap'>p</span></font></i></code>
, and for 
<math xmlns="http://www.w3.org/1998/Math/MathML" display="inline"><mrow>
<mi mathvariant='italic'>i</mi>
<mo stretchy="false">=</mo>
<mn>0</mn>
<mo stretchy="false">,</mo>
<mo stretchy="false">&#x02026;</mo>
<mo stretchy="false">,</mo>
<mi mathvariant='italic'>p</mi>
<mn>-1</mn>
</mrow></math>

,
the elements of 
<code><i><font color="black"><span style='white-space: nowrap'>r</span></font></i><font color="blue"><span style='white-space: nowrap'>[</span></font><i><font color="black"><span style='white-space: nowrap'>i</span></font></i><font color="blue"><span style='white-space: nowrap'>]</span></font></code>
 are between zero and 
<math xmlns="http://www.w3.org/1998/Math/MathML" display="inline"><mrow>
<mi mathvariant='italic'>q</mi>
<mn>-1</mn>
</mrow></math>

 inclusive.


<hr/>Input File: cppad/core/atomic_base.hpp

</body>
</html>