H2Lib  3.0
Data Structures | Macros | Typedefs | Functions
clusterbasis.h File Reference
#include "cluster.h"
#include "clusteroperator.h"
#include "uniform.h"
#include "amatrix.h"

Go to the source code of this file.

Data Structures

struct  _clusterbasis
 Representation of a cluster basis. More...
 

Typedefs

typedef struct _clusterbasis clusterbasis
 Representation of a cluster basis.
 
typedef clusterbasispclusterbasis
 Pointer to clusterbasis object.
 
typedef const clusterbasispcclusterbasis
 Pointer to constant clusterbasis object.
 

Functions

pclusterbasis init_clusterbasis (pclusterbasis cb, pccluster t)
 Initialize a clusterbasis object. More...
 
pclusterbasis init_leaf_clusterbasis (pclusterbasis cb, pccluster t)
 Initialize a clusterbasis object for a leaf. More...
 
pclusterbasis init_sub_clusterbasis (pclusterbasis cb, pclusterbasis src, pccluster t, uint off)
 Initialize a clusterbasis object representing a leaf son cluster for a leaf cluster basis. More...
 
void uninit_clusterbasis (pclusterbasis cb)
 Uninitializes a clusterbasis object. More...
 
pclusterbasis new_clusterbasis (pccluster t)
 Create a new clusterbasis object. More...
 
pclusterbasis new_leaf_clusterbasis (pccluster t)
 Create a new clusterbasis object for a leaf. More...
 
void del_clusterbasis (pclusterbasis cb)
 Delete a clusterbasis object. More...
 
void ref_clusterbasis (pclusterbasis *ptr, pclusterbasis cb)
 Set a pointer to a clusterbasis object, increase its reference counter, and decrease reference counter of original pointer target. More...
 
void unref_clusterbasis (pclusterbasis cb)
 Reduce the reference counter of a clusterbasis object. More...
 
void update_clusterbasis (pclusterbasis cb)
 Updates bookkeeping information, e.g., cb->ktree, for a clusterbasis object after its sons have been altered. More...
 
void update_tree_clusterbasis (pclusterbasis cb)
 Updates bookkeeping information, e.g., cb->ktree, for a clusterbasis object and all its descendants. More...
 
void resize_clusterbasis (pclusterbasis cb, uint k)
 Change the rank of a cluster basis and resize cb->V, cb->son[i]->E is resized for all sons. More...
 
void setrank_clusterbasis (pclusterbasis cb, uint k)
 Change the rank of a cluster basis and resize cb->V, while cb->son[i]->E is resized for all sons. More...
 
pclusterbasis build_from_cluster_clusterbasis (pccluster t)
 Construct a clusterbasis from a cluster tree. More...
 
pclusterbasis clone_clusterbasis (pcclusterbasis cb)
 Create a copy of a clusterbasis. More...
 
pclusterbasis clonestructure_clusterbasis (pcclusterbasis cb)
 Copy the tree structure of a clusterbasis. More...
 
uint getactives_clusterbasis ()
 Get number of active clusterbasis objects. More...
 
size_t getsize_clusterbasis (pcclusterbasis cb)
 Get the size of a given clusterbasis object. More...
 
void clear_weight_clusterbasis (pclusterbasis cb)
 Delete all weight matrices of the clusterbasis and its descendants. More...
 
void iterate_clusterbasis (pcclusterbasis cb, uint cbname, void(*pre)(pcclusterbasis cb, uint cbname, void *data), void(*post)(pcclusterbasis cb, uint cbname, void *data), void *data)
 Hierarchical iterator for a clusterbasis. More...
 
void iterate_parallel_clusterbasis (pcclusterbasis cb, uint cbname, uint pardepth, void(*pre)(pcclusterbasis cb, uint cbname, void *data), void(*post)(pcclusterbasis cb, uint cbname, void *data), void *data)
 Parallel hierarchical iterator for a clusterbasis. More...
 
pclusterbasisenumerate_clusterbasis (pccluster t, pclusterbasis cb)
 Enumerate clusterbasis according to cluster tree. More...
 
pavector new_coeffs_clusterbasis_avector (pcclusterbasis cb)
 Create coefficient vector for cluster basis. More...
 
void forward_clusterbasis_avector (pcclusterbasis cb, pcavector x, pavector xt)
 Forward transformation. More...
 
void forward_parallel_clusterbasis_avector (pcclusterbasis cb, pcavector x, pavector xt, uint pardepth)
 Parallel forward transformation. More...
 
void forward_nopermutation_clusterbasis_avector (pcclusterbasis cb, pcavector xp, pavector xt)
 Forward transformation for vectors using cluster numbering. More...
 
void forward_notransfer_clusterbasis_avector (pcclusterbasis cb, pcavector x, pavector xt)
 Forward transformation without transfer matrices. More...
 
void backward_clusterbasis_avector (pcclusterbasis cb, pavector yt, pavector y)
 Backward transformation. More...
 
void backward_parallel_clusterbasis_avector (pcclusterbasis cb, pavector yt, pavector y, uint pardepth)
 Parallel backward transformation. More...
 
void backward_nopermutation_clusterbasis_avector (pcclusterbasis cb, pavector yt, pavector yp)
 Backward transformation for vectors in cluster numbering. More...
 
void backward_notransfer_clusterbasis_avector (pcclusterbasis cb, pavector yt, pavector y)
 Backward transformation without transfer matrices. More...
 
void compress_clusterbasis_avector (pcclusterbasis cb, pcavector xp, pavector xt)
 Compute $\hat x_t = V_t^* x$. More...
 
void expand_clusterbasis_avector (pcclusterbasis cb, pavector yt, pavector yp)
 Add $V_t \hat y_t$ to target vector $y$. More...
 
void compress_clusterbasis_amatrix (pcclusterbasis cb, pcamatrix Xp, pamatrix Xt)
 Compute $\widehat{X}_t = V_t^* X$. More...
 
void compress_parallel_clusterbasis_amatrix (pcclusterbasis cb, pcamatrix Xp, pamatrix Xt, uint pardepth)
 Compute $\widehat{X}_t = V_t^* X$. More...
 
void forward_clusterbasis_amatrix (pcclusterbasis cb, pcamatrix Xp, pamatrix Xt)
 Matrix forward transformation. More...
 
void forward_clusterbasis_trans_amatrix (pcclusterbasis cb, pcamatrix Xp, pamatrix Xt)
 Adjoint matrix forward transformation. More...
 
void backward_clusterbasis_amatrix (pcclusterbasis cb, pamatrix Yt, pamatrix Yp)
 Matrix backward transformation. More...
 
void backward_clusterbasis_trans_amatrix (pcclusterbasis cb, pamatrix Yt, pamatrix Yp)
 Adjoint matrix backward transformation. More...
 
void addeval_clusterbasis_avector (field alpha, pcclusterbasis cb, pcavector yc, pavector yp)
 Compute $y \gets y + \alpha V_t \hat y_t$. More...
 
void addevaltrans_clusterbasis_avector (field alpha, pcclusterbasis cb, pcavector xp, pavector xc)
 Compute $\hat y_t \gets \hat y_t + \alpha V_t^* y$. More...
 
void ortho_clusterbasis (pclusterbasis cb, pclusteroperator co)
 Orthogonalize a cluster basis. More...
 
real check_ortho_clusterbasis (pcclusterbasis cb)
 Check whether a cluster basis is orthogonal. More...
 
pclusteroperator weight_clusterbasis_clusteroperator (pcclusterbasis cb, pclusteroperator co)
 Compute weight matrices for a cluster basis. More...
 
pamatrix weight_enum_clusterbasis_clusteroperator (pcclusterbasis cb)
 Compute weight matrices for a cluster basis using an iterator over the cluster tree. More...
 
void write_cdf_clusterbasis (pcclusterbasis cb, const char *name)
 Write clusterbasis to NetCDF file. More...
 
void write_cdfpart_clusterbasis (pcclusterbasis cb, int nc_file, const char *prefix)
 Write clusterbasis to part of NetCDF file. More...
 
pclusterbasis read_cdf_clusterbasis (const char *name, pccluster t)
 Read clusterbasis from NetCdf file. More...
 
pclusterbasis read_cdfpart_clusterbasis (int nc_file, const char *prefix, pccluster t)
 Read clusterbasis from part of a NetCdf file. More...
 

Detailed Description

Author
Steffen Börm