source: XIOS/dev/dev_trunk_graph/src/transformation/axis_algorithm/axis_algorithm_reduce_domain.hpp @ 2019

Last change on this file since 2019 was 2019, checked in by yushan, 6 months ago

Graph intermedia commit to a tmp branch

  • Property svn:executable set to *
File size: 1.9 KB
Line 
1/*!
2   \file axis_algorithm_reduce_domain.hpp
3   \author Ha NGUYEN
4   \since 23 June 2016
5   \date 23 June 2016
6
7   \brief Algorithm for reduce an axis to a axis
8 */
9#ifndef __XIOS_AXIS_ALGORITHM_REDUCE_DOMAIN_HPP__
10#define __XIOS_AXIS_ALGORITHM_REDUCE_DOMAIN_HPP__
11
12#include "algorithm_transformation_reduce.hpp"
13#include "transformation.hpp"
14
15namespace xios {
16
17class CAxis;
18class CDomain;
19class CReduceDomainToAxis;
20class CReductionAlgorithm;
21
22/*!
23  \class CAxisAlgorithmReduceDomain
24  Reduce a domain to an axis
25*/
26class CAxisAlgorithmReduceDomain : public CAlgorithmTransformationReduce
27{
28public:
29  CAxisAlgorithmReduceDomain(bool isSource, CAxis* axisDestination, CDomain* domainSource, CReduceDomainToAxis* algo);
30 
31  virtual ~CAxisAlgorithmReduceDomain();
32
33  static bool registerTrans();
34protected:
35  enum ReduceDirection {
36    undefined = 0,
37    iDir = 1,
38    jDir = 2
39  };
40 
41  ReduceDirection dir_;
42  bool local ;
43 
44  CDomain* domainSrc_ ;
45  CAxis* axisDest_ ;
46
47public:
48  static CGenericAlgorithmTransformation* create(bool isSource, CGrid* gridDst, CGrid* gridSrc,
49                                                CTransformation<CAxis>* transformation,
50                                                int elementPositionInGrid,
51                                                std::map<int, int>& elementPositionInGridSrc2ScalarPosition,
52                                                std::map<int, int>& elementPositionInGridSrc2AxisPosition,
53                                                std::map<int, int>& elementPositionInGridSrc2DomainPosition,
54                                                std::map<int, int>& elementPositionInGridDst2ScalarPosition,
55                                                std::map<int, int>& elementPositionInGridDst2AxisPosition,
56                                                std::map<int, int>& elementPositionInGridDst2DomainPosition);
57  static bool dummyRegistered_;
58};
59
60}
61#endif // __XIOS_AXIS_ALGORITHM_REDUCE_DOMAIN_HPP__
Note: See TracBrowser for help on using the repository browser.