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/a0dk

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

__NOTOC__ Install and compile this file in your working directory. /* ------------------------------------ */ /* Save as: c00b.c */ /* ------------------------------------ */ #include "v_a.h" /* ------------------------------------ */ #define RCA C3 /* ------------------------------------ */ int main(void) { double a[RCA*RCA]={ +9,+9,+8, +9,+6,+2, +8,+2,+3 }; double **A = ca_A_mR(a, i_mR(RCA,RCA)); double **EValue = eigs_mR(A, i_mR(RCA,C1)); clrscrn(); printf(" Copy/Paste into the octave windows \n\n"); p_Octave_mR(A,"a",P0); printf(" EValue = eigs (a,%d) \n\n",RCA); printf(" EValue:"); p_mR(EValue,S13,P6,C1); stop(); f_mR(A); f_mR(EValue); return 0; } /* ------------------------------------ */ /* ------------------------------------ */ Screen output example: Copy/Paste into the octave windows a=[ +9,+9,+8; +9,+6,+2; +8,+2,+3] EValue = eigs (a,3) EValue: +19.969678 -4.396009 +2.426331 Press return to continue.