<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic beta distribution and MKL in Intel® oneAPI Math Kernel Library</title>
    <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829409#M5403</link>
    <description>&lt;P&gt;Hello,&lt;BR /&gt;Please, provide a test casewhich reproduces the issue and would help toclarifyreasonsof thaterror.&lt;BR /&gt;Thanks,&lt;BR /&gt;Andrey&lt;/P&gt;</description>
    <pubDate>Tue, 08 May 2012 15:39:22 GMT</pubDate>
    <dc:creator>Andrey_N_Intel</dc:creator>
    <dc:date>2012-05-08T15:39:22Z</dc:date>
    <item>
      <title>beta distribution and MKL</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829407#M5401</link>
      <description>Hello, I am attempting to work with the MKL library and in particular the beta function. The commands worked with an older version of mkl on a different system. I think that there may be a problem with my function&lt;BR /&gt;&lt;BR /&gt;I am calling the following subroutine:&lt;BR /&gt;&lt;BR /&gt;&lt;P&gt;subroutine beta_rng_mkl(seed_in, n_rand_obs_in, r_beta_list, shape1, shape2)&lt;/P&gt;&lt;P&gt;use :: mkl_vsl_type&lt;/P&gt;&lt;P&gt;integer :: brng&lt;/P&gt;&lt;P&gt;integer, intent(in) :: seed_in, n_rand_obs_in, methodrng&lt;/P&gt;&lt;P&gt;real, pointer, intent(out) :: r_beta_list&lt;/P&gt;&lt;P&gt;type(VSL_STREAM_STATE) :: stream&lt;/P&gt;&lt;P&gt;integer :: status&lt;/P&gt;&lt;P&gt;external :: vslnewstream, vsrngbeta, vsldeletestream&lt;/P&gt;&lt;P&gt;methodrng = VSL_METHOD_SBETA_CJA&lt;/P&gt;&lt;P&gt;brng = vsl_brng_mcg31&lt;/P&gt;&lt;P&gt;status = vslnewstream(stream, brng, seed_in)&lt;/P&gt;&lt;P&gt;status = vsrngbeta( methodrng, stream, n_rand_obs_in, r_beta_list, shape1, shape2, 0.0, 1.0 )&lt;/P&gt;&lt;P&gt;status = vsldeletestream(stream)&lt;/P&gt;&lt;P&gt;end subroutine&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;and I get the following error message in my program:&lt;/P&gt;&lt;P&gt;jgold@clinic:~/smwcv/error_infect/data_augment/random_sim/sim1/o1newinfections75$ ifort -free -O2 -stand f03 -check bounds -traceback -warn all -fstack-protector -assume protect_parens -implicitnone -o mcmcobsgammanoepsilon.out mcmcobsgammanoepsilon.f90 -I/opt/intel/composer_xe_2011_sp1.6.233/mkl/include -L/opt/intel/composer_xe_2011_sp1.6.233/mkl/lib/intel64 -lmkl_rt&lt;/P&gt;&lt;P&gt;mcmcobsgammanoepsilon.f90(59): error #8000: There is a conflict between local interface block and external interface block. [R_BETA_LIST]&lt;/P&gt;&lt;P&gt;subroutine beta_rng_mkl(seed_in, n_rand_obs_in, r_beta_list, shape1, shape2)&lt;/P&gt;&lt;P&gt;---------------------------------------------------^&lt;/P&gt;&lt;P&gt;mcmcobsgammanoepsilon.f90(367): error #6634: The shape matching rules of actual arguments and dummy arguments have been violated. [R_BETA_LIST]&lt;/P&gt;&lt;P&gt;call beta_rng_mkl(seed_in, n_rand_obs_in, r_beta_list, shape1, shape2)&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;below is the local interface:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;P&gt;include "mkl_vsl.f90"&lt;/P&gt;&lt;P&gt;module randvariables&lt;/P&gt;&lt;P&gt;real :: harvest, shape1, shape2&lt;/P&gt;&lt;P&gt;integer :: seed_in, n_rand_obs_in&lt;/P&gt;&lt;P&gt;real, dimension(:), pointer :: r_beta_list&lt;/P&gt;&lt;P&gt;integer :: r_beta_count, rejectflag&lt;/P&gt;&lt;P&gt;integer, dimension (:, :) , allocatable :: link &lt;/P&gt;&lt;P&gt;end module&lt;/P&gt;&lt;P&gt;program mcnet&lt;/P&gt;&lt;P&gt;! Tell the main program to use the randvariables module&lt;/P&gt;&lt;P&gt;use :: randvariables&lt;/P&gt;</description>
      <pubDate>Mon, 07 May 2012 22:25:34 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829407#M5401</guid>
      <dc:creator>jaureus</dc:creator>
      <dc:date>2012-05-07T22:25:34Z</dc:date>
    </item>
    <item>
      <title>beta distribution and MKL</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829408#M5402</link>
      <description>Detection of perceived/actual mismatches of variable types is quite context dependent. We cannot ascertain what the compiler is complaining about from the snippets of code that you showed. For example, the error messages refer to source lines 59 and 367, and we do not know what those lines contain.&lt;BR /&gt;&lt;BR /&gt;Please provide a complete example that reproduces the problem.&lt;BR /&gt;</description>
      <pubDate>Tue, 08 May 2012 09:46:28 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829408#M5402</guid>
      <dc:creator>mecej4</dc:creator>
      <dc:date>2012-05-08T09:46:28Z</dc:date>
    </item>
    <item>
      <title>beta distribution and MKL</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829409#M5403</link>
      <description>&lt;P&gt;Hello,&lt;BR /&gt;Please, provide a test casewhich reproduces the issue and would help toclarifyreasonsof thaterror.&lt;BR /&gt;Thanks,&lt;BR /&gt;Andrey&lt;/P&gt;</description>
      <pubDate>Tue, 08 May 2012 15:39:22 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829409#M5403</guid>
      <dc:creator>Andrey_N_Intel</dc:creator>
      <dc:date>2012-05-08T15:39:22Z</dc:date>
    </item>
    <item>
      <title>beta distribution and MKL</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829410#M5404</link>
      <description>&lt;P&gt;here is a test program&lt;BR /&gt;&lt;BR /&gt;include 'mkl_vsl.f90'&lt;/P&gt;&lt;P&gt;module randvariables&lt;/P&gt;&lt;P&gt;real :: harvest, shape1, shape2&lt;/P&gt;&lt;P&gt;integer :: seed_in, n_rand_obs_in&lt;/P&gt;&lt;P&gt;real, dimension(:), pointer :: r_beta_list&lt;/P&gt;&lt;P&gt;integer :: r_beta_count&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;end module&lt;/P&gt;&lt;P&gt;program mcnet&lt;/P&gt;&lt;P&gt;! Tell the main program to use the randvariables module&lt;/P&gt;&lt;P&gt;use :: randvariables&lt;/P&gt;&lt;P&gt;implicit none&lt;/P&gt;&lt;P&gt;real :: theta&lt;/P&gt;&lt;P&gt;interface&lt;/P&gt;&lt;P&gt;subroutine beta_rng_mkl(seed_in, n_rand_obs_in, r_beta_list, shape1, shape2)&lt;/P&gt;&lt;P&gt;implicit none&lt;/P&gt;&lt;P&gt;integer, intent(in) :: seed_in, n_rand_obs_in&lt;/P&gt;&lt;P&gt;real, dimension(:), intent(out) :: r_beta_list&lt;/P&gt;&lt;P&gt;real, intent(in) :: shape1, shape2&lt;/P&gt;&lt;P&gt;end subroutine beta_rng_mkl&lt;/P&gt;&lt;P&gt;end interface&lt;/P&gt;&lt;P&gt;call random_number(harvest)&lt;/P&gt;&lt;P&gt;seed_in = aint(harvest * 2.0e0**31)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;shape1 = 200 &lt;/P&gt;&lt;P&gt;shape2 = 400 &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;! print *, "shape1 ", " shape2" &lt;/P&gt;&lt;P&gt;! print *, shape1, shape2&lt;/P&gt;&lt;P&gt;n_rand_obs_in = 1&lt;/P&gt;&lt;P&gt;allocate (r_beta_list(n_rand_obs_in))&lt;/P&gt;&lt;P&gt;call beta_rng_mkl(seed_in, n_rand_obs_in, r_beta_list, shape1, shape2)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;theta = r_beta_list(1) &lt;/P&gt;&lt;P&gt;print *, theta&lt;/P&gt;&lt;P&gt;end program&lt;BR /&gt;&lt;BR /&gt;My routine is above and again here are the errors&lt;/P&gt;&lt;P&gt;betaworkedex.f90(20): error #8000: There is a conflict between local interface block and external interface block. [R_BETA_LIST]&lt;/P&gt;&lt;P&gt;subroutine beta_rng_mkl(seed_in, n_rand_obs_in, r_beta_list, shape1, shape2)&lt;/P&gt;&lt;P&gt;---------------------------------------------------^&lt;/P&gt;&lt;P&gt;betaworkedex.f90(40): error #6634: The shape matching rules of actual arguments and dummy arguments have been violated. [R_BETA_LIST]&lt;/P&gt;&lt;P&gt;call beta_rng_mkl(seed_in, n_rand_obs_in, r_beta_list, shape1, shape2)&lt;/P&gt;</description>
      <pubDate>Wed, 09 May 2012 12:57:36 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829410#M5404</guid>
      <dc:creator>jaureus</dc:creator>
      <dc:date>2012-05-09T12:57:36Z</dc:date>
    </item>
    <item>
      <title>beta distribution and MKL</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829411#M5405</link>
      <description>The subroutine that you gave in the initial post is not quite correct. It declares intent for &lt;I&gt;methodrng&lt;/I&gt;, which is not a subroutine argument.&lt;BR /&gt;&lt;BR /&gt;After declaring &lt;I&gt;methodrng&lt;/I&gt; as a local integer variable, I obtained the following output:&lt;BR /&gt;&lt;BR /&gt;[bash]T:&amp;gt; ifort /Qmkl mklvsl.f90
Intel Visual Fortran Compiler XE for applications running on IA-32, Version 12.1.3.300 Build 20120130
Copyright (C) 1985-2012 Intel Corporation.  All rights reserved.

Microsoft  Incremental Linker Version 10.00.40219.01
Copyright (C) Microsoft Corporation.  All rights reserved.

-out:mklvsl.exe
-subsystem:console
-libpath:c:LANGIntelCOMPOS~2mkllibia32
mklvsl.obj

T:&amp;gt;mklvsl
  0.2999528&lt;BR /&gt;&lt;BR /&gt;However, this may be a bogus result, since I did not check whether the VSL subroutine/function calls are being made with the proper argument types.[/bash]</description>
      <pubDate>Thu, 10 May 2012 16:20:12 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829411#M5405</guid>
      <dc:creator>mecej4</dc:creator>
      <dc:date>2012-05-10T16:20:12Z</dc:date>
    </item>
    <item>
      <title>beta distribution and MKL</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829412#M5406</link>
      <description>&lt;P&gt;Hi, ok so I modified the variable definition and I get the same error. Clearly, I am doing somethng very wrong. could it have to do with the fact that I am defining variables in a module and also reading them in with an intent statement. Usually, I would not do this but it seems that this is what mkl modules want.&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;subroutine beta_rng_mkl(seed_in, n_rand_obs_in, r_beta_list, shape1, shape2)&lt;/P&gt;&lt;P&gt;use :: mkl_vsl_type&lt;/P&gt;&lt;P&gt;integer :: brng&lt;/P&gt;&lt;P&gt;integer, intent(in) :: seed_in, n_rand_obs_in&lt;/P&gt;&lt;P&gt;!integer, intent(in) :: methodrng&lt;/P&gt;&lt;P&gt;real, pointer, intent(out) :: r_beta_list&lt;/P&gt;&lt;P&gt;type(VSL_STREAM_STATE) :: stream&lt;/P&gt;&lt;P&gt;integer :: status, methodrng&lt;/P&gt;&lt;P&gt;external :: vslnewstream, vsrngbeta, vsldeletestream&lt;/P&gt;&lt;P&gt;methodrng = VSL_METHOD_SBETA_CJA&lt;/P&gt;&lt;P&gt;brng = vsl_brng_mcg31&lt;/P&gt;&lt;P&gt;status = vslnewstream(stream, brng, seed_in)&lt;/P&gt;&lt;P&gt;status = vsrngbeta( methodrng, stream, n_rand_obs_in, r_beta_list, shape1, shape2, 0.0, 1.0 )&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;status = vsldeletestream(stream)&lt;/P&gt;&lt;P&gt;end subroutine&lt;/P&gt;</description>
      <pubDate>Fri, 11 May 2012 20:07:40 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829412#M5406</guid>
      <dc:creator>jaureus</dc:creator>
      <dc:date>2012-05-11T20:07:40Z</dc:date>
    </item>
    <item>
      <title>beta distribution and MKL</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829413#M5407</link>
      <description>You have to add&lt;BR /&gt;&lt;BR /&gt; use MKL_VSL&lt;BR /&gt;&lt;BR /&gt;to provide the compiler with the information needed to check that you are making proper calls to the VSL routine(s).&lt;BR /&gt;&lt;BR /&gt;There are example source codes provided with MKL, and many of these are also described in the documentation. I suggest that you pick one that is suitable, verify that it works correctly when compiled and run, and then modify the example for your purposes.</description>
      <pubDate>Sat, 12 May 2012 05:04:17 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829413#M5407</guid>
      <dc:creator>mecej4</dc:creator>
      <dc:date>2012-05-12T05:04:17Z</dc:date>
    </item>
    <item>
      <title>beta distribution and MKL</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829414#M5408</link>
      <description>&lt;P&gt;Hi &lt;A href="http://software.intel.com/en-us/profile/518340/"&gt;&lt;SPAN style="text-decoration: underline;"&gt;jaureus&lt;/SPAN&gt;&lt;/A&gt;,&lt;/P&gt;&lt;P&gt;I used test case which you provided not able to reproduce it for above mentioned error, did you verified MKL_VSL option?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Naveen Gv&lt;/P&gt;</description>
      <pubDate>Mon, 14 May 2012 11:05:26 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829414#M5408</guid>
      <dc:creator>Naveen_G_Intel</dc:creator>
      <dc:date>2012-05-14T11:05:26Z</dc:date>
    </item>
    <item>
      <title>beta distribution and MKL</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829415#M5409</link>
      <description>Hi Naveen,&lt;BR /&gt;I am really sorry to say that even with all of your help I am unble to get it to work. I have tried out the example within the example set and it works so there is clearly a coding issue, however, I just can't see it.&lt;BR /&gt;&lt;BR /&gt;&lt;P&gt;subroutine beta_rng_mkl(seed_in, r_beta_list, shape1, shape2)&lt;/P&gt;&lt;P&gt;use mkl_vsl_type&lt;/P&gt;&lt;P&gt;use mkl_vsl&lt;/P&gt;&lt;P&gt;integer :: brng&lt;/P&gt;&lt;P&gt;integer, intent(in) :: seed_in&lt;/P&gt;&lt;P&gt;!integer, intent(in) :: methodrng&lt;/P&gt;&lt;P&gt;real, intent(out) :: r_beta_list(1)&lt;/P&gt;&lt;P&gt;type(VSL_STREAM_STATE) :: stream&lt;/P&gt;&lt;P&gt;integer :: status, methodrng, n_rand_obs_in&lt;/P&gt;&lt;P&gt;!external :: vslnewstream, vsrngbeta, vsldeletestream&lt;/P&gt;&lt;P&gt;methodrng = VSL_METHOD_SBETA_CJA&lt;/P&gt;&lt;P&gt;n_rand_obs_in = 1&lt;/P&gt;&lt;P&gt;brng = vsl_brng_mcg31&lt;/P&gt;&lt;P&gt;status = vslnewstream(stream, brng, seed_in)&lt;/P&gt;&lt;P&gt;status = vsrngbeta( methodrng, stream, n_rand_obs_in, r_beta_list, shape1, shape2, 0.0, 1.0 )&lt;/P&gt;&lt;P&gt;status = vsldeletestream(stream)&lt;/P&gt;&lt;P&gt;end subroutine&lt;BR /&gt;&lt;BR /&gt;I have modified the code to &lt;STRONG&gt;include&lt;/STRONG&gt; the mkl_vsl option as suggested. However, alas still no joy. i.e. I still get the following errors with my test code:&lt;/P&gt;&lt;P&gt;betaworkedexold.f90(20): error #8000: There is a conflict between local interface block and external interface block. [R_BETA_LIST]&lt;/P&gt;&lt;P&gt;subroutine beta_rng_mkl(seed_in, n_rand_obs_in, r_beta_list, shape1, shape2)&lt;/P&gt;&lt;P&gt;---------------------------------------------------^&lt;/P&gt;&lt;P&gt;betaworkedexold.f90(41): error #6634: The shape matching rules of actual arguments and dummy arguments have been violated. [R_BETA_LIST]&lt;/P&gt;&lt;P&gt;call beta_rng_mkl(seed_in, n_rand_obs_in, r_beta_list, shape1, shape2)&lt;/P&gt;</description>
      <pubDate>Mon, 14 May 2012 15:36:00 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829415#M5409</guid>
      <dc:creator>jaureus</dc:creator>
      <dc:date>2012-05-14T15:36:00Z</dc:date>
    </item>
    <item>
      <title>beta distribution and MKL</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829416#M5410</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Test code which you provided may not be enough to reproduce the problem. &lt;/P&gt;&lt;P&gt;This particular error usually means that the declaration of the named routine R_BETA_LIST is different between the actual procedure and a definition that came from a module. It may be that a Build &amp;gt; Rebuild of the VS solution will take care of it, as sometimes, with /warn:interface enabled, a generated interface module from a previous compilation is out of date.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Naveen Gv&lt;/P&gt;</description>
      <pubDate>Thu, 17 May 2012 03:38:07 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/beta-distribution-and-MKL/m-p/829416#M5410</guid>
      <dc:creator>Naveen_G_Intel</dc:creator>
      <dc:date>2012-05-17T03:38:07Z</dc:date>
    </item>
  </channel>
</rss>

