| 26 |
#include <string> |
#include <string> |
| 27 |
#include <vector> |
#include <vector> |
| 28 |
#include <ginac/basic.h> |
#include <ginac/basic.h> |
| 29 |
|
#include <ginac/ex.h> |
| 30 |
|
|
| 31 |
|
namespace GiNaC { |
| 32 |
|
|
| 33 |
class idx : public basic |
class idx : public basic |
| 34 |
{ |
{ |
| 92 |
extern const idx some_idx; |
extern const idx some_idx; |
| 93 |
extern type_info const & typeid_idx; |
extern type_info const & typeid_idx; |
| 94 |
|
|
| 95 |
// macros |
// utility functions |
| 96 |
|
inline const idx &ex_to_idx(const ex &e) |
| 97 |
#define ex_to_idx(X) (static_cast<idx const &>(*(X).bp)) |
{ |
| 98 |
|
return static_cast<const idx &>(*e.bp); |
| 99 |
|
} |
| 100 |
|
|
| 101 |
// other functions |
// global functions |
| 102 |
|
|
| 103 |
typedef vector<ex> exvector; |
typedef vector<ex> exvector; |
| 104 |
|
|
| 111 |
exvector const & idxv_co); |
exvector const & idxv_co); |
| 112 |
unsigned count_index(ex const & e, ex const & i); |
unsigned count_index(ex const & e, ex const & i); |
| 113 |
|
|
| 114 |
|
} // namespace GiNaC |
| 115 |
|
|
| 116 |
#endif // ndef __GINAC_IDX_H__ |
#endif // ndef __GINAC_IDX_H__ |