Quantcast
Channel: Intel® oneAPI Math Kernel Library & Intel® Math Kernel Library
Viewing all articles
Browse latest Browse all 2652

General question. Seeing error in lower digits when doing simple dgemm example

$
0
0

Hi,

 

I am new to MKL. I started by doing a basic example which creates an NxM matrix A.  A consists of random numbers between -1 and 1 and can contain one digit after the decimal point only. For example, -0.1 might be there but not -0.12

I then used dgemm to calculate A*Atranspose.

I compared the answer to my manual calculation

For some elements, there appears to be some error.

 

For example if my manual calculation calculates 123.45 then dgemm is returning 123.45000000006789 . The lower digits are obviously junk as it is simply a sum of products of numbers to one decimal place each.

 

Is this expected behaviour?

 

 

 

 

TCE Open Date: 

Thursday, November 28, 2019 - 08:21

Viewing all articles
Browse latest Browse all 2652

Trending Articles