1 | <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> |
---|
2 | <html xmlns="http://www.w3.org/1999/xhtml"> |
---|
3 | <head> |
---|
4 | <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> |
---|
5 | <title>mixpp: discrete.h Source File</title> |
---|
6 | <link href="tabs.css" rel="stylesheet" type="text/css"/> |
---|
7 | <link href="doxygen.css" rel="stylesheet" type="text/css"/> |
---|
8 | </head> |
---|
9 | <body> |
---|
10 | <!-- Generated by Doxygen 1.6.1 --> |
---|
11 | <script type="text/javascript"> |
---|
12 | <!-- |
---|
13 | function changeDisplayState (e){ |
---|
14 | var num=this.id.replace(/[^[0-9]/g,''); |
---|
15 | var button=this.firstChild; |
---|
16 | var sectionDiv=document.getElementById('dynsection'+num); |
---|
17 | if (sectionDiv.style.display=='none'||sectionDiv.style.display==''){ |
---|
18 | sectionDiv.style.display='block'; |
---|
19 | button.src='open.gif'; |
---|
20 | }else{ |
---|
21 | sectionDiv.style.display='none'; |
---|
22 | button.src='closed.gif'; |
---|
23 | } |
---|
24 | } |
---|
25 | function initDynSections(){ |
---|
26 | var divs=document.getElementsByTagName('div'); |
---|
27 | var sectionCounter=1; |
---|
28 | for(var i=0;i<divs.length-1;i++){ |
---|
29 | if(divs[i].className=='dynheader'&&divs[i+1].className=='dynsection'){ |
---|
30 | var header=divs[i]; |
---|
31 | var section=divs[i+1]; |
---|
32 | var button=header.firstChild; |
---|
33 | if (button!='IMG'){ |
---|
34 | divs[i].insertBefore(document.createTextNode(' '),divs[i].firstChild); |
---|
35 | button=document.createElement('img'); |
---|
36 | divs[i].insertBefore(button,divs[i].firstChild); |
---|
37 | } |
---|
38 | header.style.cursor='pointer'; |
---|
39 | header.onclick=changeDisplayState; |
---|
40 | header.id='dynheader'+sectionCounter; |
---|
41 | button.src='closed.gif'; |
---|
42 | section.id='dynsection'+sectionCounter; |
---|
43 | section.style.display='none'; |
---|
44 | section.style.marginLeft='14px'; |
---|
45 | sectionCounter++; |
---|
46 | } |
---|
47 | } |
---|
48 | } |
---|
49 | window.onload = initDynSections; |
---|
50 | --> |
---|
51 | </script> |
---|
52 | <div class="navigation" id="top"> |
---|
53 | <div class="tabs"> |
---|
54 | <ul> |
---|
55 | <li><a href="main.html"><span>Main Page</span></a></li> |
---|
56 | <li><a href="pages.html"><span>Related Pages</span></a></li> |
---|
57 | <li><a href="annotated.html"><span>Classes</span></a></li> |
---|
58 | <li class="current"><a href="files.html"><span>Files</span></a></li> |
---|
59 | </ul> |
---|
60 | </div> |
---|
61 | <div class="tabs"> |
---|
62 | <ul> |
---|
63 | <li><a href="files.html"><span>File List</span></a></li> |
---|
64 | <li><a href="globals.html"><span>File Members</span></a></li> |
---|
65 | </ul> |
---|
66 | </div> |
---|
67 | <h1>discrete.h</h1><a href="discrete_8h.html">Go to the documentation of this file.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 |
---|
68 | <a name="l00013"></a>00013 <span class="preprocessor">#ifndef DISCR_H</span> |
---|
69 | <a name="l00014"></a>00014 <span class="preprocessor"></span><span class="preprocessor">#define DISCR_H</span> |
---|
70 | <a name="l00015"></a>00015 <span class="preprocessor"></span> |
---|
71 | <a name="l00016"></a>00016 |
---|
72 | <a name="l00017"></a>00017 <span class="preprocessor">#include "../shared_ptr.h"</span> |
---|
73 | <a name="l00018"></a>00018 <span class="preprocessor">#include "../base/bdmbase.h"</span> |
---|
74 | <a name="l00019"></a>00019 <span class="preprocessor">#include "../math/chmat.h"</span> |
---|
75 | <a name="l00020"></a>00020 |
---|
76 | <a name="l00021"></a>00021 <span class="keyword">namespace </span>bdm { |
---|
77 | <a name="l00022"></a>00022 |
---|
78 | <a name="l00026"></a><a class="code" href="classbdm_1_1rectangular__support.html">00026</a> <span class="keyword">class </span><a class="code" href="classbdm_1_1rectangular__support.html">rectangular_support</a>: <span class="keyword">public</span> <a class="code" href="classbdm_1_1root.html" title="Root class of BDM objects.">root</a> { |
---|
79 | <a name="l00027"></a>00027 <span class="keyword">protected</span>: |
---|
80 | <a name="l00029"></a><a class="code" href="classbdm_1_1rectangular__support.html#ab63e1190a8a22031d110624a8fc64b14">00029</a> Array<vec> <a class="code" href="classbdm_1_1rectangular__support.html#ab63e1190a8a22031d110624a8fc64b14" title="Array of boundaries (2D vectors: [begining,end]) for each dimension.">ranges</a>; |
---|
81 | <a name="l00031"></a><a class="code" href="classbdm_1_1rectangular__support.html#aefe08427f4bf66191e10b727b57e4b31">00031</a> ivec <a class="code" href="classbdm_1_1rectangular__support.html#aefe08427f4bf66191e10b727b57e4b31" title="Number of support points in each dimension.">gridsizes</a>; |
---|
82 | <a name="l00033"></a><a class="code" href="classbdm_1_1rectangular__support.html#a442ae2e1881d6bcdccf0cabbef769e79">00033</a> <span class="keywordtype">int</span> <a class="code" href="classbdm_1_1rectangular__support.html#a442ae2e1881d6bcdccf0cabbef769e79" title="dimension">dim</a>; |
---|
83 | <a name="l00035"></a><a class="code" href="classbdm_1_1rectangular__support.html#a6e55e6243f3a3e451f8bed149d948319">00035</a> <span class="keywordtype">int</span> <a class="code" href="classbdm_1_1rectangular__support.html#a6e55e6243f3a3e451f8bed149d948319" title="Number of data points.">Npoints</a>; |
---|
84 | <a name="l00037"></a><a class="code" href="classbdm_1_1rectangular__support.html#ae1aa9a4e91c248a29e4e432f4b448197">00037</a> vec <a class="code" href="classbdm_1_1rectangular__support.html#ae1aa9a4e91c248a29e4e432f4b448197" title="active vector for first_vec and next_vec">actvec</a>; |
---|
85 | <a name="l00039"></a><a class="code" href="classbdm_1_1rectangular__support.html#a744688479a1ab8cf9f80d6f3021d762b">00039</a> vec <a class="code" href="classbdm_1_1rectangular__support.html#a744688479a1ab8cf9f80d6f3021d762b" title="indeces of active vector">actvec_ind</a>; |
---|
86 | <a name="l00041"></a><a class="code" href="classbdm_1_1rectangular__support.html#a967bfe2eb868409e3e0e6e41dcd63a6a">00041</a> vec <a class="code" href="classbdm_1_1rectangular__support.html#a967bfe2eb868409e3e0e6e41dcd63a6a" title="length of steps in each dimension">steps</a>; |
---|
87 | <a name="l00042"></a>00042 <span class="keyword">public</span>: |
---|
88 | <a name="l00044"></a><a class="code" href="classbdm_1_1rectangular__support.html#a9929645efe5eff3a6b87da8b81e114c4">00044</a> <a class="code" href="classbdm_1_1rectangular__support.html#a9929645efe5eff3a6b87da8b81e114c4" title="default constructor">rectangular_support</a>() : <a class="code" href="classbdm_1_1rectangular__support.html#a442ae2e1881d6bcdccf0cabbef769e79" title="dimension">dim</a> ( 0 ), <a class="code" href="classbdm_1_1rectangular__support.html#a6e55e6243f3a3e451f8bed149d948319" title="Number of data points.">Npoints</a> ( 0 ) { |
---|
89 | <a name="l00045"></a>00045 } |
---|
90 | <a name="l00046"></a>00046 |
---|
91 | <a name="l00048"></a>00048 <span class="keywordtype">void</span> <a class="code" href="classbdm_1_1rectangular__support.html#aa18272405534f914ee3798f1c4034e51" title="set parameters">set_parameters</a> ( <span class="keyword">const</span> Array<vec> &ranges0, <span class="keyword">const</span> ivec &gridsize0 ); |
---|
92 | <a name="l00049"></a>00049 |
---|
93 | <a name="l00051"></a>00051 <span class="keywordtype">void</span> <a class="code" href="classbdm_1_1rectangular__support.html#adeaab6ec24371267da14de05963c5092" title="Internal functio to set temporaries correctly.">initialize</a>(); |
---|
94 | <a name="l00052"></a>00052 |
---|
95 | <a name="l00054"></a>00054 vec <a class="code" href="classbdm_1_1rectangular__support.html#a2fd69b881ff077e6d3da3e453d7dc418" title="return vector at position given by vector of indeces">get_vec</a> ( <span class="keyword">const</span> ivec &inds ); |
---|
96 | <a name="l00055"></a>00055 |
---|
97 | <a name="l00057"></a>00057 <span class="keywordtype">long</span> <a class="code" href="classbdm_1_1rectangular__support.html#a2ae8ed78cba8e14b5dcc570b51d7d3f0" title="convert dimension indeces into linear index, the indexing is in the same way as in...">linear_index</a> ( <span class="keyword">const</span> ivec inds ); |
---|
98 | <a name="l00058"></a>00058 |
---|
99 | <a name="l00060"></a>00060 <span class="keyword">const</span> vec& <a class="code" href="classbdm_1_1rectangular__support.html#a6a1d6c127b468b772fd0a7206e2880a3" title="set the first vector to corner and store result in actvec">first_vec</a>(); |
---|
100 | <a name="l00061"></a>00061 |
---|
101 | <a name="l00063"></a>00063 <span class="keyword">const</span> vec& <a class="code" href="classbdm_1_1rectangular__support.html#a80f33e406ba1799376537c39fdf7cc97" title="Get next active vector, call ONLY after first_vector()!">next_vec</a>(); |
---|
102 | <a name="l00064"></a>00064 |
---|
103 | <a name="l00066"></a>00066 ivec <a class="code" href="classbdm_1_1rectangular__support.html#a0ea90fd6ba65251683c04599b6d094b7">nearest_point</a> ( <span class="keyword">const</span> vec &val ); |
---|
104 | <a name="l00067"></a>00067 |
---|
105 | <a name="l00069"></a><a class="code" href="classbdm_1_1rectangular__support.html#aa2cc3a7250b969675bc8f9034aa2a7d2">00069</a> <span class="keywordtype">int</span> <a class="code" href="classbdm_1_1rectangular__support.html#aa2cc3a7250b969675bc8f9034aa2a7d2" title="Access function.">points</a>()<span class="keyword"> const </span>{ |
---|
106 | <a name="l00070"></a>00070 <span class="keywordflow">return</span> <a class="code" href="classbdm_1_1rectangular__support.html#a6e55e6243f3a3e451f8bed149d948319" title="Number of data points.">Npoints</a>; |
---|
107 | <a name="l00071"></a>00071 } |
---|
108 | <a name="l00072"></a>00072 |
---|
109 | <a name="l00075"></a><a class="code" href="classbdm_1_1rectangular__support.html#acfd542382bc959fce9c117b8df5f6e9f">00075</a> <span class="keyword">const</span> vec& <a class="code" href="classbdm_1_1rectangular__support.html#acfd542382bc959fce9c117b8df5f6e9f">_steps</a>()<span class="keyword"> const </span>{ |
---|
110 | <a name="l00076"></a>00076 <span class="keywordflow">return</span> <a class="code" href="classbdm_1_1rectangular__support.html#a967bfe2eb868409e3e0e6e41dcd63a6a" title="length of steps in each dimension">steps</a>; |
---|
111 | <a name="l00077"></a>00077 } |
---|
112 | <a name="l00078"></a>00078 |
---|
113 | <a name="l00079"></a>00079 <span class="keywordtype">void</span> <a class="code" href="classbdm_1_1rectangular__support.html#ac8d82bd237cdd4dc50d5fbcc285d80ee" title="This method arrange instance properties according the data stored in the Setting...">from_setting</a> ( <span class="keyword">const</span> Setting &<span class="keyword">set</span> ); |
---|
114 | <a name="l00080"></a>00080 }; |
---|
115 | <a name="l00081"></a>00081 <a class="code" href="user__info_8h.html#a4f9de2f17e844047726487b99def99c6" title="Macro for registration of class into map of user-infos, registered class is scriptable...">UIREGISTER</a> ( rectangular_support ); |
---|
116 | <a name="l00082"></a>00082 |
---|
117 | <a name="l00084"></a><a class="code" href="classbdm_1_1discrete__support.html">00084</a> <span class="keyword">class </span><a class="code" href="classbdm_1_1discrete__support.html" title="Discrete support with stored support points.">discrete_support</a>: <span class="keyword">public</span> <a class="code" href="classbdm_1_1root.html" title="Root class of BDM objects.">root</a> { |
---|
118 | <a name="l00085"></a>00085 <span class="keyword">protected</span>: |
---|
119 | <a name="l00087"></a><a class="code" href="classbdm_1_1discrete__support.html#ac0cbdb61727406b52ca22332507a9a7c">00087</a> Array<vec> <a class="code" href="classbdm_1_1discrete__support.html#ac0cbdb61727406b52ca22332507a9a7c" title="storage of support points">Spoints</a>; |
---|
120 | <a name="l00089"></a><a class="code" href="classbdm_1_1discrete__support.html#a505284848af521fea33e65368de4845e">00089</a> <span class="keywordtype">int</span> <a class="code" href="classbdm_1_1discrete__support.html#a505284848af521fea33e65368de4845e" title="index in iterators">idx</a>; |
---|
121 | <a name="l00090"></a>00090 <span class="keyword">public</span>: |
---|
122 | <a name="l00092"></a><a class="code" href="classbdm_1_1discrete__support.html#a58d652a1f149a7698f1fee9acd1a78b5">00092</a> <a class="code" href="classbdm_1_1discrete__support.html#a58d652a1f149a7698f1fee9acd1a78b5" title="Default constructor.">discrete_support</a>() : <a class="code" href="classbdm_1_1discrete__support.html#ac0cbdb61727406b52ca22332507a9a7c" title="storage of support points">Spoints</a> ( 0 ), <a class="code" href="classbdm_1_1discrete__support.html#a505284848af521fea33e65368de4845e" title="index in iterators">idx</a> ( 0 ) {} |
---|
123 | <a name="l00094"></a><a class="code" href="classbdm_1_1discrete__support.html#adc3d175266b65168ba3f3a5f568078a1">00094</a> <span class="keywordtype">int</span> <a class="code" href="classbdm_1_1discrete__support.html#adc3d175266b65168ba3f3a5f568078a1" title="Access function.">points</a>()<span class="keyword"> const </span>{ |
---|
124 | <a name="l00095"></a>00095 <span class="keywordflow">return</span> <a class="code" href="classbdm_1_1discrete__support.html#ac0cbdb61727406b52ca22332507a9a7c" title="storage of support points">Spoints</a>.length(); |
---|
125 | <a name="l00096"></a>00096 } |
---|
126 | <a name="l00098"></a><a class="code" href="classbdm_1_1discrete__support.html#a26c803791b63916adf301a4a186f01ba">00098</a> <span class="keyword">const</span> vec& <a class="code" href="classbdm_1_1discrete__support.html#a26c803791b63916adf301a4a186f01ba" title="set the first vector to corner and store result in actvec">first_vec</a>() { |
---|
127 | <a name="l00099"></a>00099 <a class="code" href="bdmerror_8h.html#a89a0f906b242b79c5d3d342291b2cab4" title="Throw std::runtime_exception if t is not true and NDEBUG is not defined.">bdm_assert_debug</a> ( <a class="code" href="classbdm_1_1discrete__support.html#ac0cbdb61727406b52ca22332507a9a7c" title="storage of support points">Spoints</a>.length() > 0, <span class="stringliteral">"Empty support"</span> ); |
---|
128 | <a name="l00100"></a>00100 <a class="code" href="classbdm_1_1discrete__support.html#a505284848af521fea33e65368de4845e" title="index in iterators">idx</a> = 0; |
---|
129 | <a name="l00101"></a>00101 <span class="keywordflow">return</span> <a class="code" href="classbdm_1_1discrete__support.html#ac0cbdb61727406b52ca22332507a9a7c" title="storage of support points">Spoints</a> ( idx ); |
---|
130 | <a name="l00102"></a>00102 } |
---|
131 | <a name="l00104"></a><a class="code" href="classbdm_1_1discrete__support.html#a368f10fd45443dee5296cc0febb240fb">00104</a> <span class="keyword">const</span> vec& <a class="code" href="classbdm_1_1discrete__support.html#a368f10fd45443dee5296cc0febb240fb" title="set next vector after calling first_vec()">next_vec</a>() { |
---|
132 | <a name="l00105"></a>00105 <a class="code" href="bdmerror_8h.html#a89a0f906b242b79c5d3d342291b2cab4" title="Throw std::runtime_exception if t is not true and NDEBUG is not defined.">bdm_assert_debug</a> ( <a class="code" href="classbdm_1_1discrete__support.html#ac0cbdb61727406b52ca22332507a9a7c" title="storage of support points">Spoints</a>.length() > <a class="code" href="classbdm_1_1discrete__support.html#a505284848af521fea33e65368de4845e" title="index in iterators">idx</a> - 1, <span class="stringliteral">"Out of support points"</span> ); |
---|
133 | <a name="l00106"></a>00106 <span class="keywordflow">return</span> <a class="code" href="classbdm_1_1discrete__support.html#ac0cbdb61727406b52ca22332507a9a7c" title="storage of support points">Spoints</a> ( ++<a class="code" href="classbdm_1_1discrete__support.html#a505284848af521fea33e65368de4845e" title="index in iterators">idx</a> ); |
---|
134 | <a name="l00107"></a>00107 } |
---|
135 | <a name="l00108"></a>00108 |
---|
136 | <a name="l00118"></a>00118 <span class="keywordtype">void</span> <a class="code" href="classbdm_1_1discrete__support.html#a0c405889b7b76f0852c1b2a222f07aab">from_setting</a> ( <span class="keyword">const</span> Setting &<span class="keyword">set</span> ); |
---|
137 | <a name="l00119"></a>00119 |
---|
138 | <a name="l00121"></a><a class="code" href="classbdm_1_1discrete__support.html#a1e9af8da7fa2ac2c03b3cec1d4407b1d">00121</a> Array<vec> & <a class="code" href="classbdm_1_1discrete__support.html#a1e9af8da7fa2ac2c03b3cec1d4407b1d" title="access function">_Spoints</a>() { |
---|
139 | <a name="l00122"></a>00122 <span class="keywordflow">return</span> <a class="code" href="classbdm_1_1discrete__support.html#ac0cbdb61727406b52ca22332507a9a7c" title="storage of support points">Spoints</a>; |
---|
140 | <a name="l00123"></a>00123 } |
---|
141 | <a name="l00124"></a>00124 }; |
---|
142 | <a name="l00125"></a>00125 <a class="code" href="user__info_8h.html#a4f9de2f17e844047726487b99def99c6" title="Macro for registration of class into map of user-infos, registered class is scriptable...">UIREGISTER</a> ( discrete_support ); |
---|
143 | <a name="l00126"></a>00126 |
---|
144 | <a name="l00127"></a><a class="code" href="classbdm_1_1grid__fnc.html">00127</a> <span class="keyword">class </span><a class="code" href="classbdm_1_1grid__fnc.html">grid_fnc</a>: <span class="keyword">public</span> <a class="code" href="classbdm_1_1fnc.html" title="Class representing function of variable represented by rv.">fnc</a> { |
---|
145 | <a name="l00128"></a>00128 <span class="keyword">protected</span>: |
---|
146 | <a name="l00129"></a>00129 <a class="code" href="classbdm_1_1rectangular__support.html">rectangular_support</a> sup; |
---|
147 | <a name="l00130"></a>00130 vec values; |
---|
148 | <a name="l00131"></a>00131 <span class="keyword">public</span>: |
---|
149 | <a name="l00133"></a><a class="code" href="classbdm_1_1grid__fnc.html#ab694d146aa19a9801628c105a29ac8bf">00133</a> <span class="keywordtype">void</span> <a class="code" href="classbdm_1_1grid__fnc.html#ab694d146aa19a9801628c105a29ac8bf" title="constructor function">set_support</a> ( <a class="code" href="classbdm_1_1rectangular__support.html">rectangular_support</a> &sup0 ) { |
---|
150 | <a name="l00134"></a>00134 sup = sup0; |
---|
151 | <a name="l00135"></a>00135 values = zeros ( sup.<a class="code" href="classbdm_1_1rectangular__support.html#aa2cc3a7250b969675bc8f9034aa2a7d2" title="Access function.">points</a>() ); |
---|
152 | <a name="l00136"></a>00136 } |
---|
153 | <a name="l00138"></a>00138 <span class="keywordtype">void</span> <a class="code" href="classbdm_1_1grid__fnc.html#acd5fc88472c67e2ddafd3e3dfa5859c0" title="constructor function fills values by calling function f , double f(vec&amp;), given...">set_values</a> ( <span class="keywordtype">double</span> ( *evalptr ) ( <span class="keyword">const</span> vec& ) ); |
---|
154 | <a name="l00139"></a>00139 |
---|
155 | <a name="l00141"></a><a class="code" href="classbdm_1_1grid__fnc.html#a8fb871dcc27b0ac4ba6d2eae3ea484ea">00141</a> <span class="keywordtype">double</span> <a class="code" href="classbdm_1_1grid__fnc.html#a8fb871dcc27b0ac4ba6d2eae3ea484ea" title="get value nearest to the given point">nearest_val</a> ( <span class="keyword">const</span> vec &val ) { |
---|
156 | <a name="l00142"></a>00142 <span class="keywordflow">return</span> values ( sup.<a class="code" href="classbdm_1_1rectangular__support.html#a2ae8ed78cba8e14b5dcc570b51d7d3f0" title="convert dimension indeces into linear index, the indexing is in the same way as in...">linear_index</a> ( sup.<a class="code" href="classbdm_1_1rectangular__support.html#a0ea90fd6ba65251683c04599b6d094b7">nearest_point</a> ( val ) ) ); |
---|
157 | <a name="l00143"></a>00143 } |
---|
158 | <a name="l00144"></a>00144 |
---|
159 | <a name="l00145"></a><a class="code" href="classbdm_1_1grid__fnc.html#a8814bad6ae13a11f288e9ad06ef48ee5">00145</a> vec <a class="code" href="classbdm_1_1grid__fnc.html#a8814bad6ae13a11f288e9ad06ef48ee5" title="function evaluates numerical value of at cond ">eval</a> ( <span class="keyword">const</span> vec &val ) { |
---|
160 | <a name="l00146"></a>00146 <span class="keywordflow">return</span> vec_1 ( <a class="code" href="classbdm_1_1grid__fnc.html#a8fb871dcc27b0ac4ba6d2eae3ea484ea" title="get value nearest to the given point">nearest_val</a> ( val ) ); |
---|
161 | <a name="l00147"></a>00147 } |
---|
162 | <a name="l00148"></a>00148 }; |
---|
163 | <a name="l00149"></a>00149 <a class="code" href="user__info_8h.html#a4f9de2f17e844047726487b99def99c6" title="Macro for registration of class into map of user-infos, registered class is scriptable...">UIREGISTER</a> ( grid_fnc ); |
---|
164 | <a name="l00150"></a>00150 |
---|
165 | <a name="l00154"></a><a class="code" href="classbdm_1_1egrid.html">00154</a> <span class="keyword">class </span><a class="code" href="classbdm_1_1egrid.html">egrid</a>: <span class="keyword">public</span> <a class="code" href="classbdm_1_1epdf.html" title="Probability density function with numerical statistics, e.g. posterior density.">epdf</a> { |
---|
166 | <a name="l00155"></a>00155 <span class="keyword">protected</span>: |
---|
167 | <a name="l00156"></a>00156 <a class="code" href="classbdm_1_1rectangular__support.html">rectangular_support</a> sup; |
---|
168 | <a name="l00157"></a>00157 vec values; |
---|
169 | <a name="l00158"></a>00158 <span class="keyword">public</span>: |
---|
170 | <a name="l00160"></a><a class="code" href="classbdm_1_1egrid.html#a3a9f0d4f725b189b08990c5997aa57ae">00160</a> <span class="keywordtype">double</span> <a class="code" href="classbdm_1_1egrid.html#a3a9f0d4f725b189b08990c5997aa57ae" title="we assume that evallog is not called too often otherwise we should cache log(values)...">evallog</a> ( <span class="keyword">const</span> vec &val ) { |
---|
171 | <a name="l00161"></a>00161 <span class="keywordflow">return</span> log ( values ( sup.<a class="code" href="classbdm_1_1rectangular__support.html#a2ae8ed78cba8e14b5dcc570b51d7d3f0" title="convert dimension indeces into linear index, the indexing is in the same way as in...">linear_index</a> ( sup.<a class="code" href="classbdm_1_1rectangular__support.html#a0ea90fd6ba65251683c04599b6d094b7">nearest_point</a> ( val ) ) ) ); |
---|
172 | <a name="l00162"></a>00162 } |
---|
173 | <a name="l00163"></a>00163 |
---|
174 | <a name="l00164"></a>00164 }; |
---|
175 | <a name="l00165"></a>00165 } |
---|
176 | <a name="l00166"></a>00166 <span class="preprocessor">#endif //DISCR_H</span> |
---|
177 | </pre></div></div> |
---|
178 | <hr size="1"/><address style="text-align: right;"><small>Generated on Mon Oct 12 19:37:19 2009 for mixpp by |
---|
179 | <a href="http://www.doxygen.org/index.html"> |
---|
180 | <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.6.1 </small></address> |
---|
181 | </body> |
---|
182 | </html> |
---|