/**************************************************************************/
/*                                                                        */
/*                                 Sources                                */
/*                                from  the                               */
/*                           XSC SOFTWARE PACKAGE                         */
/*                                                                        */
/*                Copyright (c) 1997 University of Karlsruhe              */
/*                     Institute for Appl. Mathematics                    */
/*                                                                        */
/* This program is free software for non-commercial use. For details, see */
/* the file LICENSE.XSC, distributed with this software package.          */
/*                                                                        */
/* This program is distributed WITHOUT ANY WARRANTY. For details, see the */
/* file LICENSE.XSC, distributed with this software package.              */
/*                                                                        */
/**************************************************************************/

/* RCS $Id: z_dsta.c,v 1.2 1997/09/25 18:28:42 ae59 Exp $ */
/*
$Log: z_dsta.c,v $
 * Revision 1.2  1997/09/25  18:28:42  ae59
 * Copyright-message
 *
 * Revision 1.1  1994/01/27  13:26:04  ae59
 * Put under RCS control
 *
 */
/****************************************************************/
/*                                                              */
/*      Filename        : z_dsta.c                              */
/*                                                              */
/*      Entries         : d_otpz z_dsta(ZRI,ZII,ZRS,ZIS)        */
/*                        dotprecision ZRI,ZII,ZRS,ZIS;         */
/*                                                              */
/*      Arguments       : ZRI=dotprecision value(real lower)    */
/*                        ZII=dotprecision value(imag lower)    */
/*                        ZRS=dotprecision value(real upper)    */
/*                        ZIS=dotprecision value(imag upper)    */
/*                                                              */
/*      Description     : Convert complex interval dotprec.     */
/*                                                              */
/*      Date            : 1992-07-22                            */
/*      1992-07-22 : changed local vars, initial. =b=           */
/*      1992-02-27 : new routine                                */
/****************************************************************/

#ifndef ALL_IN_ONE
#ifdef AIX
#include "/u/p88c/runtime/o_defs.h"
#else
#include "o_defs.h"
#endif
#define local
#endif

#ifdef LINT_ARGS
local d_otpz z_dsta (dotprecision ZRI,dotprecision ZII,dotprecision ZRS,
                     dotprecision ZIS)
#else
local d_otpz z_dsta ( ZRI, ZII, ZRS, ZIS)

dotprecision ZRI;
dotprecision ZII;
dotprecision ZRS;
dotprecision ZIS;
#endif
{
        d_otpz  res;
        d_otpz *ptemp= &res;
        d_otpi *pctemp;

        E_TPUSH("z_dsta")

        d_vlcp(&ZRI);
        d_vlcp(&ZII);
        d_vlcp(&ZRS);
        d_vlcp(&ZIS);

        pctemp= &(ptemp)->RE;
        d_init((dotprecision*) &(pctemp)->INF);
        d_init((dotprecision*) &(pctemp)->SUP);

        pctemp= &(ptemp)->IM;
        d_init((dotprecision*) &(pctemp)->INF);
        d_init((dotprecision*) &(pctemp)->SUP);
        
        d_ass(&res.RE.INF,ZRI);
        d_ass(&res.IM.INF,ZII);
        d_ass(&res.RE.SUP,ZRS);
        d_ass(&res.IM.SUP,ZIS);

        d_free( &ZRI);
        d_free( &ZII);
        d_free( &ZRS);
        d_free( &ZIS);

        ptemp= &res;
        pctemp= &(ptemp)->RE;
        d_temp((dotprecision*) &(pctemp)->INF);
        d_temp((dotprecision*) &(pctemp)->SUP);

        pctemp= &(ptemp)->IM;
        d_temp((dotprecision*) &(pctemp)->INF);
        d_temp((dotprecision*) &(pctemp)->SUP);
        
        E_TPOPP("z_dsta")
        return res;
}
