/* LIBRARY V3.0 DQ2ROG TEST */
#include 
double *w;
main()
{
  int ncon = 2;
  int neq = 2;
  int nvar = 5;
  int lda = 2;
  int ldh = 5;
  int iact[5];
  int k;
  int nact;
  int nout;
  int i;
/*	*/
  static double a[2][5] = {1.0,0.0, 1.0,0.0, 1.0,1.0, 1.0,-2.0, 1.0,-2.0};
  static double alamda[5];
  static double b[2] = {5.0,-3.0};
  static double diag;
  static double g[5] = { -2.0, 0.0, 0.0, 0.0, 0.0}; static double h[5][5] = { 2.0, 0.0, 0.0, 0.0, 0.0, 0.0, 2.0,-2.0, 0.0, 0.0,0.0,-2.0, 2.0, 0.0, 0.0,0.0, 0.0, 0.0, 2.0,-2.0,0.0, 0.0, 0.0,-2.0, 2.0};
  static double sol[5];
  int	wk;
/*	*/
  wk = (3*nvar*nvar+11*nvar)+2*ncon;
  w = malloc(wk);
/*	*/
  dq2rog_ (&nvar, &ncon, &neq, a, &lda, b, g, h, &ldh, &diag, sol, &nact, iact, alamda, w);
/*	*/
  printf(" SOL = ¥n");
  for(i=0;i<5;i++) { printf("	%f¥n",sol[i]);};
}


***** コンハ゜イル リンク 実行 *****

%cc -c t_dq2rog.c
%f77 -o t_dq2rog -silent t_dq2rog.o $LINK_F77	:スタテックリンク
%t_dq2rog  : 実行

***** コンハ゜イル リンク 実行結果 *****
SOL =
1.000000
1.000000
1.000000
1.000000
1.000000