Xref: utzoo comp.lang.fortran:4964 comp.os.vms:36814 Path: utzoo!news-server.csri.toronto.edu!cs.utexas.edu!sdd.hp.com!zaphod.mps.ohio-state.edu!rpi!uwm.edu!linac!unixhub!slacvm!kencb From: KENCB@SLACVM.SLAC.STANFORD.EDU Newsgroups: comp.lang.fortran,comp.os.vms Subject: Re: Looking for QEXTD codes Message-ID: <91076.002220KENCB@SLACVM.SLAC.STANFORD.EDU> Date: 17 Mar 91 08:22:19 GMT References: <1186@earth.cs.utexas.edu> Organization: Stanford Linear Accelerator Center Lines: 46 In article <1186@earth.cs.utexas.edu>, jhpark@cs.utexas.edu (Jihun Park) says: >I am looking for a routine named QEXTD which converts single precision(?) >to double precision number. I heard this is only supported on VMS/Fortran. >But I am using UNIX so I can not access QEXTD. Does anybody out there can >provide me source codes of QEXTD ? I can't help with C-code, but I can help with what QEXT *does*. QEXT is the generic "convert to REAL*16" intrinsic function, QEXTD is the _specific_ version used to convert REAL*8 to REAL*16. From the VMS Fortran help file: FORTRAN Intrinsic_Functions QEXT QEXT (number) A function that converts the argument to a REAL*16 value. +------+---------+----------+------------+-------------+ | Args | Generic | Specific | Argument | Result Type | +------+---------+----------+------------+-------------+ | 1 | QEXT | QEXT | INTEGER*2 | REAL*16 | | | | QEXT | INTEGER*4 | REAL*16 | | | | QEXT | REAL*4 | REAL*16 | | | | QEXTD | REAL*8 | REAL*16 | | | | QEXT | REAL*16 | REAL*16 | | | | QEXT | COMPLEX*8 | REAL*16 | | | | QEXT | COMPLEX*16 | REAL*16 | +------+---------+----------+------------+-------------+ If your Unix system supports quadword real's, just do the extend from the double precision. If the hardware doesn't support it, you'll need to write a whole library of REAL*16 math functions. Do you need that? -Ken Dr. Kenneth H. Fairfield Internet: Fairfield@Tpc.Slac.Stanford.Edu SLAC, P.O.Box 4349, Bin 98 DECnet: 45047::FAIRFIELD (TPC::) Stanford, CA 94309 BITNET Fairfield@SlacTpc "These opinions are worth what you paid for 'em... ...and are they mine, not SLAC's, Stanford's, nor the DOE's..."