OpenLB 1.7
Loading...
Searching...
No Matches
fringe2D.h
Go to the documentation of this file.
1/* This file is part of the OpenLB library
2 *
3 * Copyright (C) 2015 Mathias J. Krause
4 * E-mail contact: info@openlb.net
5 * The most recent release of OpenLB can be downloaded at
6 * <http://www.openlb.net/>
7 *
8 * This program is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU General Public License
10 * as published by the Free Software Foundation; either version 2
11 * of the License, or (at your option) any later version.
12 *
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
17 *
18 * You should have received a copy of the GNU General Public
19 * License along with this program; if not, write to the Free
20 * Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
21 * Boston, MA 02110-1301, USA.
22*/
23
24#ifndef FRINGE_2D_H
25#define FRINGE_2D_H
26
27#include<vector> // for generic i/o
28#include<cmath> // for lpnorm
29
30#include "analyticalF.h"
31#include "io/ostreamManager.h"
32
88namespace olb {
89
90template <typename T, typename S>
91class Fringe2D : public AnalyticalF2D<T,S> {
92
93private:
95 AnalyticalF2D<T,S>& _wantedVelocity;
97 T _start;
99 T _end;
101 int _direction;
103 T _lambdaMax;
105 T _rise;
107 T _fall;
108
109public:
110 Fringe2D(AnalyticalF2D<T,S>& wantedVelocity, T start, T end, int direction, T lambdaMax=.005, T rise=.4, T fall=.2);
111
116 bool operator()(T output[6], const S input[2]);
117
118private:
120 T s(const T& x) const;
122 T lambda(const T& x) const;
123};
124
125} // end namespace olb
126
127#endif
128
129
AnalyticalF are applications from DD to XD, where X is set by the constructor.
Fringe2D(AnalyticalF2D< T, S > &wantedVelocity, T start, T end, int direction, T lambdaMax=.005, T rise=.4, T fall=.2)
Definition fringe2D.hh:35
bool operator()(T output[6], const S input[2])
Returns coefficients (a1, a2, B11, B12, B21, B22) for a linear velocity force modell where F = a + B*...
Definition fringe2D.hh:44
Top level namespace for all of OpenLB.