Documentation of MARTY
A Modern ARtificial Theoretical phYsicist
multifunction.h
Go to the documentation of this file.
1 // This file is part of MARTY.
2 //
3 // MARTY is free software: you can redistribute it and/or modify
4 // it under the terms of the GNU General Public License as published by
5 // the Free Software Foundation, either version 3 of the License, or
6 // (at your option) any later version.
7 //
8 // MARTY is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 // GNU General Public License for more details.
12 //
13 // You should have received a copy of the GNU General Public License
14 // along with MARTY. If not, see <https://www.gnu.org/licenses/>.
15 
23 #pragma once
24 
25 #include "abstractgammasym.h"
26 
27 namespace sgl {
28 
30 
31  public:
32 
33  AbstractMultiFunction() = default;
34  AbstractMultiFunction(GExpr const &arg);
35  AbstractMultiFunction(std::vector<GExpr> const &arg);
36 
37  bool contains(csl::Index const &index) const override;
38 
39  size_t size() const override;
40  GExpr const &argument(size_t i) const override;
41  GExpr &argument(size_t i) override;
42  iterator begin() override;
43  const_iterator begin() const override;
44  iterator end() override;
45  const_iterator end() const override;
46 
47  void printArgs(std::ostream &out, char sep) const;
48 
49  protected:
50 
51  std::vector<GExpr> m_argument;
52  };
53 
55 
56  public:
57 
58  size_t size() const override;
59  GExpr const &argument(size_t i) const override;
60  GExpr &argument(size_t i) override;
61  iterator begin() override;
62  const_iterator begin() const override;
63  iterator end() override;
64  const_iterator end() const override;
65  };
66 
67 } // namesapce sgl
Definition: abstractgammasym.h:87
Definition: abstractgammasym.h:32
Definition: multifunction.h:54
Definition: multifunction.h:29
Contains the base class for the Symbolic Gamma Library (SGL) and the GExpr definition.
Definition: abstractgammasym.h:37