1 /*---------------------------------------------------------------------------*\
3 \\ / F ield | OpenFOAM: The Open Source CFD Toolbox
5 \\ / A nd | Copyright (C) 1991-2008 OpenCFD Ltd.
7 -------------------------------------------------------------------------------
9 This file is part of OpenFOAM.
11 OpenFOAM is free software; you can redistribute it and/or modify it
12 under the terms of the GNU General Public License as published by the
13 Free Software Foundation; either version 2 of the License, or (at your
14 option) any later version.
16 OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
17 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
21 You should have received a copy of the GNU General Public License
22 along with OpenFOAM; if not, write to the Free Software Foundation,
23 Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
26 simpleSplineEdge : the actual access class for Bspline
28 \*---------------------------------------------------------------------------*/
32 #include "simpleSplineEdge.H"
34 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
39 // * * * * * * * * * * * * * * Static Data Members * * * * * * * * * * * * * //
41 defineTypeNameAndDebug(simpleSplineEdge, 0);
43 // Add the curvedEdge constructor functions to the hash tables
44 curvedEdge::addIstreamConstructorToTable<simpleSplineEdge>
45 addSimpleSplineEdgeIstreamConstructorToTable_;
47 // * * * * * * * * * * * * * * * * Constructors * * * * * * * * * * * * * * //
49 // Construct from components
50 simpleSplineEdge::simpleSplineEdge
52 const pointField& points,
55 const pointField& otherknots
58 curvedEdge(points, start, end),
59 BSpline(knotlist(points, start, end, otherknots))
63 // Construct from components
64 simpleSplineEdge::simpleSplineEdge
66 const pointField& points,
69 const pointField& otherknots,
74 curvedEdge(points, start, end),
75 BSpline(knotlist(points, start, end, otherknots), fstend, sndend)
79 // Construct from Istream
80 simpleSplineEdge::simpleSplineEdge(const pointField& points, Istream& is)
82 curvedEdge(points, is),
83 BSpline(knotlist(points, start_, end_, pointField(is)))
87 // * * * * * * * * * * * * * * * Member Functions * * * * * * * * * * * * * //
89 //- Return the position of a point on the simple spline curve given by
90 // the parameter 0 <= lambda <= 1
91 vector simpleSplineEdge::position(const scalar mu) const
93 return BSpline::position(mu);
97 //- Return the length of the simple spline curve
98 scalar simpleSplineEdge::length() const
100 notImplemented("simpleSplineEdge::length() const");
105 // * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
107 } // End namespace Foam
109 // ************************************************************************* //