- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
In an effort to remove IMSL library from our projects (because of the new licensing policy) I am giving a try to the MKL library. I mainly use cubic spline functions using Intel Visual Fortran Compiler XE on IA-32, version 12.1.1 (Package ID: w_fcompxe_2011.7.258). I have started with from an existing project that compiles and links fine with IMSL (the project exports functions used in Excel through VBA to provide spline features). I have added a new function that uses the spline possibilities of the MKL (10.3 update 10). The call to the function from VBA works fine, but I get an Access violation when calling the function dfdConstruct1D(). It seems that the problem is located in the mkl at location : _mkl_df_kernel_n8_dDFAkimaCubicSpline1D() + 0x1765c octets. The source code was created from an example provided in the documentation and I don't understand what I am doing wrong. The source file is attached.
Best regards.
In an effort to remove IMSL library from our projects (because of the new licensing policy) I am giving a try to the MKL library. I mainly use cubic spline functions using Intel Visual Fortran Compiler XE on IA-32, version 12.1.1 (Package ID: w_fcompxe_2011.7.258). I have started with from an existing project that compiles and links fine with IMSL (the project exports functions used in Excel through VBA to provide spline features). I have added a new function that uses the spline possibilities of the MKL (10.3 update 10). The call to the function from VBA works fine, but I get an Access violation when calling the function dfdConstruct1D(). It seems that the problem is located in the mkl at location : _mkl_df_kernel_n8_dDFAkimaCubicSpline1D() + 0x1765c octets. The source code was created from an example provided in the documentation and I don't understand what I am doing wrong. The source file is attached.
Best regards.
Link Copied
- « Previous
-
- 1
- 2
- Next »
29 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I did some tests with the last release of the MKL (10.3 Update 12) and it seems that the main problems are fixed. However I have found that there are still some differences with the DCSAKM function of the IMSL library. With the following, relatively smooth, data, one can see a different behavior between IMSL and the MKL.
[plain]XDATA = [ 50, 60, 70, 80, 90, 100 ]
YDATA = [ 32.5, 44, 60, 76, 88, 100 ][/plain]
If you compare the values predicted by both routines, they are exactly the same except for the intervals [50-60], [70-80] and [80-90].
The subroutine I have used to perform the calculation is attached.
Best regards,
Phil.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Phil,
Could you please tell me which type of boundary conditions are you using to construct Akima spline with MKL?
In order to construct the same spline as with DCSAKM please use DF_NO_BC.
Best regards,
Vika
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Victoriya,
Thanks for your quick reply.
I have used
[fortran]bc_type = DF_BC_NOT_A_KNOT[/fortran]
I will try with your suggestion
[fortran]bc_type = DF_NO_BC[/fortran]
and keep you informed of the results.
Best regards,
Phil.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Victoriya,
Sorry but it doesn't work better (in fact it's worst !).
Best regards,
Phil
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Victoriya,
For your information (I don't known if it can help) it seems that the derivative calculated at X=80 is equal to zero !.
Moreover the derivative for the first point seems also to be badly estimated (but the difference with IMSL is lesser).
Have you tried to download the ZIP file containing my routine ? (because this does not works for me; I get "page not found" !)
Best regards,
Phil.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Phil,
The issue was reproduced on our side and the bug report related to this issue was re-opened.
Root-causing of the problem is in progress currently.
I also failed to download .zip archive. Could you try uploading it once again?
Thanks,
Vika
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Victoriya,
Please find another attempt to attach the ZIP file containing my subroutine.
I have another side question concerning the size of the generated DLLs including the MKL. In CVF, my dll which uses IMSL has a size around 750 kB, the same dll generated using IVF with MKL (use of interpolation routines only) sizes now 9800 kB !!! That's huge in comparison ! (note that I am using static linking in both projects). Do you have an explanation of such a difference ?
Best regards,
Phil.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hey
What is the deference between the Akima method and the cubic spline method
How can code the akima in SAs I know how to code the cubic spline in SAS
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Alzaki,
Akima spline and natural cubic spline are the different types of cubic splines. They use different algorithms to construct the coefficients of the spline.
Please see this paper for the definition of Akima spline: "A New Method of Interpolation and Smooth Curve Fitting Based on Local Procedures" by Hiroshi Akima.
Best regards,
Vika
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- « Previous
-
- 1
- 2
- Next »