Cadabra
Computer algebra system for field theory problems
Toggle main menu visibility
Loading...
Searching...
No Matches
core
Kernel.hh
Go to the documentation of this file.
1
2
#pragma once
3
4
#include <functional>
5
#include "
Props.hh
"
6
12
13
namespace
cadabra
{
14
15
class
Kernel
{
16
public
:
17
Kernel
(
bool
inject_defaults=
true
);
18
Kernel
(
const
Kernel
& other) =
delete
;
19
~Kernel
();
20
23
void
inject_property
(
property
*prop, std::shared_ptr<Ex>
pattern
, std::shared_ptr<Ex> property_arguments);
24
26
std::shared_ptr<Ex>
ex_from_string
(
const
std::string&);
27
28
29
Properties
properties
;
30
32
enum class
scalar_backend_t
{
sympy
,
mathematica
}
scalar_backend
;
33
bool
call_embedded_python_functions
;
34
bool
display_fractions
;
35
36
37
const
static
std::string
version
;
38
const
static
std::string
build
;
39
40
// Warnings
41
enum class
warn_t
{
42
notset
= 0,
43
debug
= 10,
44
info
= 20,
45
warning
= 30,
46
error
= 40,
47
critical
= 50
48
};
49
warn_t
warning_level
;
50
std::function<void(
const
std::string&)>
warning_callback
;
51
void
warn
(
const
std::string& msg,
warn_t
level =
warn_t::warning
)
const
;
52
};
53
54
}
Props.hh
cadabra::Kernel::call_embedded_python_functions
bool call_embedded_python_functions
Definition
Kernel.hh:33
cadabra::Kernel::scalar_backend_t
scalar_backend_t
Settings.
Definition
Kernel.hh:32
cadabra::Kernel::scalar_backend_t::mathematica
@ mathematica
Definition
Kernel.hh:32
cadabra::Kernel::properties
Properties properties
Definition
Kernel.hh:29
cadabra::Kernel::version
static const std::string version
Definition
Kernel.hh:37
cadabra::Kernel::inject_property
void inject_property(property *prop, std::shared_ptr< Ex > pattern, std::shared_ptr< Ex > property_arguments)
Inject a property into the system and attach it to the given pattern.
Definition
Kernel.cc:115
cadabra::Kernel::build
static const std::string build
Definition
Kernel.hh:38
cadabra::Kernel::warning_callback
std::function< void(const std::string &)> warning_callback
Definition
Kernel.hh:50
cadabra::Kernel::Kernel
Kernel(bool inject_defaults=true)
Definition
Kernel.cc:28
cadabra::Kernel::ex_from_string
std::shared_ptr< Ex > ex_from_string(const std::string &)
Create an Ex expression object from a string, which will be parsed.
Definition
Kernel.cc:130
cadabra::Kernel::~Kernel
~Kernel()
Definition
Kernel.cc:110
cadabra::Kernel::warn
void warn(const std::string &msg, warn_t level=warn_t::warning) const
Definition
Kernel.cc:142
cadabra::Kernel::display_fractions
bool display_fractions
Definition
Kernel.hh:34
cadabra::Kernel::Kernel
Kernel(const Kernel &other)=delete
cadabra::Kernel::warning_level
warn_t warning_level
Definition
Kernel.hh:49
cadabra::Kernel::scalar_backend
enum cadabra::Kernel::scalar_backend_t scalar_backend
cadabra::Kernel::warn_t
warn_t
Definition
Kernel.hh:41
cadabra::Kernel::warn_t::notset
@ notset
Definition
Kernel.hh:42
cadabra::Kernel::warn_t::warning
@ warning
Definition
Kernel.hh:45
cadabra::Kernel::warn_t::critical
@ critical
Definition
Kernel.hh:47
cadabra::Kernel::warn_t::debug
@ debug
Definition
Kernel.hh:43
cadabra::Kernel::warn_t::info
@ info
Definition
Kernel.hh:44
cadabra::Kernel::warn_t::error
@ error
Definition
Kernel.hh:46
cadabra::Properties
Class holding a collection of properties attached to expressions.
Definition
Props.hh:242
cadabra::pattern
Definition
Props.hh:39
cadabra::property
Base class for all properties, handling argument parsing and defining the interface.
Definition
Props.hh:127
cadabra
Functions to handle the exchange properties of two or more symbols in a product.
Definition
Adjform.cc:83
sympy
Definition
SympyCdb.hh:14
Generated by
1.17.0