Home     |     .Net Programming    |     cSharp Home    |     Sql Server Home    |     Javascript / Client Side Development     |     Ajax Programming

Ruby on Rails Development     |     Perl Programming     |     C Programming Language     |     C++ Programming     |     IT Jobs

Python Programming Language     |     Laptop Suggestions?    |     TCL Scripting     |     Fortran Programming     |     Scheme Programming Language


 
 
Cervo Technologies
The Right Source to Outsource

MS Dynamics CRM 3.0

Fortran Programming Language

Problem linking with Fortran NAG library


Hi there,

I'm trying to compile some code that uses the Fortran NAG library. I'm
not sure how to link to the library, however.

When I type

g95 nhmm.f forbac.f makea.f objfun.f sumpi.f variance.f viterbi.f
condsim.f  beta.f cmlib.f dldp.f emalg.f

I get the following link errors. I am running Debian Sarge (3.1)

/tmp/ccwUzgR2.o(.text+0x19a): In function `emalg_':
: undefined reference to `e04uef_'
/tmp/ccwUzgR2.o(.text+0x1ae): In function `emalg_':
: undefined reference to `e04uef_'
/tmp/ccwUzgR2.o(.text+0x1c2): In function `emalg_':
: undefined reference to `e04uef_'
/tmp/ccwUzgR2.o(.text+0x1d6): In function `emalg_':
: undefined reference to `e04uef_'
/tmp/ccwUzgR2.o(.text+0x1ea): In function `emalg_':
: undefined reference to `e04uef_'
/tmp/ccwUzgR2.o(.text+0x47c): more undefined references to `e04uef_'
follow
/tmp/ccwUzgR2.o(.text+0xbe0): In function `stepps_':
: undefined reference to `e04ucf_'

Thank you,

Patrick

On May 6, 6:11 pm, prynh@gmail.com wrote:

> Hi there,

> I'm trying to compile some code that uses the Fortran NAG library. I'm
> not sure how to link to the library, however.

> When I type

> g95 nhmm.f forbac.f makea.f objfun.f sumpi.f variance.f viterbi.f
> condsim.f  beta.f cmlib.f dldp.f emalg.f

> I get the following link errors. I am running Debian Sarge (3.1)

To use the NAG library, one must PURCHASE object code for the NAG
library specific to a compiler and operating system. Have you done so?
I don't think the NAG library is distributed for g95 or gfortran. The
routine E04UCF

"is designed to minimize an arbitrary smooth function subject to
constraints (which may
include simple bounds on the variables, linear constraints and smooth
nonlinear constraints) using a
sequential quadratic programming (SQP) method."

There exist free Fortran codes with similar functionality, and you
could try substituting one of them.

> To use the NAG library, one must PURCHASE object code for the NAG
> library specific to a compiler and operating system. Have you done so?

Thank you for this. No I haven't purchased any code - I just tried
compiling some code that I inherited "out of the box".

> I don't think the NAG library is distributed for g95 or gfortran. The
> routine E04UCF

> "is designed to minimize an arbitrary smooth function subject to
> constraints (which may
> include simple bounds on the variables, linear constraints and smooth
> nonlinear constraints) using a
> sequential quadratic programming (SQP) method."

> There exist free Fortran codes with similar functionality, and you
> could try substituting one of them.

Do you know where I would find such codes ? I'm new to Fortran;
basically I'm trying to get some code that I've been given to run...

Thanks again,

Patrick

On May 6, 8:51 pm, prynh@gmail.com wrote:

You can search "minimiz" and "optimiz" at Alan Miller's site
http://users.bigpond.net.au/amiller/ (for nonlinearly constrained
optimization, cobyla may work). Some other places to look are
Open Directory: Fortran: Source Code: Optimization
http://dmoz.org/Computers/Programming/Languages/Fortran/Source_Code/O...
NEOS Guide Optimization Tree http://www-fp.mcs.anl.gov/otc/Guide/OptWeb/index.html
Netlib http://www.netlib.org/opt/ .
On May 6, 7:11 pm, Beliavsky <beliav@aol.com> wrote:

Thanks!
Add to del.icio.us | Digg this | Stumble it | Powered by Megasolutions Inc