Re: can somebody verify this C program which calls dsaupd_ ? (longish)



H. S. wrote:

Apparently, _Madhusudan Singh_, on 02/04/05 19:05,typed:

H. S. wrote:

(terribly sorry for this long post which includes my two source files,
but I could't find out how put the files online using my Yahoo account)

The problem is not with the length of your post but with the relevance to
the newsgroup.

Since I was requesting somebody who already has the FORTRAN libraries installed and works with them to test if the program does call dsaupd_ properly without getting info=-9999 as error, I do not see how the post is NOT relevant to FORTRAN language newsgroup.

(from previous post)

>   The remaining parameters to the function calls are as follows:

>   dsaupd(int n, int nev, double *Evals)
>   dsaupd(int n, int nev, doubel *Evals, double **Evecs)

I would be very surprised to see a Fortran program expecting a double**.

It would be usual to expect a double* that is big enough for the whole
matrix, as it would be for C if declared as a 2D matrix. It is, of course, system dependent, but to satisfy some of the Fortran rules for
calls, it isn't easy otherwise.


If dsaupd is not a Fortran program, but a C interface to Fortran then I would have to agree that the question is 100% C. (Actually, C++ as there are many non-C constructs used.)

Otherwise, post the generated assembly code for the smallest Fortran subroutine expecting a two-dimensional array argument so we can see the expected calling sequence. How about an in-place transpose of a 2D matrix.

-- glen

-- glen

.



Relevant Pages

  • Re: Google stats on postings
    ... As has been noted *MANY* times before, that is your personal choice. ... and the Fortran postings decreasing. ... Moderating an active newsgroup like ... the group approved and a moderator set up, you would also need to get ...
    (comp.lang.fortran)
  • Re: PL/I is not viable
    ... which with its cross-posted topics had about 300 replies, ... I take it that you would rather continue that DEAD newsgroup situation ... Fortran newsgroup. ... hows $5/each for my posting a monthly PL/I Cant with full Fortran source ...
    (comp.lang.pl1)
  • Re: Google stats on postings
    ... As has been noted *MANY* times before, that is your personal choice. ... and the Fortran postings decreasing. ... Moderating an active newsgroup like ... the group approved and a moderator set up, you would also need to get ...
    (comp.lang.fortran)
  • Re: Fortran subroutine characters args and their lengths and C
    ... that newsgroup concerning implementation of numerical analysis algorithm in either C or Fortran or C++. ... For well known reasons in the field, mixture of C and Fortran or C++ and Fortran is quite common. ... So the query was quite on topic in that group. ...
    (comp.lang.c)
  • Re: Fortran subroutine characters args and their lengths and C
    ... There are numerous queries on that newsgroup concerning implementation of numerical analysis algorithm in either C or Fortran or C++. ... For well known reasons in the field, mixture of C and Fortran or C++ and Fortran is quite common. ... So the query was quite on topic in that group. ...
    (comp.lang.fortran)

Loading