C++QEDElements  v2 Milestone 10
a framework for simulating open quantum dynamics – generic elements
ModeFunction.h
1 // Copyright András Vukics 2006–2014. Distributed under the Boost Software License, Version 1.0. (See accompanying file LICENSE.txt)
2 // -*- C++ -*-
3 #ifndef CPPQEDELEMENTS_UTILS_MODEFUNCTION_H_INCLUDED
4 #define CPPQEDELEMENTS_UTILS_MODEFUNCTION_H_INCLUDED
5 
6 #include "ComplexExtensions.h"
7 
8 #include <boost/tuple/tuple.hpp>
9 #include <boost/tuple/tuple_io.hpp>
10 
11 #include <iosfwd>
12 
13 enum ModeFunctionType {MFT_SIN, MFT_COS, MFT_PLUS, MFT_MINUS};
14 
15 inline bool isComplex(ModeFunctionType mf) {return (mf==MFT_PLUS || mf==MFT_MINUS);}
16 
17 std::ostream& operator<<(std::ostream&, ModeFunctionType);
18 std::istream& operator>>(std::istream&, ModeFunctionType&);
19 
20 
21 const dcomp modeFunction(ModeFunctionType,double);
22 
23 
24 typedef boost::tuple<ModeFunctionType,ptrdiff_t> ModeFunction;
25 
26 // std::ostream& operator<<(std::ostream&, const particle::ModeFunction&);
27 
28 #endif // CPPQEDELEMENTS_UTILS_MODEFUNCTION_H_INCLUDED
std::ostream & operator<<(std::ostream &, Method)
std::istream & operator>>(std::istream &, Method &)
std::complex< double > dcomp