Mercurial > octave-libtiff
comparison liboctave/numeric/ODEFunc.h @ 30898:51a3d3a69193
maint: Use "fcn" as preferred abbreviation for "function" in liboctave/.
* DAEFunc.h, DASPK.cc, DASSL.cc, LSODE.cc, ODEFunc.h, eigs-base.cc,
eigs-base.h, oct-norm.cc, mx-inlines.cc:
Replace "func", "fun" in documentation and variable names with "fcn".
author | Rik <rik@octave.org> |
---|---|
date | Tue, 05 Apr 2022 13:20:48 -0700 |
parents | 796f54d4ddbf |
children |
comparison
equal
deleted
inserted
replaced
30897:260ce8667d96 | 30898:51a3d3a69193 |
---|---|
37 | 37 |
38 typedef ColumnVector (*ODERHSFunc) (const ColumnVector&, double); | 38 typedef ColumnVector (*ODERHSFunc) (const ColumnVector&, double); |
39 typedef Matrix (*ODEJacFunc) (const ColumnVector&, double); | 39 typedef Matrix (*ODEJacFunc) (const ColumnVector&, double); |
40 | 40 |
41 ODEFunc (void) | 41 ODEFunc (void) |
42 : m_fun (nullptr), m_jac (nullptr), m_reset (true) { } | 42 : m_fcn (nullptr), m_jac (nullptr), m_reset (true) { } |
43 | 43 |
44 ODEFunc (ODERHSFunc f) | 44 ODEFunc (ODERHSFunc f) |
45 : m_fun (f), m_jac (nullptr), m_reset (true) { } | 45 : m_fcn (f), m_jac (nullptr), m_reset (true) { } |
46 | 46 |
47 ODEFunc (ODERHSFunc f, ODEJacFunc j) | 47 ODEFunc (ODERHSFunc f, ODEJacFunc j) |
48 : m_fun (f), m_jac (j), m_reset (true) { } | 48 : m_fcn (f), m_jac (j), m_reset (true) { } |
49 | 49 |
50 ODEFunc (const ODEFunc& a) | 50 ODEFunc (const ODEFunc& a) |
51 : m_fun (a.m_fun), m_jac (a.m_jac), m_reset (true) { } | 51 : m_fcn (a.m_fcn), m_jac (a.m_jac), m_reset (true) { } |
52 | 52 |
53 ODEFunc& operator = (const ODEFunc& a) | 53 ODEFunc& operator = (const ODEFunc& a) |
54 { | 54 { |
55 if (this != &a) | 55 if (this != &a) |
56 { | 56 { |
57 m_fun = a.m_fun; | 57 m_fcn = a.m_fcn; |
58 m_jac = a.m_jac; | 58 m_jac = a.m_jac; |
59 m_reset = a.m_reset; | 59 m_reset = a.m_reset; |
60 } | 60 } |
61 return *this; | 61 return *this; |
62 } | 62 } |
63 | 63 |
64 virtual ~ODEFunc (void) = default; | 64 virtual ~ODEFunc (void) = default; |
65 | 65 |
66 ODERHSFunc function (void) const { return m_fun; } | 66 ODERHSFunc function (void) const { return m_fcn; } |
67 | 67 |
68 ODEFunc& set_function (ODERHSFunc f) | 68 ODEFunc& set_function (ODERHSFunc f) |
69 { | 69 { |
70 m_fun = f; | 70 m_fcn = f; |
71 m_reset = true; | 71 m_reset = true; |
72 return *this; | 72 return *this; |
73 } | 73 } |
74 | 74 |
75 ODEJacFunc jacobian_function (void) const { return m_jac; } | 75 ODEJacFunc jacobian_function (void) const { return m_jac; } |
81 return *this; | 81 return *this; |
82 } | 82 } |
83 | 83 |
84 protected: | 84 protected: |
85 | 85 |
86 ODERHSFunc m_fun; | 86 ODERHSFunc m_fcn; |
87 ODEJacFunc m_jac; | 87 ODEJacFunc m_jac; |
88 | 88 |
89 // This variable is TRUE when this object is constructed, and also | 89 // This variable is TRUE when this object is constructed, and also |
90 // after any internal data has changed. Derived classes may use | 90 // after any internal data has changed. Derived classes may use |
91 // this information (and change it) to know when to (re)initialize | 91 // this information (and change it) to know when to (re)initialize |