Mercurial > hg > octave-nkf
comparison src/expm.cc @ 497:88614b380d6e
[project @ 1994-07-08 02:00:57 by jwe]
author | jwe |
---|---|
date | Fri, 08 Jul 1994 02:08:37 +0000 |
parents | 393e95f46b51 |
children | 0f388340e607 |
comparison
equal
deleted
inserted
replaced
496:e7c5b23b34d3 | 497:88614b380d6e |
---|---|
41 #include "gripes.h" | 41 #include "gripes.h" |
42 #include "error.h" | 42 #include "error.h" |
43 #include "f-expm.h" | 43 #include "f-expm.h" |
44 | 44 |
45 #ifdef WITH_DLD | 45 #ifdef WITH_DLD |
46 tree_constant * | 46 Octave_object |
47 builtin_matrix_exp_2 (const tree_constant *args, int nargin, int nargout) | 47 builtin_matrix_exp_2 (const Octave_object& args, int nargin, int nargout) |
48 { | 48 { |
49 tree_constant *retval = new tree_constant [2]; | 49 Octave_object retval (1); |
50 retval[0] = matrix_exp (args[1]); | 50 retval(0) = matrix_exp (args(1)); |
51 return retval; | 51 return retval; |
52 } | 52 } |
53 #endif | 53 #endif |
54 | 54 |
55 extern "C" | 55 extern "C" |
67 tree_constant retval; | 67 tree_constant retval; |
68 tree_constant tmp = a.make_numeric (); | 68 tree_constant tmp = a.make_numeric (); |
69 | 69 |
70 // Constants for matrix exponential calculation. | 70 // Constants for matrix exponential calculation. |
71 | 71 |
72 static double padec[] = | 72 static double padec [] = |
73 { | 73 { |
74 5.0000000000000000e-1, | 74 5.0000000000000000e-1, |
75 1.1666666666666667e-1, | 75 1.1666666666666667e-1, |
76 1.6666666666666667e-2, | 76 1.6666666666666667e-2, |
77 1.6025641025641026e-3, | 77 1.6025641025641026e-3, |