annotate liboctave/numeric/ODEFunc.h @ 33636:3ec6fcce7715 default tip @

gui: Avoid using HAVE_QSCINTILLA in more header files. * gui-settings.h, settings-dialog.h: Don't include QScintilla header. Forward-declare QSciLexer class instead if necessary. Declare all member functions unconditionally. * gui-settings.cc (gui_settings::get_valid_lexer_styles, gui_settings::read_lexer_settings), settings-dialog.cc (settings_dialog::update_lexer, settings_dialog::get_lexer_settings, settings_dialog::write_lexer_settings): Define functions unconditionally. * gui-preferences-ed.h: Don't include QScintilla header. Remove definition of local variable os_eol_mode from header. * gui-preferences-ed.cc (os_eol_mode): Move definition of local variable here.
author Markus Mützel <markus.muetzel@gmx.de>
date Tue, 28 May 2024 14:54:58 +0200
parents 4b601ca024d5
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
27923
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
1 ////////////////////////////////////////////////////////////////////////
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
2 //
32632
2e484f9f1f18 maint: update Octave Project Developers copyright for the new year
John W. Eaton <jwe@octave.org>
parents: 31771
diff changeset
3 // Copyright (C) 1993-2024 The Octave Project Developers
27923
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
4 //
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
5 // See the file COPYRIGHT.md in the top-level directory of this
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
6 // distribution or <https://octave.org/copyright/>.
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
7 //
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
8 // This file is part of Octave.
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
9 //
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
10 // Octave is free software: you can redistribute it and/or modify it
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
11 // under the terms of the GNU General Public License as published by
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
12 // the Free Software Foundation, either version 3 of the License, or
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
13 // (at your option) any later version.
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
14 //
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
15 // Octave is distributed in the hope that it will be useful, but
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
16 // WITHOUT ANY WARRANTY; without even the implied warranty of
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
17 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
18 // GNU General Public License for more details.
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
19 //
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
20 // You should have received a copy of the GNU General Public License
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
21 // along with Octave; see the file COPYING. If not, see
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
22 // <https://www.gnu.org/licenses/>.
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
23 //
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
24 ////////////////////////////////////////////////////////////////////////
3
9a4c07481e61 [project @ 1993-08-08 01:20:23 by jwe]
jwe
parents:
diff changeset
25
20791
f7084eae3318 maint: Use Octave coding conventions for #if statements.
Rik <rik@octave.org>
parents: 19697
diff changeset
26 #if ! defined (octave_ODEFunc_h)
382
e02d6b664394 [project @ 1994-03-09 21:08:03 by jwe]
jwe
parents: 238
diff changeset
27 #define octave_ODEFunc_h 1
e02d6b664394 [project @ 1994-03-09 21:08:03 by jwe]
jwe
parents: 238
diff changeset
28
21244
1473547f50f5 include octave-config.h in public header files
John W. Eaton <jwe@octave.org>
parents: 20791
diff changeset
29 #include "octave-config.h"
1473547f50f5 include octave-config.h in public header files
John W. Eaton <jwe@octave.org>
parents: 20791
diff changeset
30
30508
6f07492c9c20 Provide header file with forward declarations of matrix types (bug #59820).
Markus Mützel <markus.muetzel@gmx.de>
parents: 30047
diff changeset
31 #include "mx-fwd.h"
3
9a4c07481e61 [project @ 1993-08-08 01:20:23 by jwe]
jwe
parents:
diff changeset
32
32628
ae4e19c0a2b1 maint: Place class name and class keyword on one line.
Rik <rik@octave.org>
parents: 31771
diff changeset
33 class ODEFunc
3
9a4c07481e61 [project @ 1993-08-08 01:20:23 by jwe]
jwe
parents:
diff changeset
34 {
9a4c07481e61 [project @ 1993-08-08 01:20:23 by jwe]
jwe
parents:
diff changeset
35 public:
9a4c07481e61 [project @ 1993-08-08 01:20:23 by jwe]
jwe
parents:
diff changeset
36
1536
26411f9c7603 [project @ 1995-10-05 05:41:26 by jwe]
jwe
parents: 1315
diff changeset
37 typedef ColumnVector (*ODERHSFunc) (const ColumnVector&, double);
26411f9c7603 [project @ 1995-10-05 05:41:26 by jwe]
jwe
parents: 1315
diff changeset
38 typedef Matrix (*ODEJacFunc) (const ColumnVector&, double);
26411f9c7603 [project @ 1995-10-05 05:41:26 by jwe]
jwe
parents: 1315
diff changeset
39
31771
21f9b34eb893 maint: Eliminate "(void)" in C++ function prototypes/declarations.
Rik <rik@octave.org>
parents: 31706
diff changeset
40 ODEFunc ()
30898
51a3d3a69193 maint: Use "fcn" as preferred abbreviation for "function" in liboctave/.
Rik <rik@octave.org>
parents: 30564
diff changeset
41 : m_fcn (nullptr), m_jac (nullptr), m_reset (true) { }
532
2ca256b77602 [project @ 1994-07-20 19:56:55 by jwe]
jwe
parents: 465
diff changeset
42
1536
26411f9c7603 [project @ 1995-10-05 05:41:26 by jwe]
jwe
parents: 1315
diff changeset
43 ODEFunc (ODERHSFunc f)
30898
51a3d3a69193 maint: Use "fcn" as preferred abbreviation for "function" in liboctave/.
Rik <rik@octave.org>
parents: 30564
diff changeset
44 : m_fcn (f), m_jac (nullptr), m_reset (true) { }
3
9a4c07481e61 [project @ 1993-08-08 01:20:23 by jwe]
jwe
parents:
diff changeset
45
1536
26411f9c7603 [project @ 1995-10-05 05:41:26 by jwe]
jwe
parents: 1315
diff changeset
46 ODEFunc (ODERHSFunc f, ODEJacFunc j)
30898
51a3d3a69193 maint: Use "fcn" as preferred abbreviation for "function" in liboctave/.
Rik <rik@octave.org>
parents: 30564
diff changeset
47 : m_fcn (f), m_jac (j), m_reset (true) { }
3
9a4c07481e61 [project @ 1993-08-08 01:20:23 by jwe]
jwe
parents:
diff changeset
48
1536
26411f9c7603 [project @ 1995-10-05 05:41:26 by jwe]
jwe
parents: 1315
diff changeset
49 ODEFunc (const ODEFunc& a)
30898
51a3d3a69193 maint: Use "fcn" as preferred abbreviation for "function" in liboctave/.
Rik <rik@octave.org>
parents: 30564
diff changeset
50 : m_fcn (a.m_fcn), m_jac (a.m_jac), m_reset (true) { }
3
9a4c07481e61 [project @ 1993-08-08 01:20:23 by jwe]
jwe
parents:
diff changeset
51
1536
26411f9c7603 [project @ 1995-10-05 05:41:26 by jwe]
jwe
parents: 1315
diff changeset
52 ODEFunc& operator = (const ODEFunc& a)
17769
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
53 {
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
54 if (this != &a)
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
55 {
30898
51a3d3a69193 maint: Use "fcn" as preferred abbreviation for "function" in liboctave/.
Rik <rik@octave.org>
parents: 30564
diff changeset
56 m_fcn = a.m_fcn;
30047
02e28f7e4d04 maint: use "m_" prefix for member variables DAERTFunc/ODEFunc classes in liboctave/numeric.
Rik <rik@octave.org>
parents: 29358
diff changeset
57 m_jac = a.m_jac;
02e28f7e4d04 maint: use "m_" prefix for member variables DAERTFunc/ODEFunc classes in liboctave/numeric.
Rik <rik@octave.org>
parents: 29358
diff changeset
58 m_reset = a.m_reset;
17769
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
59 }
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
60 return *this;
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
61 }
3
9a4c07481e61 [project @ 1993-08-08 01:20:23 by jwe]
jwe
parents:
diff changeset
62
31771
21f9b34eb893 maint: Eliminate "(void)" in C++ function prototypes/declarations.
Rik <rik@octave.org>
parents: 31706
diff changeset
63 virtual ~ODEFunc () = default;
1861
620a65533630 [project @ 1996-02-04 10:17:34 by jwe]
jwe
parents: 1844
diff changeset
64
31771
21f9b34eb893 maint: Eliminate "(void)" in C++ function prototypes/declarations.
Rik <rik@octave.org>
parents: 31706
diff changeset
65 ODERHSFunc function () const { return m_fcn; }
1536
26411f9c7603 [project @ 1995-10-05 05:41:26 by jwe]
jwe
parents: 1315
diff changeset
66
26411f9c7603 [project @ 1995-10-05 05:41:26 by jwe]
jwe
parents: 1315
diff changeset
67 ODEFunc& set_function (ODERHSFunc f)
17769
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
68 {
30898
51a3d3a69193 maint: Use "fcn" as preferred abbreviation for "function" in liboctave/.
Rik <rik@octave.org>
parents: 30564
diff changeset
69 m_fcn = f;
30047
02e28f7e4d04 maint: use "m_" prefix for member variables DAERTFunc/ODEFunc classes in liboctave/numeric.
Rik <rik@octave.org>
parents: 29358
diff changeset
70 m_reset = true;
17769
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
71 return *this;
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
72 }
3
9a4c07481e61 [project @ 1993-08-08 01:20:23 by jwe]
jwe
parents:
diff changeset
73
31771
21f9b34eb893 maint: Eliminate "(void)" in C++ function prototypes/declarations.
Rik <rik@octave.org>
parents: 31706
diff changeset
74 ODEJacFunc jacobian_function () const { return m_jac; }
3
9a4c07481e61 [project @ 1993-08-08 01:20:23 by jwe]
jwe
parents:
diff changeset
75
1536
26411f9c7603 [project @ 1995-10-05 05:41:26 by jwe]
jwe
parents: 1315
diff changeset
76 ODEFunc& set_jacobian_function (ODEJacFunc j)
17769
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
77 {
30047
02e28f7e4d04 maint: use "m_" prefix for member variables DAERTFunc/ODEFunc classes in liboctave/numeric.
Rik <rik@octave.org>
parents: 29358
diff changeset
78 m_jac = j;
02e28f7e4d04 maint: use "m_" prefix for member variables DAERTFunc/ODEFunc classes in liboctave/numeric.
Rik <rik@octave.org>
parents: 29358
diff changeset
79 m_reset = true;
17769
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
80 return *this;
49a5a4be04a1 maint: Use GNU style coding conventions for code in liboctave/
Rik <rik@octave.org>
parents: 17744
diff changeset
81 }
3
9a4c07481e61 [project @ 1993-08-08 01:20:23 by jwe]
jwe
parents:
diff changeset
82
9a4c07481e61 [project @ 1993-08-08 01:20:23 by jwe]
jwe
parents:
diff changeset
83 protected:
9a4c07481e61 [project @ 1993-08-08 01:20:23 by jwe]
jwe
parents:
diff changeset
84
30898
51a3d3a69193 maint: Use "fcn" as preferred abbreviation for "function" in liboctave/.
Rik <rik@octave.org>
parents: 30564
diff changeset
85 ODERHSFunc m_fcn;
30047
02e28f7e4d04 maint: use "m_" prefix for member variables DAERTFunc/ODEFunc classes in liboctave/numeric.
Rik <rik@octave.org>
parents: 29358
diff changeset
86 ODEJacFunc m_jac;
4049
a35a3c5d4740 [project @ 2002-08-16 08:54:31 by jwe]
jwe
parents: 2847
diff changeset
87
a35a3c5d4740 [project @ 2002-08-16 08:54:31 by jwe]
jwe
parents: 2847
diff changeset
88 // This variable is TRUE when this object is constructed, and also
a35a3c5d4740 [project @ 2002-08-16 08:54:31 by jwe]
jwe
parents: 2847
diff changeset
89 // after any internal data has changed. Derived classes may use
a35a3c5d4740 [project @ 2002-08-16 08:54:31 by jwe]
jwe
parents: 2847
diff changeset
90 // this information (and change it) to know when to (re)initialize
a35a3c5d4740 [project @ 2002-08-16 08:54:31 by jwe]
jwe
parents: 2847
diff changeset
91 // their own internal data related to this object.
a35a3c5d4740 [project @ 2002-08-16 08:54:31 by jwe]
jwe
parents: 2847
diff changeset
92
30047
02e28f7e4d04 maint: use "m_" prefix for member variables DAERTFunc/ODEFunc classes in liboctave/numeric.
Rik <rik@octave.org>
parents: 29358
diff changeset
93 bool m_reset;
382
e02d6b664394 [project @ 1994-03-09 21:08:03 by jwe]
jwe
parents: 238
diff changeset
94 };
3
9a4c07481e61 [project @ 1993-08-08 01:20:23 by jwe]
jwe
parents:
diff changeset
95
9a4c07481e61 [project @ 1993-08-08 01:20:23 by jwe]
jwe
parents:
diff changeset
96 #endif