<?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 If you look at mkl_types.h in Intel® oneAPI Math Kernel Library</title>
    <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/calling-vzCIS-within-c/m-p/939333#M14360</link>
    <description>If you look at &lt;STRONG&gt;mkl_types.h&lt;/STRONG&gt; header file you will see that a declaration of &lt;STRONG&gt;MKL_Complex16&lt;/STRONG&gt; type is inside of &lt;STRONG&gt;#ifndef-#endif&lt;/STRONG&gt; directives. It means, that in order to use that type you'll need to define the macro &lt;STRONG&gt;MKL_Complex16&lt;/STRONG&gt; before &lt;STRONG&gt;mkl.h&lt;/STRONG&gt; or &lt;STRONG&gt;mkl_types.h&lt;/STRONG&gt; header files:

...
#define MKL_Complex16
#include "mkl.h"
...

or as
...
#define MKL_Complex16
#include "mkl_types.h"
...

or as
...
#define MKL_Complex16 std::complex&lt;DOUBLE&gt;
#include "mkl.h"
...
and in the last example MKL's complex type will be re-defined by STL complex type.&lt;/DOUBLE&gt;</description>
    <pubDate>Sun, 10 Feb 2013 20:28:00 GMT</pubDate>
    <dc:creator>SergeyKostrov</dc:creator>
    <dc:date>2013-02-10T20:28:00Z</dc:date>
    <item>
      <title>calling vzCIS within c++</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/calling-vzCIS-within-c/m-p/939330#M14357</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;I've got a problem in calling vzCIS from C++&lt;/P&gt;
&lt;P&gt;#include &amp;lt;complex&amp;gt;&lt;BR /&gt;#include "mkl.h"&lt;BR /&gt;&lt;BR /&gt;template&amp;lt;class T&amp;gt;class array{&lt;BR /&gt;&amp;nbsp;&amp;nbsp; public:&lt;BR /&gt;&amp;nbsp;&amp;nbsp; int n;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; T* x;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; array(){};&lt;BR /&gt;&amp;nbsp;&amp;nbsp; ~array(){};&lt;BR /&gt;&amp;nbsp;&amp;nbsp; array(int _n):n(_n),x(new T&lt;N&gt;){};&lt;BR /&gt;};&lt;BR /&gt;&lt;BR /&gt;int main(){&lt;BR /&gt;&amp;nbsp;&amp;nbsp; int n=32;&lt;BR /&gt;&amp;nbsp;&amp;nbsp; array&amp;lt;double&amp;gt; x(n);&lt;BR /&gt;&amp;nbsp;&amp;nbsp; array&amp;lt;double&amp;gt; y(n);&lt;BR /&gt;&amp;nbsp;&amp;nbsp; //array&amp;lt;MKL_Complex16&amp;gt; u(n);&lt;BR /&gt;&amp;nbsp;&amp;nbsp; //array&amp;lt;MKL_Complex16&amp;gt; v(n);&lt;BR /&gt;&amp;nbsp;&amp;nbsp; array&amp;lt; std::complex&amp;lt;double&amp;gt; &amp;gt; u(n);&lt;BR /&gt;&amp;nbsp;&amp;nbsp; array&amp;lt; std::complex&amp;lt;double&amp;gt; &amp;gt; v(n);&lt;BR /&gt;&amp;nbsp;&amp;nbsp; vdCos(x.n,x.x,y.x);&lt;BR /&gt;&amp;nbsp;&amp;nbsp; vzCIS(u.n,u.x,v.x);&lt;BR /&gt;&amp;nbsp;&amp;nbsp; return 0;&lt;BR /&gt;}&lt;/N&gt;&lt;/P&gt;
&lt;P&gt;I compiled with icpc -mkl file.cpp and icpc gave me&lt;/P&gt;
&lt;P&gt;error: argument of type "std::complex&amp;lt;double&amp;gt; *" is incompatible with parameter of type "MKL_Complex16 *"&lt;/P&gt;
&lt;P&gt;Does someone have a solution? Tahnk you very much.&lt;/P&gt;
&lt;P&gt;Fabio&lt;/P&gt;</description>
      <pubDate>Sat, 09 Feb 2013 18:43:20 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/calling-vzCIS-within-c/m-p/939330#M14357</guid>
      <dc:creator>Fabio_G_1</dc:creator>
      <dc:date>2013-02-09T18:43:20Z</dc:date>
    </item>
    <item>
      <title>The third argument of vzCIS</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/calling-vzCIS-within-c/m-p/939331#M14358</link>
      <description>&lt;P&gt;The third argument of vzCIS should be an array with type (Fortran's) DOUBLE COMPLEX or something compatible with it. Your code is trying to pass a real array instead.&lt;/P&gt;</description>
      <pubDate>Sat, 09 Feb 2013 20:57:17 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/calling-vzCIS-within-c/m-p/939331#M14358</guid>
      <dc:creator>mecej4</dc:creator>
      <dc:date>2013-02-09T20:57:17Z</dc:date>
    </item>
    <item>
      <title>MKL_Complex16 is compatible</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/calling-vzCIS-within-c/m-p/939332#M14359</link>
      <description>&lt;P&gt;MKL_Complex16 is compatible with std::complex&amp;lt;double&amp;gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://software.intel.com/sites/products/documentation/hpc/mkl/lin/MKL_UG_coding_calls/Using_Complex_Types_in_C_C.htm" target="_blank"&gt;http://software.intel.com/sites/products/documentation/hpc/mkl/lin/MKL_UG_coding_calls/Using_Complex_Types_in_C_C.htm&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;and the version with comment out lines, i.e. array&amp;lt;MKL_Complex16&amp;gt;, does not work too. (with or without redefining MKL_Complex16).&lt;/P&gt;
&lt;P&gt;mecej4: thank you now I've understand where is the problem.&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;</description>
      <pubDate>Sat, 09 Feb 2013 22:42:00 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/calling-vzCIS-within-c/m-p/939332#M14359</guid>
      <dc:creator>Fabio_G_1</dc:creator>
      <dc:date>2013-02-09T22:42:00Z</dc:date>
    </item>
    <item>
      <title>If you look at mkl_types.h</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/calling-vzCIS-within-c/m-p/939333#M14360</link>
      <description>If you look at &lt;STRONG&gt;mkl_types.h&lt;/STRONG&gt; header file you will see that a declaration of &lt;STRONG&gt;MKL_Complex16&lt;/STRONG&gt; type is inside of &lt;STRONG&gt;#ifndef-#endif&lt;/STRONG&gt; directives. It means, that in order to use that type you'll need to define the macro &lt;STRONG&gt;MKL_Complex16&lt;/STRONG&gt; before &lt;STRONG&gt;mkl.h&lt;/STRONG&gt; or &lt;STRONG&gt;mkl_types.h&lt;/STRONG&gt; header files:

...
#define MKL_Complex16
#include "mkl.h"
...

or as
...
#define MKL_Complex16
#include "mkl_types.h"
...

or as
...
#define MKL_Complex16 std::complex&lt;DOUBLE&gt;
#include "mkl.h"
...
and in the last example MKL's complex type will be re-defined by STL complex type.&lt;/DOUBLE&gt;</description>
      <pubDate>Sun, 10 Feb 2013 20:28:00 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/calling-vzCIS-within-c/m-p/939333#M14360</guid>
      <dc:creator>SergeyKostrov</dc:creator>
      <dc:date>2013-02-10T20:28:00Z</dc:date>
    </item>
    <item>
      <title>Please, also have a look at</title>
      <link>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/calling-vzCIS-within-c/m-p/939334#M14361</link>
      <description>&lt;P&gt;Please, also have a look at the paper &lt;A href="http://software.intel.com/en-us/articles/use-of-intel-mkl-data-types-in-cc-applications"&gt;http://software.intel.com/en-us/articles/use-of-intel-mkl-data-types-in-cc-applications&lt;/A&gt;&amp;nbsp;which describes some aspects of use of Intel(R) MKL data types in C++ applications.&amp;nbsp;Thanks, Andrey&lt;/P&gt;</description>
      <pubDate>Mon, 11 Feb 2013 07:55:27 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-oneAPI-Math-Kernel-Library/calling-vzCIS-within-c/m-p/939334#M14361</guid>
      <dc:creator>Andrey_N_Intel</dc:creator>
      <dc:date>2013-02-11T07:55:27Z</dc:date>
    </item>
  </channel>
</rss>

