NFFT Logo 3.2.2
solver_adjoint.h
Go to the documentation of this file.
00001 /*
00002  * Copyright (c) 2002, 2012 Jens Keiner, Stefan Kunis, Daniel Potts
00003  *
00004  * This program is free software; you can redistribute it and/or modify it under
00005  * the terms of the GNU General Public License as published by the Free Software
00006  * Foundation; either version 2 of the License, or (at your option) any later
00007  * version.
00008  *
00009  * This program is distributed in the hope that it will be useful, but WITHOUT
00010  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
00011  * FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more
00012  * details.
00013  *
00014  * You should have received a copy of the GNU General Public License along with
00015  * this program; if not, write to the Free Software Foundation, Inc., 51
00016  * Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
00017  */
00018 
00019 /* $Id: solver_adjoint.h 3775 2012-06-02 16:39:48Z keiner $ */
00020 
00024 #ifndef SOLVER_ADJOINT_H
00025 #define SOLVER_ADJOINT_H
00026 
00028 #include "nfft3.h"
00029 
00030 /*
00031  * Macro for mangling an adjoint transform.
00032  * temporary added 01.2007 by tim becker
00033  */
00034                                                                                \
00035 #define MACRO_SOLVER_ADJOINT_PLAN(MV, FLT, FLT_TYPE)                           \
00036                                                                                \
00037                                 \
00038 typedef struct                                                                 \
00039 {                                                                              \
00040   MV ## _plan *mv;                      \
00041   unsigned flags;                       \
00042                                                                                \
00043   double *w;                            \
00044   double *w_hat;                        \
00045                                                                                \
00046   FLT_TYPE *y_hat;                      \
00047                                                                                \
00048   FLT_TYPE *f_iter;                     \
00049   FLT_TYPE *r_hat_iter;                 \
00050   FLT_TYPE *z_iter;                     \
00052   FLT_TYPE *p_iter;                     \
00053   FLT_TYPE *v_hat_iter;                 \
00054                                                                                \
00055   double alpha_iter;                    \
00056   double beta_iter;                     \
00057                                                                                \
00058   double dot_r_hat_iter;                \
00059   double dot_r_hat_iter_old;            \
00060   double dot_z_iter;                    \
00062   double dot_z_iter_old;                \
00063   double dot_p_iter;                    \
00065   double dot_v_hat_iter;                \
00066 } i ## MV ## _adjoint_plan;                                                    \
00067                                                                                \
00068                                                   \
00069 void i ## MV ## _adjoint_init(adjoint ## MV ## _plan *ths, MV ## _plan *mv);   \
00070                                                \
00071 void i ## MV ## _adjoint_init_advanced(adjoint ## MV ## _plan *ths, MV ## _plan,\
00072 *mv, unsigned adjoint ## MV ## _flags);                                       \
00073 \
00074 void i ## MV ## _adjoint_before_loop(adjoint ## MV ## _plan *ths);              \
00075 \
00076 void i ## MV ## _adjoint_loop_one_step(adjoint ## MV ## _plan *ths);            \
00077 \
00078 void i ## MV ## _adjoint_finalize(adjoint ## MV ## _plan *ths);                 \
00079 
00080 
00081 MACRO_SOLVER_ADJOINT_PLAN(nfsft, complex, double _Complex)
00082 MACRO_SOLVER_ADJOINT_PLAN(nfft, complex, double _Complex)
00083 MACRO_SOLVER_ADJOINT_PLAN(nfct, double, double)
00084 MACRO_SOLVER_ADJOINT_PLAN(nfst, double, double)
00085 MACRO_SOLVER_ADJOINT_PLAN(nnfft, complex, double _Complex)
00086 MACRO_SOLVER_ADJOINT_PLAN(mri_inh_2d1d, complex, double _Complex)
00087 MACRO_SOLVER_ADJOINT_PLAN(mri_inh_3d, complex, double _Complex)
00088 
00089 #endif
00090 /* solver_adjoint.h */

Generated on Fri Oct 12 2012 by Doxygen 1.8.0-20120409