<div>Hi, Andreas</div>
<div>&nbsp;</div>
<div>Could you actually provide one example which uses automatic differentiation to give the first and second direvatives with ampl external function?</div>
<div>&nbsp;</div>
<div>Another question coming into my mind is: </div>
<div>Does that mean I don&#39;t need code to calculate the value of the integration function, instead, I just need to code to calculate the first and second direvatives?</div>
<div>&nbsp;</div>
<div>Again, if you can give me the example you mentioned in your email, I would appreciate it very much.</div>
<div>&nbsp;</div>
<div>Best</div>
<div>&nbsp;</div>
<div>Roy<br><br>&nbsp;</div>
<div><span class="gmail_quote">On 3/2/07, <b class="gmail_sendername">Andreas Waechter</b> &lt;<a href="mailto:andreasw@watson.ibm.com">andreasw@watson.ibm.com</a>&gt; wrote:</span>
<blockquote class="gmail_quote" style="PADDING-LEFT: 1ex; MARGIN: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">Hi Roy,<br><br>&gt; What I am sure is my code could just calculate the value of the integration<br>&gt; function and it doesn&#39;t provide the first and second direvatives. Does this
<br>&gt; explain why Bonmin couldn&#39;t work with my external function? But why Bonmin<br>&gt; couldn&#39;t load amplfunc.dll file? Does it have something to do with the first<br>&gt; and second direvative?<br><br>I would think so.&nbsp;&nbsp;The Ampl Solver Library (ASL) that is linked into
<br>Bonmin knows that first and second derivatives are provided, and I would<br>think that this explains why it refuses to load your amplfunc.dll.<br><br>If you want to use bonmin with your external function, you need to somehow
<br>provide the derivatives.&nbsp;&nbsp;One avenue might be to use automatic<br>differentiation (I have used ADOL-C in that context before when we had an<br>external function that is computed by code that only provided the function
<br>value).&nbsp;&nbsp;However, that probably won&#39;t work if you are actually integrating<br>something (where you have lots of &quot;if&quot; statements in your code which are<br>not nice for automatic differentiation methods...).
<br><br>&gt; I will try IPOPT soon and give you the result soon.<br><br>If you already know that your DLL doesn&#39;t provide those derivatives, ipopt<br>won&#39;t work either.<br><br>Regards,<br><br>Andreas<br></blockquote>
</div><br>