OpenFPM_pdata  4.1.0
Project that contain the implementation of distributed structures
 
Loading...
Searching...
No Matches
DCPSE_surface_op.hpp
1//
2// Created by Abhinav Singh on 15.11.21.
3//
4
5#ifndef OPENFPM_PDATA_DCPSE_SURFACE_OP_HPP
6#define OPENFPM_PDATA_DCPSE_SURFACE_OP_HPP
7#ifdef HAVE_EIGEN
8
9#include "DCPSE/DCPSE_op/DCPSE_op.hpp"
10
11template<unsigned int NORMAL_ID>
12class SurfaceDerivative_x {
13
14 void *dcpse;
15
16public:
29 template<typename particles_type>
30 SurfaceDerivative_x(particles_type &parts, unsigned int ord, typename particles_type::stype rCut,typename particles_type::stype nSpacing,
31 support_options opt = support_options::RADIUS) {
33 p.zero();
34 p.get(0) = 1;
35
36 dcpse = new Dcpse<particles_type::dims, particles_type>(parts, p, ord, rCut,nSpacing,value_t<NORMAL_ID>(), opt);
37 }
38
39 template<typename particles_type>
40 void deallocate(particles_type &parts) {
41 delete (Dcpse<particles_type::dims, particles_type> *) dcpse;
42 }
43
44 template<typename operand_type>
46 operator()(operand_type arg) {
47 typedef Dcpse<operand_type::vtype::dims, typename operand_type::vtype> dcpse_type;
48
50 }
51
52 template<typename particles_type>
53 void checkMomenta(particles_type &particles) {
54 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
55 dcpse_temp->checkMomenta(particles);
56
57 }
58
59 template<unsigned int prp, typename particles_type>
60 void DrawKernel(particles_type &particles, int k) {
61 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
62 dcpse_temp->template DrawKernel<prp>(particles, k);
63
64 }
65
71 template<typename particles_type>
72 void save(particles_type &particles, const std::string &file) {
73 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
74 dcpse_temp->save(file);
75 }
81 template<typename particles_type>
82 void load(particles_type &particles, const std::string &file) {
83 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
84 dcpse_temp->load(file);
85 }
86
92 template<typename particles_type>
93 void update(particles_type &particles) {
94 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
95 dcpse_temp->template createNormalParticles<NORMAL_ID>(particles);
96 dcpse_temp->initializeUpdate(particles);
97 dcpse_temp->accumulateAndDeleteNormalParticles(particles);
98 }
99};
100
101template<unsigned int NORMAL_ID>
102class SurfaceDerivative_y {
103
104 void *dcpse;
105
106public:
119 template<typename particles_type>
120 SurfaceDerivative_y(particles_type &parts, unsigned int ord, typename particles_type::stype rCut,typename particles_type::stype nSpacing,
121 support_options opt = support_options::RADIUS) {
123 p.zero();
124 p.get(1) = 1;
125
126 dcpse = new Dcpse<particles_type::dims, particles_type>(parts, p, ord, rCut,nSpacing,value_t<NORMAL_ID>(), opt);
127 }
128
129 template<typename particles_type>
130 void deallocate(particles_type &parts) {
131 delete (Dcpse<particles_type::dims, particles_type> *) dcpse;
132 }
133
134 template<typename operand_type>
136 operator()(operand_type arg) {
137 typedef Dcpse<operand_type::vtype::dims, typename operand_type::vtype> dcpse_type;
138
140 }
141
142 template<typename particles_type>
143 void checkMomenta(particles_type &particles) {
144 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
145 dcpse_temp->checkMomenta(particles);
146
147 }
148
149 template<unsigned int prp, typename particles_type>
150 void DrawKernel(particles_type &particles, int k) {
151 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
152 dcpse_temp->template DrawKernel<prp>(particles, k);
153
154 }
155
156
162 template<typename particles_type>
163 void save(particles_type &particles, const std::string &file) {
164 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
165 dcpse_temp->save(file);
166 }
172 template<typename particles_type>
173 void load(particles_type &particles, const std::string &file) {
174 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
175 dcpse_temp->load(file);
176 }
182 template<typename particles_type>
183 void update(particles_type &particles) {
184 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
185 dcpse_temp->template createNormalParticles<NORMAL_ID>(particles);
186 dcpse_temp->initializeUpdate(particles);
187 dcpse_temp->accumulateAndDeleteNormalParticles(particles);
188
189 }
190};
191
192template<unsigned int NORMAL_ID>
193class SurfaceDerivative_z {
194
195 void *dcpse;
196
197public:
210 template<typename particles_type>
211 SurfaceDerivative_z(particles_type &parts, unsigned int ord, typename particles_type::stype rCut,typename particles_type::stype nSpacing,
212 support_options opt = support_options::RADIUS) {
214 p.zero();
215 p.get(2) = 1;
216
217 dcpse = new Dcpse<particles_type::dims, particles_type>(parts, p, ord, rCut,nSpacing,value_t<NORMAL_ID>(), opt);
218 }
219
220 template<typename particles_type>
221 void deallocate(particles_type &parts) {
222 delete (Dcpse<particles_type::dims, particles_type> *) dcpse;
223 }
224
225 template<typename operand_type>
227 operator()(operand_type arg) {
228 typedef Dcpse<operand_type::vtype::dims, typename operand_type::vtype> dcpse_type;
229
231 }
232
233 template<typename particles_type>
234 void checkMomenta(particles_type &particles) {
235 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
236 dcpse_temp->checkMomenta(particles);
237
238 }
239
240 template<unsigned int prp, typename particles_type>
241 void DrawKernel(particles_type &particles, int k) {
242 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
243 dcpse_temp->template DrawKernel<prp>(particles, k);
244
245 }
246
252 template<typename particles_type>
253 void save(particles_type &particles, const std::string &file) {
254 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
255 dcpse_temp->save(file);
256 }
262 template<typename particles_type>
263 void load(particles_type &particles, const std::string &file) {
264 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
265 dcpse_temp->load(file);
266 }
272 template<typename particles_type>
273 void update(particles_type &particles) {
274 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
275 dcpse_temp->template createNormalParticles<NORMAL_ID>(particles);
276 dcpse_temp->initializeUpdate(particles);
277 dcpse_temp->accumulateAndDeleteNormalParticles(particles);
278
279 }
280};
281
282template<unsigned int NORMAL_ID>
283class Laplace_Beltrami {
284
285 void *dcpse;
286
287public:
300 template<typename particles_type>
301 Laplace_Beltrami(particles_type &parts, unsigned int ord, typename particles_type::stype rCut,typename particles_type::stype nSpacing,
302 support_options opt = support_options::RADIUS) {
304 p.zero();
305 p.get(0) = 2;
306 p.get(1) = 2;
307 p.get(2) = 2;
308
309 dcpse = new Dcpse<particles_type::dims, particles_type>(parts, p, ord, rCut,nSpacing,value_t<NORMAL_ID>(), opt);
310 }
311
312 template<typename particles_type>
313 void deallocate(particles_type &parts) {
314 delete (Dcpse<particles_type::dims, particles_type> *) dcpse;
315 }
316
317 template<typename operand_type>
319 operator()(operand_type arg) {
320 typedef Dcpse<operand_type::vtype::dims, typename operand_type::vtype> dcpse_type;
321
323 }
324
325 template<typename particles_type>
326 void checkMomenta(particles_type &particles) {
327 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
328 dcpse_temp->checkMomenta(particles);
329
330 }
331
332 template<unsigned int prp, typename particles_type>
333 void DrawKernel(particles_type &particles, int k) {
334 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
335 dcpse_temp->template DrawKernel<prp>(particles, k);
336
337 }
338
344 template<typename particles_type>
345 void save(particles_type &particles, const std::string &file) {
346 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
347 dcpse_temp->save(file);
348 }
354 template<typename particles_type>
355 void load(particles_type &particles, const std::string &file) {
356 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
357 dcpse_temp->load(file);
358 }
364 template<typename particles_type>
365 void update(particles_type &particles) {
366 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
367 dcpse_temp->template createNormalParticles<NORMAL_ID>(particles);
368 dcpse_temp->template createNormalParticles<NORMAL_ID>(particles);
369 dcpse_temp->initializeUpdate(particles);
370 dcpse_temp->accumulateAndDeleteNormalParticles(particles);
371 }
372};
373
374template<unsigned int NORMAL_ID>
375class SurfaceDerivative_xx {
376
377 void *dcpse;
378
379public:
392 template<typename particles_type>
393 SurfaceDerivative_xx(particles_type &parts, unsigned int ord, typename particles_type::stype rCut,typename particles_type::stype nSpacing,
394 support_options opt = support_options::RADIUS) {
396 p.zero();
397 p.get(0) = 2;
398
399 dcpse = new Dcpse<particles_type::dims, particles_type>(parts, p, ord, rCut,nSpacing,value_t<NORMAL_ID>(), opt);
400 }
401
402 template<typename particles_type>
403 void deallocate(particles_type &parts) {
404 delete (Dcpse<particles_type::dims, particles_type> *) dcpse;
405 }
406
407 template<typename operand_type>
409 operator()(operand_type arg) {
410 typedef Dcpse<operand_type::vtype::dims, typename operand_type::vtype> dcpse_type;
411
413 }
414
415 template<typename particles_type>
416 void checkMomenta(particles_type &particles) {
417 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
418 dcpse_temp->checkMomenta(particles);
419
420 }
421
422 template<unsigned int prp, typename particles_type>
423 void DrawKernel(particles_type &particles, int k) {
424 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
425 dcpse_temp->template DrawKernel<prp>(particles, k);
426
427 }
428
434 template<typename particles_type>
435 void save(particles_type &particles, const std::string &file) {
436 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
437 dcpse_temp->save(file);
438 }
444 template<typename particles_type>
445 void load(particles_type &particles, const std::string &file) {
446 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
447 dcpse_temp->load(file);
448 }
454 template<typename particles_type>
455 void update(particles_type &particles) {
456 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
457 dcpse_temp->template createNormalParticles<NORMAL_ID>(particles);
458 dcpse_temp->template createNormalParticles<NORMAL_ID>(particles);
459 dcpse_temp->initializeUpdate(particles);
460 dcpse_temp->accumulateAndDeleteNormalParticles(particles);
461 }
462};
463
464
465template<unsigned int NORMAL_ID>
466class SurfaceDerivative_yy {
467
468 void *dcpse;
469
470public:
483 template<typename particles_type>
484 SurfaceDerivative_yy(particles_type &parts, unsigned int ord, typename particles_type::stype rCut,typename particles_type::stype nSpacing,
485 support_options opt = support_options::RADIUS) {
487 p.zero();
488 p.get(1) = 2;
489
490 dcpse = new Dcpse<particles_type::dims, particles_type>(parts, p, ord, rCut,nSpacing,value_t<NORMAL_ID>(), opt);
491 }
492
493 template<typename particles_type>
494 void deallocate(particles_type &parts) {
495 delete (Dcpse<particles_type::dims, particles_type> *) dcpse;
496 }
497
498 template<typename operand_type>
500 operator()(operand_type arg) {
501 typedef Dcpse<operand_type::vtype::dims, typename operand_type::vtype> dcpse_type;
502
504 }
505
506 template<typename particles_type>
507 void checkMomenta(particles_type &particles) {
508 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
509 dcpse_temp->checkMomenta(particles);
510
511 }
512
513 template<unsigned int prp, typename particles_type>
514 void DrawKernel(particles_type &particles, int k) {
515 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
516 dcpse_temp->template DrawKernel<prp>(particles, k);
517
518 }
519
525 template<typename particles_type>
526 void save(particles_type &particles, const std::string &file) {
527 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
528 dcpse_temp->save(file);
529 }
535 template<typename particles_type>
536 void load(particles_type &particles, const std::string &file) {
537 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
538 dcpse_temp->load(file);
539 }
545 template<typename particles_type>
546 void update(particles_type &particles) {
547 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
548 dcpse_temp->template createNormalParticles<NORMAL_ID>(particles);
549 dcpse_temp->initializeUpdate(particles);
550 dcpse_temp->accumulateAndDeleteNormalParticles(particles);
551
552 }
553};
554
555template<unsigned int NORMAL_ID>
556class SurfaceDerivative_zz {
557
558 void *dcpse;
559
560public:
573 template<typename particles_type>
574 SurfaceDerivative_zz(particles_type &parts, unsigned int ord, typename particles_type::stype rCut,typename particles_type::stype nSpacing,
575 support_options opt = support_options::RADIUS) {
577 p.zero();
578 p.get(2) = 2;
579
580 dcpse = new Dcpse<particles_type::dims, particles_type>(parts, p, ord, rCut,nSpacing,value_t<NORMAL_ID>(), opt);
581 }
582
583 template<typename particles_type>
584 void deallocate(particles_type &parts) {
585 delete (Dcpse<particles_type::dims, particles_type> *) dcpse;
586 }
587
588 template<typename operand_type>
590 operator()(operand_type arg) {
591 typedef Dcpse<operand_type::vtype::dims, typename operand_type::vtype> dcpse_type;
592
594 }
595
596 template<typename particles_type>
597 void checkMomenta(particles_type &particles) {
598 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
599 dcpse_temp->checkMomenta(particles);
600
601 }
602
603 template<unsigned int prp, typename particles_type>
604 void DrawKernel(particles_type &particles, int k) {
605 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
606 dcpse_temp->template DrawKernel<prp>(particles, k);
607
608 }
609
615 template<typename particles_type>
616 void save(particles_type &particles, const std::string &file) {
617 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
618 dcpse_temp->save(file);
619 }
625 template<typename particles_type>
626 void load(particles_type &particles, const std::string &file) {
627 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
628 dcpse_temp->load(file);
629 }
635 template<typename particles_type>
636 void update(particles_type &particles) {
637 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
638 dcpse_temp->template createNormalParticles<NORMAL_ID>(particles);
639 particles.write("With Normal");
640 dcpse_temp->initializeUpdate(particles);
641 dcpse_temp->accumulateAndDeleteNormalParticles(particles);
642
643 }
644};
645
646template<unsigned int NORMAL_ID>
647class SurfaceDerivative_xy {
648
649 void *dcpse;
650
651public:
664 template<typename particles_type>
665 SurfaceDerivative_xy(particles_type &parts, unsigned int ord, typename particles_type::stype rCut,typename particles_type::stype nSpacing,
666 support_options opt = support_options::RADIUS) {
668 p.zero();
669 p.get(0) = 1;
670 p.get(1) = 1;
671
672 dcpse = new Dcpse<particles_type::dims, particles_type>(parts, p, ord, rCut,nSpacing,value_t<NORMAL_ID>(), opt);
673 }
674
675 template<typename particles_type>
676 void deallocate(particles_type &parts) {
677 delete (Dcpse<particles_type::dims, particles_type> *) dcpse;
678 }
679
680 template<typename operand_type>
682 operator()(operand_type arg) {
683 typedef Dcpse<operand_type::vtype::dims, typename operand_type::vtype> dcpse_type;
684
686 }
687
688 template<typename particles_type>
689 void checkMomenta(particles_type &particles) {
690 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
691 dcpse_temp->checkMomenta(particles);
692
693 }
694
695 template<unsigned int prp, typename particles_type>
696 void DrawKernel(particles_type &particles, int k) {
697 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
698 dcpse_temp->template DrawKernel<prp>(particles, k);
699
700 }
701
707 template<typename particles_type>
708 void save(particles_type &particles, const std::string &file) {
709 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
710 dcpse_temp->save(file);
711 }
717 template<typename particles_type>
718 void load(particles_type &particles, const std::string &file) {
719 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
720 dcpse_temp->load(file);
721 }
727 template<typename particles_type>
728 void update(particles_type &particles) {
729 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
730 dcpse_temp->template createNormalParticles<NORMAL_ID>(particles);
731 dcpse_temp->initializeUpdate(particles);
732 dcpse_temp->accumulateAndDeleteNormalParticles(particles);
733
734 }
735};
736
737
738template<unsigned int NORMAL_ID>
739class SurfaceDerivative_yz {
740
741 void *dcpse;
742
743public:
756 template<typename particles_type>
757 SurfaceDerivative_yz(particles_type &parts, unsigned int ord, typename particles_type::stype rCut,typename particles_type::stype nSpacing,
758 support_options opt = support_options::RADIUS) {
760 p.zero();
761 p.get(1) = 1;
762 p.get(2) = 1;
763
764 dcpse = new Dcpse<particles_type::dims, particles_type>(parts, p, ord, rCut,nSpacing,value_t<NORMAL_ID>(), opt);
765 }
766
767 template<typename particles_type>
768 void deallocate(particles_type &parts) {
769 delete (Dcpse<particles_type::dims, particles_type> *) dcpse;
770 }
771
772 template<typename operand_type>
774 operator()(operand_type arg) {
775 typedef Dcpse<operand_type::vtype::dims, typename operand_type::vtype> dcpse_type;
776
778 }
779
780 template<typename particles_type>
781 void checkMomenta(particles_type &particles) {
782 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
783 dcpse_temp->checkMomenta(particles);
784
785 }
786
787 template<unsigned int prp, typename particles_type>
788 void DrawKernel(particles_type &particles, int k) {
789 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
790 dcpse_temp->template DrawKernel<prp>(particles, k);
791
792 }
793
799 template<typename particles_type>
800 void save(particles_type &particles, const std::string &file) {
801 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
802 dcpse_temp->save(file);
803 }
809 template<typename particles_type>
810 void load(particles_type &particles, const std::string &file) {
811 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
812 dcpse_temp->load(file);
813 }
819 template<typename particles_type>
820 void update(particles_type &particles) {
821 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
822 dcpse_temp->template createNormalParticles<NORMAL_ID>(particles);
823 dcpse_temp->initializeUpdate(particles);
824 dcpse_temp->accumulateAndDeleteNormalParticles(particles);
825
826 }
827};
828
829
830template<unsigned int NORMAL_ID>
831class SurfaceDerivative_xz {
832
833 void *dcpse;
834
835public:
848 template<typename particles_type>
849 SurfaceDerivative_xz(particles_type &parts, unsigned int ord, typename particles_type::stype rCut,typename particles_type::stype nSpacing,
850 support_options opt = support_options::RADIUS) {
852 p.zero();
853 p.get(0) = 1;
854 p.get(2) = 1;
855
856 dcpse = new Dcpse<particles_type::dims, particles_type>(parts, p, ord, rCut,nSpacing,value_t<NORMAL_ID>(), opt);
857 }
858
859 template<typename particles_type>
860 void deallocate(particles_type &parts) {
861 delete (Dcpse<particles_type::dims, particles_type> *) dcpse;
862 }
863
864 template<typename operand_type>
866 operator()(operand_type arg) {
867 typedef Dcpse<operand_type::vtype::dims, typename operand_type::vtype> dcpse_type;
868
870 }
871
872 template<typename particles_type>
873 void checkMomenta(particles_type &particles) {
874 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
875 dcpse_temp->checkMomenta(particles);
876
877 }
878
879 template<unsigned int prp, typename particles_type>
880 void DrawKernel(particles_type &particles, int k) {
881 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
882 dcpse_temp->template DrawKernel<prp>(particles, k);
883
884 }
885
891 template<typename particles_type>
892 void save(particles_type &particles, const std::string &file) {
893 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
894 dcpse_temp->save(file);
895 }
901 template<typename particles_type>
902 void load(particles_type &particles, const std::string &file) {
903 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
904 dcpse_temp->load(file);
905 }
911 template<typename particles_type>
912 void update(particles_type &particles) {
913 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
914 dcpse_temp->template createNormalParticles<NORMAL_ID>(particles);
915 dcpse_temp->initializeUpdate(particles);
916 dcpse_temp->accumulateAndDeleteNormalParticles(particles);
917
918 }
919};
920
921template<unsigned int NORMAL_ID>
922class SurfaceDerivative_G {
923
924 void *dcpse;
925
926public:
939 template<typename particles_type>
940 SurfaceDerivative_G(particles_type &parts, unsigned int ord, typename particles_type::stype rCut,typename particles_type::stype nSpacing,
941 const Point<particles_type::dims, unsigned int> &p,support_options opt = support_options::RADIUS) {
942
943 dcpse = new Dcpse<particles_type::dims, particles_type>(parts, p, ord, rCut,nSpacing,value_t<NORMAL_ID>(), opt);
944 }
945
946 template<typename particles_type>
947 void deallocate(particles_type &parts) {
948 delete (Dcpse<particles_type::dims, particles_type> *) dcpse;
949 }
950
951 template<typename operand_type>
953 operator()(operand_type arg) {
954 typedef Dcpse<operand_type::vtype::dims, typename operand_type::vtype> dcpse_type;
955
957 }
958
959 template<typename particles_type>
960 void checkMomenta(particles_type &particles) {
961 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
962 dcpse_temp->checkMomenta(particles);
963
964 }
965
966 template<unsigned int prp, typename particles_type>
967 void DrawKernel(particles_type &particles, int k) {
968 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
969 dcpse_temp->template DrawKernel<prp>(particles, k);
970
971 }
972
978 template<typename particles_type>
979 void save(particles_type &particles, const std::string &file) {
980 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
981 dcpse_temp->save(file);
982 }
988 template<typename particles_type>
989 void load(particles_type &particles, const std::string &file) {
990 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
991 dcpse_temp->load(file);
992 }
998 template<typename particles_type>
999 void update(particles_type &particles) {
1000 auto dcpse_temp = (Dcpse<particles_type::dims, particles_type> *) dcpse;
1001 dcpse_temp->template createNormalParticles<NORMAL_ID>(particles);
1002 dcpse_temp->initializeUpdate(particles);
1003 dcpse_temp->accumulateAndDeleteNormalParticles(particles);
1004
1005 }
1006};
1007#endif //Eigen
1008#endif //OPENFPM_PDATA_DCPSE_SURFACE_OP_HPP
This class implement the point shape in an N-dimensional space.
Definition Point.hpp:28
__device__ __host__ void zero()
Set to zero the point coordinate.
Definition Point.hpp:284
__device__ __host__ const T & get(unsigned int i) const
Get coordinate.
Definition Point.hpp:172
Unknown operation specialization.
Distributed vector.
bool write(std::string out, int opt=VTK_WRITER)
Output particle position and properties.