Fortran: Difference between revisions

Jump to navigation Jump to search
53 bytes removed ,  29 November 2012
no edit summary
(Created page with " {{Code|C++ function to load a matrix from an ASCII file in Octave native format|<syntaxhighlight lang="C" style="font-size:13px"> #include <octave_file_io.h> #include <oct...")
 
No edit summary
Line 41: Line 41:
   *data = (double*) malloc (M.numel () * sizeof (double));
   *data = (double*) malloc (M.numel () * sizeof (double));
   *numel = M.numel ();
   *numel = M.numel ();
  std::cout << M << std::endl << *numel << std::endl;
 
   memcpy (*data, M.fortran_vec (), *numel * sizeof (double));
   memcpy (*data, M.fortran_vec (), *numel * sizeof (double));


349

edits

Navigation menu