Intel® Fortran Compiler
Build applications that can scale for the future with optimized code designed for Intel® Xeon® and compatible processors.
29245 Discussions

Casting numerical rank 2 arrays between data types

g_f_thomas
Beginner
450 Views
In my program I have some double arrays, call them NW, NE, SW, and SE, commensurable in size and shape as need be in order to stuff them into an array A like A = [NW NE; SWSE] in Matlab like notation. However, I need A to be of

type

(D_INTERVAL), allocatable :: A(:,:)

for use with the interval linear solver suitein the current release of MKL. Right now I get such missives as

Error: The assignment operation or the binary expression operation is invalid for the data types of the two operands.

Is there any way round this without making everything of type(D_INTERVAL) thus extending computational time by a factor of about 3?

Thanks,

Gerry

0 Kudos
1 Reply
g_f_thomas
Beginner
450 Views

Here I go talking to myself again!

A%inf = 0.d0; A%sup = 0.d0

is the way to do it, I think.

Gerry

0 Kudos
Reply