OpenCL* for CPU
Ask questions and share information on Intel® SDK for OpenCL™ Applications and OpenCL™ implementations for Intel® CPU
Announcements
This forum covers OpenCL* for CPU only. OpenCL* for GPU questions can be asked in the GPU Compute Software forum. Intel® FPGA SDK for OpenCL™ questions can be ask in the FPGA Intel® High Level Design forum.
1663 Discussions

Complex matrix multiplication OpenCL

c7890
Novice
465 Views

i’m a new programmer on opencl, i’ve to perform a multiplication of 2 complex matrix but i don’t know how to deal with complex matrix on opencl. please any help?
I already tried matrix multiplication with normal numbers.

0 Kudos
1 Reply
Ben_A_Intel
Employee
430 Views

Hello!

Do you already have a version of the matrix multiplication kernel that works on real (non-complex) numbers?  If not, this is a good place to get started:

https://software.intel.com/content/www/us/en/develop/articles/sgemm-for-intel-processor-graphics.htm...

Once you have a matrix multiplication kernel that works on real numbers, to convert to a kernel that works on complex numbers you'll need to change the inner-most loop to perform a complex multiplication and add rather than a real (non-complex) mulitplication and add.  The multiplication part can be a bit tricky, but the add is pretty straightforward.

If you get this working can you post your code?  My google search found several others asking similar questions, but I didn't find a working example... yet!

Reply