https://software.intel.com/en-us/forums/topic/356291/feed
enHi Andrey,
https://software.intel.com/en-us/comment/1721031#comment-1721031
<a id="comment-1721031"></a>
<div class="field field-name-comment-body field-type-text-long field-label-hidden"><div class="field-items"><div class="field-item even" property="content:encoded"><p>Hi Andrey,<br />
Thak you for your complete answers. Because MKL DataFitting is so complecated (versatile or flexible) for me that made me confused.<br />
But I'm getting used to it little by little now. </p>
</div></div></div>Fri, 11 Jan 2013 13:51:40 +0000Shigeo Kobayashicomment 1721031 at https://software.intel.comHi Shigeo,
https://software.intel.com/en-us/comment/1721006#comment-1721006
<a id="comment-1721006"></a>
<div class="field field-name-comment-body field-type-text-long field-label-hidden"><div class="field-items"><div class="field-item even" property="content:encoded"><p>Hi Shigeo, </p>
<p>I do appreciate your questions/feedback related to Intel(R) MKL interpolation functions. Let me address your comments one be one:</p>
<p>1. Yes, the library sets the priorities for boundary conditions as described in the documentation.<br />
The editor df?editppspline1d returns error when you specify boundary conditions which requires array bc, but bs is not provided. For example, in code below the editor returns error DF_ERROR_BAD_BC</p>
<p>bc = 0;<br />
status = dfdEditPPSpline1D(task, DF_PP_CUBIC, DF_PP_NATURAL,<br />
DF_BC_1ST_LEFT_DER | DF_BC_1ST_RIGHT_DER , bc, DF_NO_IC, 0, scoeff, scoeffhint);</p>
<p>At the same time, if you specify<br />
DF_BC_1ST_LEFT_DER | DF_BC_2ND_LEFT_DER | DF_BC_1ST_RIGHT_DER | DF_BC_2ND_RIGHT_DER<br />
as boundary conditions, on the stage of spline construction (function df?construct1d) the library will return error instead of ignoring 2nd order derivatives (as specified in the documentation). I believe that such behavior of the library in this corner case should be properly fixed.</p>
<p>2. When you provide a vector-valued function, the library will interpret its storage format according to yhint parameter. However, when you construct spline for this vector-valued function, spline coefficients will be always stored in the same, row-major format as specified in the description of df?editppspline1d editor. This is design decision which additional helps to address performance aspects.</p>
<p>3. When you interpolate using df?interpolate1d function, the inteporlation results will be packed according to value of rhint parameter as described in df?interpolate1d/df?interpolateex1d section of the manual. For vector-valued function interpolation results are packaged one-by-one for each coordinate of the function, in natural order. Interpolation results for each coordinate are packed according to value of parameter rhint, in row- or column-major format. You will not see any difference when you request to compute just one derivative of given order (say, only value or derivative of the second order). The difference is visible when you request two estimates, say value and derivative of the first order.</p>
<p>4. Specification of one point as boundary condition for vector valued function was design decision. We investigate opportunities to eliminate this limitation.</p>
<p>5.While I'm not sure the request to describe applicability of splines in different computational fields fits into Intel(R) MKL Manual, it might look like a document similar to VSL Notes describing MKL random number generators and Summary Statistics Application Notes describing algorithms for stat analysis available at <a href="http://software.intel.com/en-us/articles/intel-math-kernel-library-documentation">http://software.intel.com/en-us/articles/intel-math-kernel-library-docum...</a>. We need to better understand the details behind such document. </p>
<p>Also, for further reference I suggest to use Intel MKL(R) docs available at <a href="http://software.intel.com/en-us/articles/intel-math-kernel-library-documentation">http://software.intel.com/en-us/articles/intel-math-kernel-library-docum...</a>.</p>
<p>Please, let me know if I covered your comments, and feel free to share with us further feedback or questions related to splines or other domains of the library.</p>
<p>Thanks,<br />
Andrey</p>
</div></div></div>Fri, 11 Jan 2013 08:07:43 +0000Andrey Nikolaev (Intel)comment 1721006 at https://software.intel.comHi Andrey,Thank you for your
https://software.intel.com/en-us/comment/1720928#comment-1720928
<a id="comment-1720928"></a>
<div class="field field-name-comment-body field-type-text-long field-label-hidden"><div class="field-items"><div class="field-item even" property="content:encoded"><p>Hi Andrey,Thank you for your detailed explanation. I thoroughly understand.</p>
<p>I currently have no time to recomfirm same things and might have some confusions,<br />
but it should be worth listing what I have noticed so far.</p>
<p>1.The documentation says,conditions such as DF_BC_NOT_A_KNOT etc have priorities<br />
and any conditions having less priority is ignored.<br />
But actually,dfsEditPPSpline1D returns error instead of ignoring.</p>
<p>2.Hint Values for Vector-Valued Function y (yhint) for dfdNewTask1D,<br />
DF_MATRIX_STORAGE_ROWS or DF_MATRIX_STORAGE_COLS option has no difference?</p>
<p>3.df?interpolate1d,hint Values for the rhint Parameter(DF_MATRIX_STORAGE_ROWS or<br />
DF_MATRIX_STORAGE_COLS) has no difference?</p>
<p>4.DF_BC_Q_VAL option for default quadratic spline,only one y((x0 + x1)/2) value is allowed for all ys as boundary condition,<br />
but this is somewhat strange for Vector-Valued Function y ( Every yi meet always at one point ((x0 + x1)/2,yi((x0 + x1)/2)) ). </p>
<p>5.There are so many spline types such as Akima, Bessel, Hermite, natural cubic, quadratic Subbotin ...<br />
It will be helpfull if the documentation tells us which is the most suitable type for specific computation field.</p>
<p>Thank you again </p>
</div></div></div>Thu, 10 Jan 2013 13:48:00 +0000Shigeo Kobayashicomment 1720928 at https://software.intel.comHello Shigeo,
https://software.intel.com/en-us/comment/1720911#comment-1720911
<a id="comment-1720911"></a>
<div class="field field-name-comment-body field-type-text-long field-label-hidden"><div class="field-items"><div class="field-item even" property="content:encoded"><p>Hello Shigeo,</p>
<p>Description of spline boundary conditions in Intel(R) MKL Manual related to derivatives of the first/second order is incorrect. If you provide DF_BC_[1ST|2ND]_[LEFT|RIGHT]_DER boundary condition to the df?editppspline1d editor, the library expects generally non-zero values of the derivatives (of course, zero values are aslo admissable). This bug in the documentation will be fixed in one of the next releases of the library.</p>
<p>As Mecej4 correctly pointed, natural cubic spline is one defined by free-end boundary conditions: y''(x(1)) = y''(x(n))=0.<br />
Intel MKL implementation of cubic spline slightly extended this definition: </p>
<p> - if you need "classical" natural cubic spline, please specify "natural" type of the cubic spline with DF_BC_FREE_END boundary conditions</p>
<p>status = dfdEditPPSpline1D(task, DF_PP_CUBIC, DF_PP_NATURAL,DF_BC_FREE_END, 0, DF_NO_IC, 0, scoeff, scoeffhint)</p>
<p> - if you need cubic spline with other boundary conditions, please specify "natural" type of the cubic spline with required boundary conditions, e.g.:</p>
<p>status = dfdEditPPSpline1D(task, DF_PP_CUBIC, DF_PP_NATURAL,<br />
DF_BC_1ST_LEFT_DER | DF_BC_1ST_RIGHT_DER , bc, DF_NO_IC, 0, scoeff, scoeffhint)</p>
<p>In this case you will construct a non-natural cubic spline with given boundary conditions.</p>
<p>Does this approach work for you or you would prefer to see clear difference in specification of natural and non-natural cubic splines?</p>
<p>For linear spline with periodic conditions the library expects y(x(1)) = y(x(n)). If your function meets this condition you will get the same results with or without specification of the periodic boundary conditions.<br />
If you specify periodic boundary conditions for linear spline, and your function y does not meet the equality above, the library is expected to return relevant error code. However, this is not the case in the current version of Intel(R) MKL, and testing of periodicity conditions should be supported for linear spline in future releases of the library.</p>
<p>Please, let us know, if this answers your questions, or additional details are necessary.</p>
<p>Thanks,<br />
Andrey</p>
</div></div></div>Thu, 10 Jan 2013 07:53:49 +0000Andrey Nikolaev (Intel)comment 1720911 at https://software.intel.comNo..., DF_BC_1ST_LEFT_DER(=
https://software.intel.com/en-us/comment/1720837#comment-1720837
<a id="comment-1720837"></a>
<div class="field field-name-comment-body field-type-text-long field-label-hidden"><div class="field-items"><div class="field-item even" property="content:encoded"><p>No..., DF_BC_1ST_LEFT_DER(==bc_type) with non-zero boundary value(==bc[0]) gives you non-zero slope of the curve.</p>
<p>> A "natural" spline is one which has no bending moment applied at the ends, i.e., y'' = 0 at those points.<br />
Yes,but MKL implementation seems to be different (Pls see DF_PP_NATURAL and DF_BC_FREE_END).</p>
</div></div></div>Wed, 09 Jan 2013 14:34:00 +0000Shigeo Kobayashicomment 1720837 at https://software.intel.com'The first derivative at the
https://software.intel.com/en-us/comment/1720827#comment-1720827
<a id="comment-1720827"></a>
<div class="field field-name-comment-body field-type-text-long field-label-hidden"><div class="field-items"><div class="field-item even" property="content:encoded"><p> 'The first derivative at the left endpoint is zero.' This implies that you want the slope of the curve to be zero at the left endpoint,.i.e., the curve has as tangent a line with y'(x=the left endpoint) = 0.</p>
<p>A "natural" spline is one which has no bending moment applied at the ends, i.e., y'' = 0 at those points.</p>
</div></div></div>Wed, 09 Jan 2013 11:49:12 +0000mecej4comment 1720827 at https://software.intel.com