1 /**
2  *  @ingroup PMGC
3  *  @author  Tucker Beck [fortran ->c translation], Michael Holst [original]
4  *  @brief  Multigrid smoothing functions
5  *
6  *  @attention
7  *  @verbatim
8  *
9  * APBS -- Adaptive Poisson-Boltzmann Solver
10  *
11  * Nathan A. Baker (nathan.baker@pnl.gov)
12  * Pacific Northwest National Laboratory
13  *
14  * Additional contributing authors listed in the code documentation.
15  *
16  * Copyright (c) 2010-2014 Battelle Memorial Institute. Developed at the Pacific Northwest National Laboratory, operated by Battelle Memorial Institute, Pacific Northwest Division for the U.S. Department Energy.  Portions Copyright (c) 2002-2010, Washington University in St. Louis.  Portions Copyright (c) 2002-2010, Nathan A. Baker.  Portions Copyright (c) 1999-2002, The Regents of the University of California. Portions Copyright (c) 1995, Michael Holst.
17  * All rights reserved.
18  *
19  *
20  * Redistribution and use in source and binary forms, with or without
21  * modification, are permitted provided that the following conditions are met:
22  *
23  * -  Redistributions of source code must retain the above copyright notice, this
24  * list of conditions and the following disclaimer.
25  *
26  * - Redistributions in binary form must reproduce the above copyright notice,
27  * this list of conditions and the following disclaimer in the documentation
28  * and/or other materials provided with the distribution.
29  *
30  * - Neither the name of Washington University in St. Louis nor the names of its
31  * contributors may be used to endorse or promote products derived from this
32  * software without specific prior written permission.
33  *
34  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
35  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
36  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
37  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
38  * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
39  * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
40  * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
41  * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
42  * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
43  * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
44  * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
45  *
46  * @endverbatim
47  */
48 
49 #ifndef _SMOOTHD_H_
50 #define _SMOOTHD_H_
51 
52 #include "apbscfg.h"
53 
54 #include "maloc/maloc.h"
55 
56 #include "generic/vhal.h"
57 #include "generic/vmatrix.h"
58 #include "pmgc/gsd.h"
59 #include "pmgc/cgd.h"
60 
61 /** @brief   call the appropriate linear smoothing routine.
62  *  @ingroup PMGC
63  *  @author  Tucker Beck [C Translation], Michael Holst [Original]
64  *
65  *  @note    Replaces smooth from smoothd.f
66  */
67 VEXTERNC void Vsmooth(
68         int    *nx,       ///< @todo: Doc
69         int    *ny,       ///< @todo: Doc
70         int    *nz,       ///< @todo: Doc
71         int    *ipc,      ///< @todo: Doc
72         double *rpc,      ///< @todo: Doc
73         double *ac,       ///< @todo: Doc
74         double *cc,       ///< @todo: Doc
75         double *fc,       ///< @todo: Doc
76         double *x,        ///< @todo: Doc
77         double *w1,       ///< @todo: Doc
78         double *w2,       ///< @todo: Doc
79         double *r,        ///< @todo: Doc
80         int    *itmax,    ///< @todo: Doc
81         int    *iters,    ///< @todo: Doc
82         double *errtol,   ///< @todo: Doc
83         double *omega,    ///< @todo: Doc
84         int    *iresid,   ///< @todo: Doc
85         int    *iadjoint, ///< @todo: Doc
86         int    *meth      ///< @todo: Doc
87         );
88 
89 /** @brief   call the appropriate non-linear smoothing routine.
90  *  @ingroup PMGC
91  *  @author  Tucker Beck [C Translation], Michael Holst [Original]
92  *
93  *  @note    Replaces nsmooth from nsmoothd.f
94  */
95 VEXTERNC void Vnsmooth(
96         int    *nx,       ///< @todo: Doc
97         int    *ny,       ///< @todo: Doc
98         int    *nz,       ///< @todo: Doc
99         int    *ipc,      ///< @todo: Doc
100         double *rpc,      ///< @todo: Doc
101         double *ac,       ///< @todo: Doc
102         double *cc,       ///< @todo: Doc
103         double *fc,       ///< @todo: Doc
104         double *x,        ///< @todo: Doc
105         double *w1,       ///< @todo: Doc
106         double *w2,       ///< @todo: Doc
107         double *r,        ///< @todo: Doc
108         int    *itmax,    ///< @todo: Doc
109         int    *iters,    ///< @todo: Doc
110         double *errtol,   ///< @todo: Doc
111         double *omega,    ///< @todo: Doc
112         int    *iresid,   ///< @todo: Doc
113         int    *iadjoint, ///< @todo: Doc
114         int    *meth      ///< @todo: Doc
115         );
116 
117 
118 #endif /* _SMOOTHD_H_ */
119