00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013 #include "f2c.h"
00014 #include "blaswrap.h"
00015
00016
00017
00018 struct {
00019 integer infot, nout;
00020 logical ok, lerr;
00021 } infoc_;
00022
00023 #define infoc_1 infoc_
00024
00025 struct {
00026 char srnamt[32];
00027 } srnamc_;
00028
00029 #define srnamc_1 srnamc_
00030
00031
00032
00033 static integer c__0 = 0;
00034 static integer c__1 = 1;
00035 static integer c_n1 = -1;
00036 static integer c__2 = 2;
00037
00038 int derrac_(integer *nunit)
00039 {
00040
00041 static char fmt_9999[] = "(1x,a6,\002 drivers passed the tests of the er"
00042 "ror exits\002)";
00043 static char fmt_9998[] = "(\002 *** \002,a6,\002 drivers failed the test"
00044 "s of the error \002,\002exits ***\002)";
00045
00046
00047 integer s_wsle(cilist *), e_wsle(void);
00048 int s_copy(char *, char *, ftnlen, ftnlen);
00049 integer s_wsfe(cilist *), do_fio(integer *, char *, ftnlen), e_wsfe(void);
00050
00051
00052 doublereal a[16] , b[4], c__[4];
00053 integer i__, j;
00054 doublereal r__[4], w[8], x[4], r1[4], r2[4], af[16] ;
00055 integer info, iter;
00056 doublereal work[16];
00057 real swork[16];
00058 extern int chkxer_(char *, integer *, integer *, logical
00059 *, logical *), dsposv_(char *, integer *, integer *,
00060 doublereal *, integer *, doublereal *, integer *, doublereal *,
00061 integer *, doublereal *, real *, integer *, integer *);
00062
00063
00064 static cilist io___1 = { 0, 0, 0, 0, 0 };
00065 static cilist io___17 = { 0, 0, 0, fmt_9999, 0 };
00066 static cilist io___18 = { 0, 0, 0, fmt_9998, 0 };
00067
00068
00069
00070
00071
00072
00073
00074
00075
00076
00077
00078
00079
00080
00081
00082
00083
00084
00085
00086
00087
00088
00089
00090
00091
00092
00093
00094
00095
00096
00097
00098
00099
00100
00101
00102
00103
00104
00105
00106 infoc_1.nout = *nunit;
00107 io___1.ciunit = infoc_1.nout;
00108 s_wsle(&io___1);
00109 e_wsle();
00110
00111
00112
00113 for (j = 1; j <= 4; ++j) {
00114 for (i__ = 1; i__ <= 4; ++i__) {
00115 a[i__ + (j << 2) - 5] = 1. / (doublereal) (i__ + j);
00116 af[i__ + (j << 2) - 5] = 1. / (doublereal) (i__ + j);
00117
00118 }
00119 b[j - 1] = 0.;
00120 r1[j - 1] = 0.;
00121 r2[j - 1] = 0.;
00122 w[j - 1] = 0.;
00123 x[j - 1] = 0.;
00124 c__[j - 1] = 0.;
00125 r__[j - 1] = 0.;
00126
00127 }
00128 infoc_1.ok = TRUE_;
00129
00130 s_copy(srnamc_1.srnamt, "DSPOSV", (ftnlen)32, (ftnlen)6);
00131 infoc_1.infot = 1;
00132 dsposv_("/", &c__0, &c__0, a, &c__1, b, &c__1, x, &c__1, work, swork, &
00133 iter, &info);
00134 chkxer_("DSPOSV", &infoc_1.infot, &infoc_1.nout, &infoc_1.lerr, &
00135 infoc_1.ok);
00136 infoc_1.infot = 2;
00137 dsposv_("U", &c_n1, &c__0, a, &c__1, b, &c__1, x, &c__1, work, swork, &
00138 iter, &info);
00139 chkxer_("DSPOSV", &infoc_1.infot, &infoc_1.nout, &infoc_1.lerr, &
00140 infoc_1.ok);
00141 infoc_1.infot = 3;
00142 dsposv_("U", &c__0, &c_n1, a, &c__1, b, &c__1, x, &c__1, work, swork, &
00143 iter, &info);
00144 chkxer_("DSPOSV", &infoc_1.infot, &infoc_1.nout, &infoc_1.lerr, &
00145 infoc_1.ok);
00146 infoc_1.infot = 5;
00147 dsposv_("U", &c__2, &c__1, a, &c__1, b, &c__2, x, &c__2, work, swork, &
00148 iter, &info);
00149 chkxer_("DSPOSV", &infoc_1.infot, &infoc_1.nout, &infoc_1.lerr, &
00150 infoc_1.ok);
00151 infoc_1.infot = 7;
00152 dsposv_("U", &c__2, &c__1, a, &c__2, b, &c__1, x, &c__2, work, swork, &
00153 iter, &info);
00154 chkxer_("DSPOSV", &infoc_1.infot, &infoc_1.nout, &infoc_1.lerr, &
00155 infoc_1.ok);
00156 infoc_1.infot = 9;
00157 dsposv_("U", &c__2, &c__1, a, &c__2, b, &c__2, x, &c__1, work, swork, &
00158 iter, &info);
00159 chkxer_("DSPOSV", &infoc_1.infot, &infoc_1.nout, &infoc_1.lerr, &
00160 infoc_1.ok);
00161
00162
00163
00164 if (infoc_1.ok) {
00165 io___17.ciunit = infoc_1.nout;
00166 s_wsfe(&io___17);
00167 do_fio(&c__1, "DSPOSV", (ftnlen)6);
00168 e_wsfe();
00169 } else {
00170 io___18.ciunit = infoc_1.nout;
00171 s_wsfe(&io___18);
00172 do_fio(&c__1, "DSPOSV", (ftnlen)6);
00173 e_wsfe();
00174 }
00175
00176
00177 return 0;
00178
00179
00180
00181 }