OpenFCST: The open-source Fuel Cell Simulation Toolbox
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
homogeneous_CL.h
Go to the documentation of this file.
1 //---------------------------------------------------------------------------
2 //
3 // FCST: Fuel Cell Simulation Toolbox
4 //
5 // Copyright (C) 2006-13 by Energy Systems Design Laboratory, University of Alberta
6 //
7 // This software is distributed under the MIT License.
8 // For more information, see the README file in /doc/LICENSE
9 // - Class: homogeneous_CL.h
10 // - Description: Class characterizing the macro-homogeneous catalyst layer.
11 // - Developers: Marc Secanell, Peter Dobson and Madhur Bhaiya
12 // - Id: $Id: homogeneous_CL.h 2605 2014-08-15 03:36:44Z secanell $
13 //
14 //---------------------------------------------------------------------------
15 
16 #ifndef _FUELCELLSHOP__HOMOGENEOUS_CL__H
17 #define _FUELCELLSHOP__HOMOGENEOUS_CL__H
18 
19 // Include deal.II classes
20 #include <base/parameter_handler.h>
21 #include <base/point.h>
22 #include <base/function.h>
23 #include <lac/vector.h>
24 #include <fe/fe_values.h>
25 
26 // Include openFCST routines:
27 #include "fcst_constants.h"
28 #include "conventional_CL.h"
29 #include "base_kinetics.h"
31 #include "catalyst_support_base.h"
32 #include "catalyst_base.h"
33 
34 // Include STL
35 #include "cmath"
36 #include "iostream"
37 
38 namespace FuelCellShop
39 {
40  namespace Layer
41  {
50  template <int dim>
51  class HomogeneousCL :
52  public ConventionalCL<dim>
53  {
54  public:
55 
71  static const std::string concrete_name;
72 
74 
75 
80  HomogeneousCL();
81 
86 
88 
90 
91 
95  virtual void current_density(std::vector<double>&);
96 
101  virtual void current_density(std::vector<double>& current, std::vector<double>& effectiveness)
102  {
103  current_density(current);
104  effectiveness.assign(current.size(), 1.0);
105  }
106 
111  virtual void derivative_current_density(std::map< VariableNames, std::vector<double> >& );
113 
114  protected:
116 
117 
121  HomogeneousCL(const std::string name);
122 
129  virtual void declare_parameters (const std::string& cl_section_name,
130  ParameterHandler &param) const;
131 
136  void initialize (ParameterHandler &param);
138 
140 
141 
146  virtual boost::shared_ptr<FuelCellShop::Layer::CatalystLayer<dim> > create_replica (const std::string &cl_section_name)
147  {
148  return boost::shared_ptr<FuelCellShop::Layer::CatalystLayer<dim> > (new FuelCellShop::Layer::HomogeneousCL<dim> (cl_section_name));
149  }
151 
153 
154 
159 
161  void set_cell_id(const unsigned int& ) {}
162  };
163  }
164 }
165 
166 #endif
static const std::string concrete_name
Concrete name used for objects of this class.
Definition: homogeneous_CL.h:71
HomogeneousCL()
Prototye Constructor.
VariableNames
The enumeration containing the names of some of the available FCST solution variables and their deriv...
Definition: system_management.h:62
virtual boost::shared_ptr< FuelCellShop::Layer::CatalystLayer< dim > > create_replica(const std::string &cl_section_name)
This member function is used to create an object of type gas diffusion layer.
Definition: homogeneous_CL.h:146
const std::string name
Name of the layer.
Definition: base_layer.h:336
virtual void derivative_current_density(std::map< VariableNames, std::vector< double > > &)
This member function will use a FuelCellShop::BaseKinetics class in order to compute the derivative o...
static HomogeneousCL< dim > const * PROTOTYPE
Definition: homogeneous_CL.h:157
void initialize(ParameterHandler &param)
Member function used to read in data and initialize the necessary data to compute the coefficients...
This class characterizes a catalyst layer and uses this information to compute effective transport pr...
Definition: conventional_CL.h:61
virtual void current_density(std::vector< double > &)
This member function will use a FuelCellShop::BaseKinetics class in order to compute the current dens...
This class characterizes a catalyst layer and uses this information to compute effective transport pr...
Definition: homogeneous_CL.h:51
void set_cell_id(const unsigned int &)
This routine is not used for this layer.
Definition: homogeneous_CL.h:161
virtual void current_density(std::vector< double > &current, std::vector< double > &effectiveness)
This member function computes the current density production in the CL.
Definition: homogeneous_CL.h:101
virtual void declare_parameters(const std::string &cl_section_name, ParameterHandler &param) const
Declare parameters for a parameter file.