qem.h 15.6 KB
Newer Older
Pierre Kraemer's avatar
Pierre Kraemer committed
1
/*******************************************************************************
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
 * CGoGN: Combinatorial and Geometric modeling with Generic N-dimensional Maps  *
 * version 0.1                                                                  *
 * Copyright (C) 2009-2012, IGG Team, LSIIT, University of Strasbourg           *
 *                                                                              *
 * This library is free software; you can redistribute it and/or modify it      *
 * under the terms of the GNU Lesser General Public License as published by the *
 * Free Software Foundation; either version 2.1 of the License, or (at your     *
 * option) any later version.                                                   *
 *                                                                              *
 * This library is distributed in the hope that it will be useful, but WITHOUT  *
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or        *
 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License  *
 * for more details.                                                            *
 *                                                                              *
 * You should have received a copy of the GNU Lesser General Public License     *
 * along with this library; if not, write to the Free Software Foundation,      *
 * Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301 USA.           *
 *                                                                              *
 * Web site: http://cgogn.unistra.fr/                                           *
 * Contact information: cgogn@unistra.fr                                        *
 *                                                                              *
 *******************************************************************************/
Pierre Kraemer's avatar
Pierre Kraemer committed
24

25
/*! \file qem.h
26
27
28
* Header file for Quadric Error Metric classes.
*/

Pierre Kraemer's avatar
Pierre Kraemer committed
29
30
31
#ifndef __QEM__
#define __QEM__

32
#include "Utils/os_spec.h" // allow compilation under windows
33
#include <cmath>
34

Pierre Kraemer's avatar
Pierre Kraemer committed
35
36
#include "Geometry/vector_gen.h"
#include "Geometry/matrix.h"
37
#include "Geometry/tensor.h"
Pierre Kraemer's avatar
Pierre Kraemer committed
38
39
#include "Geometry/plane_3d.h"

40
41
// Eigen includes
#include <Eigen/Dense>
42

43
#define CONST_VAL -5212368.54127 // random value
44

45
46
47
/*! \namespace CGoGN
 * \brief namespace for all elements composing the CGoGN library
 */
48
49
namespace CGoGN {

50
51
52
/*! \namespace Utils
 * \brief namespace for tool classes used by CGoGN and its applications
 */
53
namespace Utils {
54

55
56
57
58
59
/*! \class Quadric
 *
 * \brief Quadric for computing the quadric error metric (QEM)
 * introduced by Garland and Heckbert in 1997.
 */
Pierre Kraemer's avatar
Pierre Kraemer committed
60
61
62
63
template <typename REAL>
class Quadric
{
public:
64
	/**
65
66
	 * \brief get CGoGN name of current type
	 *
67
68
69
70
71
72
	 * \return name of the CGoGN type
	 */
	static std::string CGoGNnameOfType()
	{
		return "Quadric" ;
	}
Pierre Kraemer's avatar
Pierre Kraemer committed
73

74
75
76
	typedef Geom::Vector<3,REAL> VEC3 ;
	typedef Geom::Vector<4,REAL> VEC4 ;
	typedef Geom::Matrix<4,4,double> MATRIX44 ; // double is crucial here !
Pierre Kraemer's avatar
Pierre Kraemer committed
77

78
79
80
	/*!
	 * \brief Default constructor
	 *
Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
81
	 * Initializes empty members.
82
	 */
83
	Quadric() ;
Pierre Kraemer's avatar
Pierre Kraemer committed
84

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
85
86
87
88
89
90
	/*!
	 * \brief Constructor
	 *
	 * Initializes empty members (idem. default constructor).
	 * Exists for compatibility reasons.
	 */
91
	Quadric(int i) ;
92
93

	/*!
Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
94
	 * \brief Constructor building a quadric given three points (defining a plane);.
95
96
97
98
99
	 *
	 * \param p1 first point
	 * \param p2 second point
	 * \param p3 third point
	 */
100
	Quadric(VEC3& p1, VEC3& p2, VEC3& p3) ;
Pierre Kraemer's avatar
Pierre Kraemer committed
101

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
102
103
104
105
106
107

	/*!
	 * \brief destructor
	 */
	~Quadric() {} ;

108
109
110
	/*!
	 * \brief set members to zero
	 */
111
	void zero() ;
112

113
114
115
116
117
	/*!
	 * \brief affectation operator (by copy)
	 *
	 * \param q the Quadric to copy
	 */
118
	void operator= (const Quadric<REAL>& q) ;
119
120
121
122
123
124

	/*!
	 * \brief sum of Quadric operator
	 *
	 * \param q the Quadric to sum
	 */
125
	Quadric& operator+= (const Quadric<REAL>& q) ;
126
127
128
129
130
131

	/*!
	 * \brief substract of Quadric operator
	 *
	 * \param q the Quadric to substract
	 */
132
	Quadric& operator -= (const Quadric<REAL>& q) ;
Pierre Kraemer's avatar
Pierre Kraemer committed
133

134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
	/*!
	 * \brief scalar product operator
	 *
	 * \param v the scalar to multiply the Quadric with
	 */
	Quadric& operator *= (const REAL& v) ;

	/*!
	 * \brief scalar division operator
	 *
	 * \param v the scalar to divide the Quadric with
	 */
	Quadric& operator /= (const REAL& v) ;

	/*!
Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
149
	 * \brief error evaluation operator
150
151
152
153
154
	 *
	 * \param v a point expressed in homogeneous coordinates in space
	 *
	 * \return the error
	 */
155
	REAL operator() (const VEC4& v) const ;
156
157

	/*!
Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
158
	 * \brief error evaluation operator
159
160
161
162
163
	 *
	 * \param v a point in space
	 *
	 * \param the error
	 */
164
	REAL operator() (const VEC3& v) const ;
Pierre Kraemer's avatar
Pierre Kraemer committed
165

166
167
168
169
170
171
172
173
	/*!
	 * \brief Write to stream operator
	 *
	 * \param out the stream to write to
	 * \param q the Quadric to write in the stream
	 *
	 * \return the stream reference
	 */
Pierre Kraemer's avatar
Pierre Kraemer committed
174
175
176
177
	friend std::ostream& operator<<(std::ostream& out, const Quadric<REAL>& q)
	{
		out << q.A ;
		return out ;
178
	} ;
Pierre Kraemer's avatar
Pierre Kraemer committed
179

180
181
182
183
184
185
186
187
	/*!
	 * \brief Read from stream operator
	 *
	 * \param int the stream to read from
	 * \param q the Quadric to write the data that has been read in
	 *
	 * \return the stream reference
	 */
Pierre Kraemer's avatar
Pierre Kraemer committed
188
189
190
191
	friend std::istream& operator>>(std::istream& in, Quadric<REAL>& q)
	{
		in >> q.A ;
		return in ;
192
	} ;
Pierre Kraemer's avatar
Pierre Kraemer committed
193

194
195
196
197
198
199
200
	/*!
	 * \brief Method to deduce a position in space that minimizes the error
	 *
	 * \param v the ideal position (if it can be computed)
	 *
	 * \return true if the ideal position has been computed correctly
	 */
201
	bool findOptimizedPos(VEC3& v) ;
Pierre Kraemer's avatar
Pierre Kraemer committed
202
203

private:
204
205
206
207
208
209
210
211
212
	MATRIX44 A ; /*!< The Quadric matrix */

	/*!
	 * \brief method to evaluate the error at a given point in space (homogeneous coordinates)
	 *
	 * \param v the given point
	 *
	 * \return the error
	 */
213
	REAL evaluate(const VEC4& v) const ;
Pierre Kraemer's avatar
Pierre Kraemer committed
214

215
216
217
218
219
220
221
222
	/*!
	 * \brief method to deduce an optimal position in space (homogeneous coordinates)
	 * w.r.t. the current Quadric.
	 *
	 * \param v will contain the optimal position (if it can be computed)
	 *
	 * \return true if an optimal position was correctly computed
	 */
223
	bool optimize(VEC4& v) const ;
Pierre Kraemer's avatar
Pierre Kraemer committed
224
225
} ;

226
227
228
229
230
231
/*! \class QuadricNd
 * \brief extension of Quadric (which is 3D) to nD points.
 * This was published by Garland and Heckbert in 1998 and is meant to define a quadric
 * for a nD-space which contains geometry (3D) + other attributes like color (3D),
 * normals (3D) or texture coordinates (2D) for instance.
 */
232
233
234
235
template <typename REAL, unsigned int N>
class QuadricNd
{
public:
236
237
238
239
240
	/**
	 * \brief get CGoGN name of current type
	 *
	 * \return name of the CGoGN type
	 */
241
242
243
244
	static std::string CGoGNnameOfType()
	{
		return "QuadricNd" ;
	}
245
246
247
248

	typedef Geom::Vector<N,REAL> VECN ;
	typedef Geom::Vector<N+1,REAL> VECNp ;

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
249
250
251
252
253
	/*!
	 * \brief Default constructor
	 *
	 * Initializes empty members.
	 */
254
	QuadricNd() ;
255

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
256
257
258
259
260
261
	/*!
	 * \brief Constructor
	 *
	 * Initializes empty members (idem. default constructor).
	 * Exists for compatibility reasons.
	 */
262
	QuadricNd(int i) ;
263

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
264
265
266
267
268
269
270
	/*!
	 * \brief Constructor building a quadricNd given three points (defining a plane);
	 *
	 * \param p1 first point
	 * \param p2 second point
	 * \param p3 third point
	 */
271
	QuadricNd(const VECN& p1_r, const VECN& p2_r, const VECN& p3_r) ;
272

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
273
274
275
276
277
278
279
280
	/*!
	 * \brief destructor
	 */
	~QuadricNd() {} ;

	/*!
	 * \brief set members to zero
	 */
281
	void zero() ;
282

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
283
284
285
286
287
	/*!
	 * \brief affectation operator (by copy)
	 *
	 * \param q the Quadric to copy
	 */
288
	void operator= (const QuadricNd<REAL,N>& q) ;
289

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
290
291
292
293
294
	/*!
	 * \brief sum of Quadric operator
	 *
	 * \param q the Quadric to sum
	 */
295
	QuadricNd& operator+= (const QuadricNd<REAL,N>& q) ;
296

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
297
298
299
300
301
	/*!
	 * \brief substract of Quadric operator
	 *
	 * \param q the Quadric to substract
	 */
302
	QuadricNd& operator -= (const QuadricNd<REAL,N>& q) ;
303

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
304
305
306
307
308
	/*!
	 * \brief scalar product operator
	 *
	 * \param v the scalar to multiply the Quadric with
	 */
309
	QuadricNd& operator *= (REAL v) ;
310

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
311
312
313
314
315
	/*!
	 * \brief scalar division operator
	 *
	 * \param v the scalar to divide the QuadricNd with
	 */
316
	QuadricNd& operator /= (REAL v) ;
317

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
318
319
320
321
322
323
324
	/*!
	 * \brief error evaluation operator
	 *
	 * \param v a point expressed in homogeneous coordinates in nD space
	 *
	 * \return the error
	 */
325
	REAL operator() (const VECNp& v) const ;
326

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
327
328
329
330
331
332
333
	/*!
	 * \brief error evaluation operator
	 *
	 * \param v a point in nD space
	 *
	 * \param the error
	 */
334
	REAL operator() (const VECN& v) const ;
335

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
336
337
338
339
340
341
342
343
	/*!
	 * \brief Write to stream operator
	 *
	 * \param out the stream to write to
	 * \param q the QuadricNd to write in the stream
	 *
	 * \return the stream reference
	 */
344
345
	friend std::ostream& operator<<(std::ostream& out, const QuadricNd<REAL,N>& q)
	{
346
		out << "(" << q.A << ", " << q.b << ", " << q.c << ")" ;
347
		return out ;
348
	} ;
349

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
350
351
352
353
354
355
356
357
	/*!
	 * \brief Read from stream operator
	 *
	 * \param int the stream to read from
	 * \param q the QuadricNd to write the data that has been read in
	 *
	 * \return the stream reference
	 */
358
359
	friend std::istream& operator>>(std::istream& in, QuadricNd<REAL,N>& q)
	{
360
361
362
		in >> q.A ;
		in >> q.b ;
		in >> q.c ;
363
		return in ;
364
	} ;
365

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
366
367
368
369
370
371
372
	/*!
	 * \brief Method to deduce a position in space that minimizes the error
	 *
	 * \param v the ideal position (if it can be computed)
	 *
	 * \return true if the ideal position has been computed correctly
	 */
373
	bool findOptimizedVec(VECN& v) ;
374
375

private:
376
	// Double computation is crucial for stability
Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
377
378
379
	Geom::Matrix<N,N,double> A ; /*!< The first QuadricNd member matrix A */
	Geom::Vector<N,double> b ; /*!< The second QuadricNd member vector b */
	double c ;/*!< The third QuadricNd member scalar c */
380

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
381
382
383
384
385
386
387
	/*!
	 * \brief method to evaluate the error at a given nD point in space (homogeneous coordinates)
	 *
	 * \param v the given point
	 *
	 * \return the error
	 */
388
	REAL evaluate(const VECN& v) const ;
389

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
390
391
392
393
394
395
396
397
	/*!
	 * \brief method to deduce an optimal position in space (homogeneous coordinates)
	 * w.r.t. the current QuadricNd.
	 *
	 * \param v will contain the optimal position (if it can be computed)
	 *
	 * \return true if an optimal position was correctly computed
	 */
398
	bool optimize(VECN& v) const ;
399
400
} ;

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
401
402
403
404
405
/*! \class QuadricHF
 * \brief Quadric used for measuring a lightfield metric.
 * This was defined by Vanhoey, Sauvage and Dischler in 2012.
 * This implementation works only for polynomial basis functions.
 */
406
407
408
409
template <typename REAL>
class QuadricHF
{
public:
410
411
412
413
414
	/**
	 * \brief get CGoGN name of current type
	 *
	 * \return name of the CGoGN type
	 */
415
416
	static std::string CGoGNnameOfType() { return "QuadricHF" ; }

417
	typedef Geom::Vector<3,REAL> VEC3 ;
418

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
419
420
421
422
423
	/*!
	 * \brief Constructor
	 *
	 * Initializes empty members
	 */
424
	QuadricHF() ;
425

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
426
427
428
429
430
431
	/*!
	 * \brief Constructor
	 *
	 * Initializes empty members (idem. default constructor)
	 * Exists for compatibility reasons
	 */
432
	QuadricHF(int i) ;
433

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
434
435
436
437
438
439
440
	/*!
	 * \brief Constructor building a quadric given a lightfield function and the two angles gamma and alpha
	 *
	 * \param v the lightfield function
	 * \param gamma
	 * \param alpha
	 */
441
	QuadricHF(const std::vector<VEC3>& v, const REAL& gamma, const REAL& alpha) ;
442

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
443
444
445
446
447
448
449
	/*!
	 * \brief Constructor building a quadric given a lightfield function and the two angles gamma and alpha
	 *
	 * \param v the lightfield function expressed as a Geom::Tensor
	 * \param gamma
	 * \param alpha
	 */
450
	QuadricHF(const Geom::Tensor3d* T, const REAL& gamma, const REAL& alpha) ;
451

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
452
453
454
	/*!
	 * Destructor
	 */
455
	~QuadricHF() ;
456

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
457
458
459
	/*!
	 * \brief set members to zero
	 */
460
461
	void zero() ;

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
462
463
464
465
466
	/*!
	 * \brief affectation operator (by copy)
	 *
	 * \param q the QuadricHF to copy
	 */
467
468
	QuadricHF& operator= (const QuadricHF<REAL>& q) ;

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
469
470
471
472
473
	/*!
	 * \brief sum of QuadricHF operator
	 *
	 * \param q the QuadricHF to sum
	 */
474
	QuadricHF& operator+= (const QuadricHF<REAL>& q) ;
Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
475
476
477
478
479
480

	/*!
	 * \brief substract of Quadric operator
	 *
	 * \param q the QuadricHF to substract
	 */
481
482
	QuadricHF& operator -= (const QuadricHF<REAL>& q) ;

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
483
484
485
486
487
	/*!
	 * \brief scalar product operator
	 *
	 * \param v the scalar to multiply the QuadricHF with
	 */
488
489
	QuadricHF& operator *= (const REAL& v) ;

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
490
491
492
493
494
	/*!
	 * \brief scalar division operator
	 *
	 * \param v the scalar to divide the QuadricHF with
	 */
495
496
	QuadricHF& operator /= (const REAL& v) ;

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
497
498
499
500
501
502
503
	/*!
	 * \brief error evaluation operator
	 *
	 * \param coefs a lightfield function
	 *
	 * \param the error
	 */
504
	REAL operator() (const std::vector<VEC3>& coefs) const ;
505

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
506
507
508
509
510
511
512
513
	/*!
	 * \brief Write to stream operator
	 *
	 * \param out the stream to write to
	 * \param q the QuadricNd to write in the stream
	 *
	 * \return the stream reference
	 */
514
515
	friend std::ostream& operator<<(std::ostream& out, const QuadricHF<REAL>& q)
	{
516
		// TODO out << "(" << q.m_A << ", " << q.m_b << ", " << q.m_c << ")" ;
517
		return out ;
518
	} ;
519

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
520
521
522
523
524
525
526
527
	/*!
	 * \brief Read from stream operator
	 *
	 * \param int the stream to read from
	 * \param q the QuadricHF to write the data that has been read in
	 *
	 * \return the stream reference
	 */
528
529
	friend std::istream& operator>>(std::istream& in, QuadricHF<REAL>& q)
	{
530
		// TODO
531
532
533
		//		in >> q.A ;
		//		in >> q.b ;
		//		in >> q.c ;
534
		return in ;
535
	} ;
536

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
537
538
539
540
541
542
543
	/*!
	 * \brief Method to deduce a position in space that minimizes the error
	 *
	 * \param v the ideal position (if it can be computed)
	 *
	 * \return true if the ideal position has been computed correctly
	 */
544
	bool findOptimizedCoefs(std::vector<VEC3>& coefs) ;
545

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
	/*!
	 * \brief method to convert a lightfield in tensor format to a coefficient vector format
	 *
	 * \param coefs vector of coefficients representing a lightfield function
	 *
	 * \return a tensor representing the same lightfield function
	 *
	 */
	static Geom::Tensor3d* tensorsFromCoefs(const std::vector<VEC3>& coefs) ;

	/*!
	 * \brief method to convert a lightfield in coefficient vector format to a tensor format
	 *
	 * \param T the tensor to convert
	 *
	 * \return a vector of coefficients representing the same lightfield function
	 */
Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
563
	static std::vector<VEC3> coefsFromTensors(Geom::Tensor3d* T) ;
Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
564
565
566
567
568
569
570
571
572

	/*!
	 * \brief method to complete a symmetric tensor that was
	 * only filled in its first half
	 *
	 * \param T the tensor to fill
	 */
	static void fillTensor(Geom::Tensor3d& T) ;

573
574
private:
	// Double computation is crucial for stability
Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
575
576
577
	Eigen::MatrixXd m_A ; /*!< The first QuadricHF member matrix A */
	Eigen::VectorXd m_b[3] ; /*!< The second QuadricHF member vector b */
	double m_c[3] ; /*!< The third QuadricHF member scalar c */
578

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
579
580
581
582
583
584
585
	/*!
	 * \brief method to evaluate the error for a given lightfield function
	 *
	 * \param coefs the given function
	 *
	 * \return the error
	 */
586
	REAL evaluate(const std::vector<VEC3>& coefs) const ;
587

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
588
589
590
591
592
593
594
595
	/*!
	 * \brief method to deduce an optimal coefficients in space
	 * w.r.t. the current QuadricND.
	 *
	 * \param coefs will contain the optimal result (if it can be computed)
	 *
	 * \return true if an optimal result was correctly computed
	 */
596
	bool optimize(std::vector<VEC3>& coefs) const ;
597

598
	Geom::Tensor3d rotate(const Geom::Tensor3d& T, const Geom::Matrix33d& R) ;
599

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
	/*!
	 * \brief method to build a rotate matrix (rotation in tangent plane)
	 * given angle gamma
	 *
	 * \param gamma the rotation angle
	 *
	 * \return the rotation matrix
	 */
	Geom::Matrix33d buildRotateMatrix(const REAL& gamma) ;

	/*!
	 * \brief method to build the first integral matrix A
	 * given angle alpha
	 *
	 * \param alpha angle
	 * \param size the amount of monomes in a function
	 *
	 * \return the integral of product of monomes
	 */
619
	Eigen::MatrixXd buildIntegralMatrix_A(const REAL& alpha, unsigned int size) ;
Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
620
621
622
623
624
625
626
627
628
629

	/*!
	 * \brief method to build the first integral matrix B
	 * given angle alpha
	 *
	 * \param alpha angle
	 * * \param size the amount of monomes in a function
	 *
	 * \return the integral of product of monomes
	 */
630
	Eigen::MatrixXd buildIntegralMatrix_B(const REAL& alpha, unsigned int size) ;
631

Kenneth Vanhoey's avatar
Kenneth Vanhoey committed
632
633
634
635
636
637
638
639
640
	/*!
	 * \brief method to build the third integral matrix C
	 * given angle alpha
	 *
	 * \param alpha angle
	 * \param size the amount of monomes in a function
	 *
	 * \return the integral of product of monomes
	 */
641
	Eigen::MatrixXd buildIntegralMatrix_C(const REAL& alpha, unsigned int size) ;
642
643
} ;

644
} // Utils
645
646
647

} // CGOGN

648
649
#include "qem.hpp"

Pierre Kraemer's avatar
Pierre Kraemer committed
650
#endif