.. highlight:: c .. _gf_block: Block Green functions ======================= This is a specialisation of :ref:`gf_and_view` for block functions. A block Green function is nothing but Green function on a discrete domain representing the block indices, and whose value is itself a Green function. For convenience, the following aliases are provided :: template using block_gf = gf >; template using block_gf_view = gf_view >; template using block_gf_const_view = gf_const_view>; Constructors -------------- The constructors of the gf. target_shape_t = {} Factories ------------- Also several factories are provided for these block Green functions. Factories for the regular type ..................................... The factories for the regular type *gf* are :: // From a number and a gf to be copied template block_gf make_block_gf(int n, gf const & g); // From a vector of gf (moving directly) template block_gf make_block_gf(std::vector> V); // From a vector of gf or views (a gf must be contructible from GF2) template block_gf make_block_gf(std::vector const &V); // From a init list of GF with the correct type template block_gf make_block_gf(std::initializer_list> const &V); // From vector and a gf to be copied template block_gf make_block_gf(std::vector block_names, gf const &g); // From vector, vector template block_gf make_block_gf(std::vector block_names, std::vector> V); // From vector, init_list template block_gf make_block_gf(std::vector block_names, std::initializer_list> const &V); Factories for the view type ..................................... The factories for the view type *gf_view*, *gf_const_view* are :: // Build a view of the gf. // 1- All Green functions must have the same type // 2- [Expert only] This is a simplified version of the code. // In the real code, the reference is of stripped from G in the type deduction. template gf_view make_block_gf_view(G && ... g); // Make a view from a vector of gf template gf_view make_block_gf_view_from_vector (std::vector V); Domain & mesh ---------------- The domain is a discrete domain ... Singularity ------------- None. Interpolation method --------------------- None. Data storage --------------- Not exposed to user. HDF5 storage convention --------------------------- TO BE WRITTEN. Iterators ----------- TO BE COMPLETED. Block gf have a natural iterator, e.g. :: // if a BG is block function for (auto & g : BG) .... Examples --------- .. triqs_example:: ./gf_block_0.cpp