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

problem with IMSL subroutine lin_sol_lsq

raov
Beginner
513 Views
Using Intel Fortran 8.0 professional for Windows , the program below stops silently after calling IMSL subroutine lin_sol_lsq. How can I make it work, or at least get an error message?
program xlin_sol_lsq_imsl
use rand_gen_int , only: rand_gen
use lin_sol_lsq_int, only: lin_sol_lsq
implicit none
integer i
integer, parameter :: m=20, n=8
real(kind(1d0)), parameter :: one=1d0, zero=0d0
real(kind(1d0)) A(m,0:n), c(0:n,1), pi_over_2, x(m), y(m,1)
! Generate a random grid of points.
call rand_gen(x)
x = x*2 - one
pi_over_2 = atan(one)*2
y(1:m,1) = exp(x) + cos(pi_over_2*x)
A(:,0) = one
A(:,1) = x
do i=2, n
A(:,i) = 2*x*A(:,i-1) - A(:,i-2)
end do
print*,"calling lin_sol_lsq, x=",x
call lin_sol_lsq(A, y, c)
print*,"returned from lin_sol_lsq, c=",c
end program xlin_sol_lsq_imsl
0 Kudos
1 Reply
Steven_L_Intel1
Employee
513 Views
This works fine for me in 8.1.028.
0 Kudos
Reply