Skip to main content

  | मौसम…

411 समाचार
Public archive edition · Attributed source reporting with original dates · AI drafts are excluded

411 REFERENCE · Wikibooks

Linear Algebra and the C Language/a0eb

Reference material by Wikibooks contributors. This retains its source identity and is not 411 news reporting.

__NOTOC__ Install this file in your working directory. /* ------------------------------------ */ /* Save as : dg_uv.h */ /* ------------------------------------ */ void G_points2D_mR( W_Ctrl w, double **A, double **B ) { FILE *fp; int c; fp = fopen("a_main.plt","w"); fprintf(fp, " reset\n" " set zeroaxis\n" " set size ratio -1\n" " plot[%0.3f:%0.3f] [%0.3f:%0.3f]\\\n" " \"aU.plt\" with line,\\\n" " \"aV.plt\" with line\n", w.xmini,w.xmaxi,w.ymini,w.ymaxi); fclose(fp); fp = fopen("aU.plt","w"); for(c=C1; c<A[C_SIZE][C0]; c++) fprintf(fp," %+.3f %+.3f \n",A[1][c],A[2][c]); fclose(fp); fp = fopen("aV.plt","w"); for(c=C1; c<B[C_SIZE][C0]; c++) fprintf(fp," %+.3f %+.3f \n",B[1][c],B[2][c]); fclose(fp); printf( " * open the file main.plt with Gnuplot. (Windows)\n" " * Use the command into Gnuplot : load \"a_main.plt\" (Linux)\n\n"); } /* ------------------------------------ */ /* ------------------------------------ */