mirror of
https://github.com/triqs/dft_tools
synced 2024-12-26 14:23:38 +01:00
gfs: cleaning code.
Using construction delegation to simplify code.
This commit is contained in:
parent
cbf2142af6
commit
e48a451550
@ -36,10 +36,7 @@ namespace triqs { namespace gfs {
|
|||||||
gf_mesh() = default;
|
gf_mesh() = default;
|
||||||
gf_mesh (typename B::domain_t const & d, int Nmax = 1025) :
|
gf_mesh (typename B::domain_t const & d, int Nmax = 1025) :
|
||||||
B(d, d.statistic==Fermion?m1(d.beta):0, d.statistic==Fermion?(2*Nmax+1)*m1(d.beta): 2*Nmax*m1(d.beta), Nmax, without_last){}
|
B(d, d.statistic==Fermion?m1(d.beta):0, d.statistic==Fermion?(2*Nmax+1)*m1(d.beta): 2*Nmax*m1(d.beta), Nmax, without_last){}
|
||||||
// use delegating...
|
gf_mesh (double beta, statistic_enum S, int Nmax = 1025) : gf_mesh({beta,S}, Nmax){}
|
||||||
gf_mesh (double beta, statistic_enum S, int Nmax = 1025) :
|
|
||||||
//gf_mesh({beta,S}, Nmax){}
|
|
||||||
B(typename B::domain_t(beta,S), S==Fermion?m1(beta):0, S==Fermion?(2*Nmax+1)*m1(beta): 2*Nmax*m1(beta), Nmax, without_last){}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
namespace gfs_implementation {
|
namespace gfs_implementation {
|
||||||
|
@ -35,11 +35,8 @@ namespace triqs { namespace gfs {
|
|||||||
template<typename Opt> struct gf_mesh<imtime,Opt> : linear_mesh<matsubara_domain<false>> {
|
template<typename Opt> struct gf_mesh<imtime,Opt> : linear_mesh<matsubara_domain<false>> {
|
||||||
typedef linear_mesh<matsubara_domain<false>> B;
|
typedef linear_mesh<matsubara_domain<false>> B;
|
||||||
gf_mesh() = default;
|
gf_mesh() = default;
|
||||||
gf_mesh (typename B::domain_t d, int n_time_slices, mesh_kind mk=half_bins):
|
gf_mesh(typename B::domain_t d, int n_time_slices, mesh_kind mk = half_bins) : B(d, 0, d.beta, n_time_slices, mk) {}
|
||||||
B( d, 0, d.beta, n_time_slices, mk){}
|
gf_mesh (double beta, statistic_enum S, int n_time_slices, mesh_kind mk=half_bins): gf_mesh( {beta,S}, n_time_slices, mk){}
|
||||||
gf_mesh (double beta, statistic_enum S, int n_time_slices, mesh_kind mk=half_bins):
|
|
||||||
//gf_mesh( {beta,S}, n_time_slices, mk){}
|
|
||||||
B( typename B::domain_t(beta,S), 0, beta, n_time_slices, mk){}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
namespace gfs_implementation {
|
namespace gfs_implementation {
|
||||||
|
Loading…
Reference in New Issue
Block a user