AQUAgpusph 4.1.2
Loading...
Searching...
No Matches
Set.h
Go to the documentation of this file.
1/*
2 * This file is part of AQUAgpusph, a free CFD program based on SPH.
3 * Copyright (C) 2012 Jose Luis Cercos Pita <jl.cercos@upm.es>
4 *
5 * AQUAgpusph is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation, either version 3 of the License, or
8 * (at your option) any later version.
9 *
10 * AQUAgpusph is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with AQUAgpusph. If not, see <http://www.gnu.org/licenses/>.
17 */
18
26#ifndef SET_H_INCLUDED
27#define SET_H_INCLUDED
28
29#include <CalcServer.h>
30#include <CalcServer/Tool.h>
31
32namespace Aqua {
33namespace CalcServer {
34
39{
40 public:
58 Set(const std::string name,
59 const std::string var_name,
60 const std::string value,
61 bool once = false);
62
65 ~Set();
66
69 void setup();
70
71 protected:
76 cl_event _execute(const std::vector<cl_event> events);
77
78 private:
81 void variable();
82
85 void setupOpenCL();
86
93 void solve();
94
98 void setVariables();
99
101 std::string _var_name;
103 std::string _value;
104
107
109 cl_mem _input;
110
112 cl_kernel _kernel;
113
115 size_t _global_work_size;
117 size_t _local_work_size;
119 unsigned int _n;
120
122 void* _data;
123};
124
125}
126} // namespace
127
128#endif // SET_H_INCLUDED
The calculation main entry point. (See Aqua::CalcServer::CalcServer for details)
Tools virtual environment to allow the user to define/manipulate the tools used to carry out the simu...
Set all the components of an array with the desired value.
Definition: Set.h:39
~Set()
Definition: Set.cpp:58
void setup()
Definition: Set.cpp:69
cl_event _execute(const std::vector< cl_event > events)
Definition: Set.cpp:95
Tools base class. The way that AQUAgpusph compute each problem is set through a set of tools that are...
Definition: Tool.h:46
const std::string name()
Definition: Tool.h:66
Definition: Variable.h:700
Main AQUAgpusph namespace.
Definition: ArgumentsManager.cpp:45