14#include "spline_builder.hpp"
15#include "spline_builder_2d.hpp"
20
21
22
23
24
25
26
47 using exec_space = ExecSpace;
50 using memory_space = MemorySpace;
53 using builder_type1 =
ddc::
54 SplineBuilder<ExecSpace, MemorySpace, BSpline1, DDimI1, BcLower1, BcUpper1, Solver>;
71 using continuous_dimension_type1 =
typename builder_type1::continuous_dimension_type;
74 using continuous_dimension_type2 =
typename builder_type_2_3::continuous_dimension_type1;
77 using continuous_dimension_type3 =
typename builder_type_2_3::continuous_dimension_type2;
80 using interpolation_discrete_dimension_type1 =
81 typename builder_type1::interpolation_discrete_dimension_type;
84 using interpolation_discrete_dimension_type2 =
85 typename builder_type_2_3::interpolation_discrete_dimension_type1;
88 using interpolation_discrete_dimension_type3 =
89 typename builder_type_2_3::interpolation_discrete_dimension_type2;
92 using bsplines_type1 =
typename builder_type1::bsplines_type;
95 using bsplines_type2 =
typename builder_type_2_3::bsplines_type1;
98 using bsplines_type3 =
typename builder_type_2_3::bsplines_type2;
101 using deriv_type1 =
typename builder_type1::deriv_type;
104 using deriv_type2 =
typename builder_type_2_3::deriv_type1;
107 using deriv_type3 =
typename builder_type_2_3::deriv_type2;
110 using interpolation_domain_type1 =
111 typename builder_type1::interpolation_discrete_dimension_type;
114 using interpolation_domain_type2 =
115 typename builder_type_2_3::interpolation_discrete_dimension_type1;
118 using interpolation_domain_type3 =
119 typename builder_type_2_3::interpolation_discrete_dimension_type2;
123 interpolation_discrete_dimension_type1,
124 interpolation_discrete_dimension_type2,
125 interpolation_discrete_dimension_type3>;
128
129
130
131
133 class BatchedInterpolationDDom,
134 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
135 using batched_interpolation_domain_type = BatchedInterpolationDDom;
138
139
140
141
142
143
144
145
147 class BatchedInterpolationDDom,
148 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
149 using batch_domain_type =
ddc::remove_dims_of_t<
150 BatchedInterpolationDDom,
151 interpolation_discrete_dimension_type1,
152 interpolation_discrete_dimension_type2,
153 interpolation_discrete_dimension_type3>;
156
157
158
159
160
161
162
163
165 class BatchedInterpolationDDom,
166 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
167 using batched_spline_domain_type
168 =
ddc::detail::convert_type_seq_to_discrete_domain_t<
ddc::type_seq_replace_t<
169 ddc::to_type_seq_t<BatchedInterpolationDDom>,
170 ddc::detail::TypeSeq<
171 interpolation_discrete_dimension_type1,
172 interpolation_discrete_dimension_type2,
173 interpolation_discrete_dimension_type3>,
174 ddc::detail::TypeSeq<bsplines_type1, bsplines_type2, bsplines_type3>>>;
177
178
179
180
181
182
183
184
186 class BatchedInterpolationDDom,
187 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
188 using batched_derivs_domain_type1 =
ddc::replace_dim_of_t<
189 BatchedInterpolationDDom,
190 interpolation_discrete_dimension_type1,
194
195
196
197
198
199
200
201
203 class BatchedInterpolationDDom,
204 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
205 using batched_derivs_domain_type2 =
ddc::replace_dim_of_t<
206 BatchedInterpolationDDom,
207 interpolation_discrete_dimension_type2,
211
212
213
214
215
216
217
218
220 class BatchedInterpolationDDom,
221 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
222 using batched_derivs_domain_type3 =
ddc::replace_dim_of_t<
223 BatchedInterpolationDDom,
224 interpolation_discrete_dimension_type3,
228
229
230
231
232
233
234
235
236
238 class BatchedInterpolationDDom,
239 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
240 using batched_derivs_domain_type1_2 =
ddc::replace_dim_of_t<
241 ddc::replace_dim_of_t<
242 BatchedInterpolationDDom,
243 interpolation_discrete_dimension_type1,
245 interpolation_domain_type2,
249
250
251
252
253
254
255
256
257
259 class BatchedInterpolationDDom,
260 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
261 using batched_derivs_domain_type2_3 =
ddc::replace_dim_of_t<
262 ddc::replace_dim_of_t<
263 BatchedInterpolationDDom,
264 interpolation_discrete_dimension_type2,
266 interpolation_domain_type3,
270
271
272
273
274
275
276
277
278
280 class BatchedInterpolationDDom,
281 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
282 using batched_derivs_domain_type1_3 =
ddc::replace_dim_of_t<
283 ddc::replace_dim_of_t<
284 BatchedInterpolationDDom,
285 interpolation_discrete_dimension_type1,
287 interpolation_domain_type3,
291
292
293
294
295
296
297
298
300 class BatchedInterpolationDDom,
301 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
302 using batched_derivs_domain_type
303 =
ddc::detail::convert_type_seq_to_discrete_domain_t<
ddc::type_seq_replace_t<
304 ddc::to_type_seq_t<BatchedInterpolationDDom>,
305 ddc::detail::TypeSeq<
306 interpolation_discrete_dimension_type1,
307 interpolation_discrete_dimension_type2,
308 interpolation_discrete_dimension_type3>,
309 ddc::detail::TypeSeq<deriv_type1, deriv_type2, deriv_type3>>>;
312 builder_type1 m_spline_builder1;
313 builder_type_2_3 m_spline_builder_2_3;
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
333 interpolation_domain_type
const& interpolation_domain,
334 std::optional<std::size_t> cols_per_chunk = std::nullopt,
335 std::optional<
unsigned int> preconditioner_max_block_size = std::nullopt)
336 : m_spline_builder1(interpolation_domain, cols_per_chunk, preconditioner_max_block_size)
337 , m_spline_builder_2_3(interpolation_domain, cols_per_chunk, preconditioner_max_block_size)
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
358 class BatchedInterpolationDDom,
359 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
361 BatchedInterpolationDDom
const& batched_interpolation_domain,
362 std::optional<std::size_t> cols_per_chunk = std::nullopt,
363 std::optional<
unsigned int> preconditioner_max_block_size = std::nullopt)
365 interpolation_domain_type(batched_interpolation_domain),
367 preconditioner_max_block_size)
375
376
377
378
388
389
390
391
395
396
397
398
399
400
404 interpolation_domain_type1,
405 interpolation_domain_type2,
406 interpolation_domain_type3>(
407 m_spline_builder1.interpolation_domain(),
408 m_spline_builder_2_3.interpolation_domain());
412
413
414
415
416
417
418
419
420
422 class BatchedInterpolationDDom,
423 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
425 BatchedInterpolationDDom
const& batched_interpolation_domain)
const noexcept
427 assert(interpolation_domain() == interpolation_domain_type(batched_interpolation_domain));
428 return batched_interpolation_domain;
432
433
434
435
436
437
438
439
441 class BatchedInterpolationDDom,
442 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
443 batch_domain_type<BatchedInterpolationDDom>
batch_domain(
444 BatchedInterpolationDDom
const& batched_interpolation_domain)
const noexcept
446 assert(interpolation_domain() == interpolation_domain_type(batched_interpolation_domain));
451
452
453
454
455
456
461 ddc::discrete_space<bsplines_type1>().full_domain(),
462 ddc::discrete_space<bsplines_type2>().full_domain(),
463 ddc::discrete_space<bsplines_type3>().full_domain());
467
468
469
470
471
472
473
474
476 class BatchedInterpolationDDom,
477 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
479 BatchedInterpolationDDom
const& batched_interpolation_domain)
const noexcept
481 assert(interpolation_domain() == interpolation_domain_type(batched_interpolation_domain));
482 return ddc::replace_dim_of<interpolation_discrete_dimension_type1, bsplines_type1>(
483 ddc::replace_dim_of<interpolation_discrete_dimension_type2, bsplines_type2>(
485 interpolation_discrete_dimension_type3,
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559 template <
class Layout,
class BatchedInterpolationDDom>
563 batched_spline_domain_type<BatchedInterpolationDDom>,
565 memory_space> spline,
566 ddc::
ChunkSpan<
double const, BatchedInterpolationDDom, Layout, memory_space> vals,
569 batched_derivs_domain_type1<BatchedInterpolationDDom>,
571 memory_space>> derivs_min1
575 batched_derivs_domain_type1<BatchedInterpolationDDom>,
577 memory_space>> derivs_max1
581 batched_derivs_domain_type2<BatchedInterpolationDDom>,
583 memory_space>> derivs_min2
587 batched_derivs_domain_type2<BatchedInterpolationDDom>,
589 memory_space>> derivs_max2
593 batched_derivs_domain_type3<BatchedInterpolationDDom>,
595 memory_space>> derivs_min3
599 batched_derivs_domain_type3<BatchedInterpolationDDom>,
601 memory_space>> derivs_max3
605 batched_derivs_domain_type1_2<BatchedInterpolationDDom>,
607 memory_space>> mixed_derivs_min1_min2
611 batched_derivs_domain_type1_2<BatchedInterpolationDDom>,
613 memory_space>> mixed_derivs_max1_min2
617 batched_derivs_domain_type1_2<BatchedInterpolationDDom>,
619 memory_space>> mixed_derivs_min1_max2
623 batched_derivs_domain_type1_2<BatchedInterpolationDDom>,
625 memory_space>> mixed_derivs_max1_max2
629 batched_derivs_domain_type2_3<BatchedInterpolationDDom>,
631 memory_space>> mixed_derivs_min2_min3
635 batched_derivs_domain_type2_3<BatchedInterpolationDDom>,
637 memory_space>> mixed_derivs_max2_min3
641 batched_derivs_domain_type2_3<BatchedInterpolationDDom>,
643 memory_space>> mixed_derivs_min2_max3
647 batched_derivs_domain_type2_3<BatchedInterpolationDDom>,
649 memory_space>> mixed_derivs_max2_max3
653 batched_derivs_domain_type1_3<BatchedInterpolationDDom>,
655 memory_space>> mixed_derivs_min1_min3
659 batched_derivs_domain_type1_3<BatchedInterpolationDDom>,
661 memory_space>> mixed_derivs_max1_min3
665 batched_derivs_domain_type1_3<BatchedInterpolationDDom>,
667 memory_space>> mixed_derivs_min1_max3
671 batched_derivs_domain_type1_3<BatchedInterpolationDDom>,
673 memory_space>> mixed_derivs_max1_max3
677 batched_derivs_domain_type<BatchedInterpolationDDom>,
679 memory_space>> mixed_derivs_min1_min2_min3
683 batched_derivs_domain_type<BatchedInterpolationDDom>,
685 memory_space>> mixed_derivs_max1_min2_min3
689 batched_derivs_domain_type<BatchedInterpolationDDom>,
691 memory_space>> mixed_derivs_min1_max2_min3
695 batched_derivs_domain_type<BatchedInterpolationDDom>,
697 memory_space>> mixed_derivs_max1_max2_min3
701 batched_derivs_domain_type<BatchedInterpolationDDom>,
703 memory_space>> mixed_derivs_min1_min2_max3
707 batched_derivs_domain_type<BatchedInterpolationDDom>,
709 memory_space>> mixed_derivs_max1_min2_max3
713 batched_derivs_domain_type<BatchedInterpolationDDom>,
715 memory_space>> mixed_derivs_min1_max2_max3
719 batched_derivs_domain_type<BatchedInterpolationDDom>,
721 memory_space>> mixed_derivs_max1_max2_max3
722 = std::nullopt)
const;
742template <
class Layout,
class BatchedInterpolationDDom>
762 batched_spline_domain_type<BatchedInterpolationDDom>,
764 memory_space> spline,
765 ddc::
ChunkSpan<
double const, BatchedInterpolationDDom, Layout, memory_space> vals,
768 batched_derivs_domain_type1<BatchedInterpolationDDom>,
770 memory_space>> derivs_min1,
773 batched_derivs_domain_type1<BatchedInterpolationDDom>,
775 memory_space>> derivs_max1,
778 batched_derivs_domain_type2<BatchedInterpolationDDom>,
780 memory_space>> derivs_min2,
783 batched_derivs_domain_type2<BatchedInterpolationDDom>,
785 memory_space>> derivs_max2,
788 batched_derivs_domain_type3<BatchedInterpolationDDom>,
790 memory_space>> derivs_min3,
793 batched_derivs_domain_type3<BatchedInterpolationDDom>,
795 memory_space>> derivs_max3,
798 batched_derivs_domain_type1_2<BatchedInterpolationDDom>,
800 memory_space>> mixed_derivs_min1_min2,
803 batched_derivs_domain_type1_2<BatchedInterpolationDDom>,
805 memory_space>> mixed_derivs_max1_min2,
808 batched_derivs_domain_type1_2<BatchedInterpolationDDom>,
810 memory_space>> mixed_derivs_min1_max2,
813 batched_derivs_domain_type1_2<BatchedInterpolationDDom>,
815 memory_space>> mixed_derivs_max1_max2,
818 batched_derivs_domain_type2_3<BatchedInterpolationDDom>,
820 memory_space>> mixed_derivs_min2_min3,
823 batched_derivs_domain_type2_3<BatchedInterpolationDDom>,
825 memory_space>> mixed_derivs_max2_min3,
828 batched_derivs_domain_type2_3<BatchedInterpolationDDom>,
830 memory_space>> mixed_derivs_min2_max3,
833 batched_derivs_domain_type2_3<BatchedInterpolationDDom>,
835 memory_space>> mixed_derivs_max2_max3,
838 batched_derivs_domain_type1_3<BatchedInterpolationDDom>,
840 memory_space>> mixed_derivs_min1_min3,
843 batched_derivs_domain_type1_3<BatchedInterpolationDDom>,
845 memory_space>> mixed_derivs_max1_min3,
848 batched_derivs_domain_type1_3<BatchedInterpolationDDom>,
850 memory_space>> mixed_derivs_min1_max3,
853 batched_derivs_domain_type1_3<BatchedInterpolationDDom>,
855 memory_space>> mixed_derivs_max1_max3,
858 batched_derivs_domain_type<BatchedInterpolationDDom>,
860 memory_space>> mixed_derivs_min1_min2_min3,
863 batched_derivs_domain_type<BatchedInterpolationDDom>,
865 memory_space>> mixed_derivs_max1_min2_min3,
868 batched_derivs_domain_type<BatchedInterpolationDDom>,
870 memory_space>> mixed_derivs_min1_max2_min3,
873 batched_derivs_domain_type<BatchedInterpolationDDom>,
875 memory_space>> mixed_derivs_max1_max2_min3,
878 batched_derivs_domain_type<BatchedInterpolationDDom>,
880 memory_space>> mixed_derivs_min1_min2_max3,
883 batched_derivs_domain_type<BatchedInterpolationDDom>,
885 memory_space>> mixed_derivs_max1_min2_max3,
888 batched_derivs_domain_type<BatchedInterpolationDDom>,
890 memory_space>> mixed_derivs_min1_max2_max3,
893 batched_derivs_domain_type<BatchedInterpolationDDom>,
895 memory_space>> mixed_derivs_max1_max2_max3)
const
897 auto const batched_interpolation_domain = vals.domain();
899 assert(interpolation_domain() == interpolation_domain_type(batched_interpolation_domain));
902 auto const batched_interpolation_deriv_domain2
903 =
ddc::replace_dim_of<interpolation_discrete_dimension_type2, deriv_type2>(
904 batched_interpolation_domain,
906 ddc::DiscreteElement<deriv_type2>(1),
909 ddc::
Chunk spline_derivs_min2_alloc(
910 m_spline_builder1.batched_spline_domain(batched_interpolation_deriv_domain2),
912 auto spline_derivs_min2 = spline_derivs_min2_alloc.span_view();
913 auto spline_derivs_min2_opt = std::optional(spline_derivs_min2.span_cview());
918 mixed_derivs_min1_min2,
919 mixed_derivs_max1_min2);
921 spline_derivs_min2_opt = std::nullopt;
924 ddc::
Chunk spline_derivs_max2_alloc(
925 m_spline_builder1.batched_spline_domain(batched_interpolation_deriv_domain2),
927 auto spline_derivs_max2 = spline_derivs_max2_alloc.span_view();
928 auto spline_derivs_max2_opt = std::optional(spline_derivs_max2.span_cview());
933 mixed_derivs_min1_max2,
934 mixed_derivs_max1_max2);
936 spline_derivs_max2_opt = std::nullopt;
940 auto const batched_interpolation_deriv_domain3
941 =
ddc::replace_dim_of<interpolation_discrete_dimension_type3, deriv_type3>(
942 batched_interpolation_domain,
944 ddc::DiscreteElement<deriv_type3>(1),
947 ddc::
Chunk spline_derivs_min3_alloc(
948 m_spline_builder1.batched_spline_domain(batched_interpolation_deriv_domain3),
950 auto spline_derivs_min3 = spline_derivs_min3_alloc.span_view();
951 auto spline_derivs_min3_opt = std::optional(spline_derivs_min3.span_cview());
956 mixed_derivs_min1_min3,
957 mixed_derivs_max1_min3);
959 spline_derivs_min3_opt = std::nullopt;
962 ddc::
Chunk spline_derivs_max3_alloc(
963 m_spline_builder1.batched_spline_domain(batched_interpolation_deriv_domain3),
965 auto spline_derivs_max3 = spline_derivs_max3_alloc.span_view();
966 auto spline_derivs_max3_opt = std::optional(spline_derivs_max3.span_cview());
971 mixed_derivs_min1_max3,
972 mixed_derivs_max1_max3);
974 spline_derivs_max3_opt = std::nullopt;
978 auto batched_interpolation_deriv_domain2_3
979 =
ddc::replace_dim_of<interpolation_discrete_dimension_type3, deriv_type3>(
980 batched_interpolation_deriv_domain2,
982 ddc::DiscreteElement<deriv_type3>(1),
985 ddc::
Chunk spline_derivs_min2_min3_alloc(
986 m_spline_builder1.batched_spline_domain(batched_interpolation_deriv_domain2_3),
988 auto spline_derivs_min2_min3 = spline_derivs_min2_min3_alloc.span_view();
989 auto spline_derivs_min2_min3_opt = std::optional(spline_derivs_min2_min3.span_cview());
992 spline_derivs_min2_min3,
993 *mixed_derivs_min2_min3,
994 mixed_derivs_min1_min2_min3,
995 mixed_derivs_max1_min2_min3);
997 spline_derivs_min2_min3_opt = std::nullopt;
1000 ddc::
Chunk spline_derivs_min2_max3_alloc(
1001 m_spline_builder1.batched_spline_domain(batched_interpolation_deriv_domain2_3),
1003 auto spline_derivs_min2_max3 = spline_derivs_min2_max3_alloc.span_view();
1004 auto spline_derivs_min2_max3_opt = std::optional(spline_derivs_min2_max3.span_cview());
1007 spline_derivs_min2_max3,
1008 *mixed_derivs_min2_max3,
1009 mixed_derivs_min1_min2_max3,
1010 mixed_derivs_max1_min2_max3);
1012 spline_derivs_min2_max3_opt = std::nullopt;
1015 ddc::
Chunk spline_derivs_max2_min3_alloc(
1016 m_spline_builder1.batched_spline_domain(batched_interpolation_deriv_domain2_3),
1018 auto spline_derivs_max2_min3 = spline_derivs_max2_min3_alloc.span_view();
1019 auto spline_derivs_max2_min3_opt = std::optional(spline_derivs_max2_min3.span_cview());
1022 spline_derivs_max2_min3,
1023 *mixed_derivs_max2_min3,
1024 mixed_derivs_min1_max2_min3,
1025 mixed_derivs_max1_max2_min3);
1027 spline_derivs_max2_min3_opt = std::nullopt;
1030 ddc::
Chunk spline_derivs_max2_max3_alloc(
1031 m_spline_builder1.batched_spline_domain(batched_interpolation_deriv_domain2_3),
1033 auto spline_derivs_max2_max3 = spline_derivs_max2_max3_alloc.span_view();
1034 auto spline_derivs_max2_max3_opt = std::optional(spline_derivs_max2_max3.span_cview());
1037 spline_derivs_max2_max3,
1038 *mixed_derivs_max2_max3,
1039 mixed_derivs_min1_max2_max3,
1040 mixed_derivs_max1_max2_max3);
1042 spline_derivs_max2_max3_opt = std::nullopt;
1047 m_spline_builder1.batched_spline_domain(batched_interpolation_domain),
1049 ddc::
ChunkSpan const spline1 = spline1_alloc.span_view();
1051 m_spline_builder1(spline1, vals, derivs_min1, derivs_max1);
1053 m_spline_builder_2_3(
1055 spline1.span_cview(),
1056 spline_derivs_min2_opt,
1057 spline_derivs_max2_opt,
1058 spline_derivs_min3_opt,
1059 spline_derivs_max3_opt,
1060 spline_derivs_min2_min3_opt,
1061 spline_derivs_max2_min3_opt,
1062 spline_derivs_min2_max3_opt,
1063 spline_derivs_max2_max3_opt);
friend class DiscreteDomain
KOKKOS_FUNCTION constexpr bool operator!=(DiscreteVector< OTags... > const &rhs) const noexcept
A class for creating a 2D spline approximation of a function.
A class for creating a 3D spline approximation of a function.
SplineBuilder3D(SplineBuilder3D const &x)=delete
Copy-constructor is deleted.
void operator()(ddc::ChunkSpan< double, batched_spline_domain_type< BatchedInterpolationDDom >, Layout, memory_space > spline, ddc::ChunkSpan< double const, BatchedInterpolationDDom, Layout, memory_space > vals, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type1< BatchedInterpolationDDom >, Layout, memory_space > > derivs_min1=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type1< BatchedInterpolationDDom >, Layout, memory_space > > derivs_max1=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type2< BatchedInterpolationDDom >, Layout, memory_space > > derivs_min2=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type2< BatchedInterpolationDDom >, Layout, memory_space > > derivs_max2=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type3< BatchedInterpolationDDom >, Layout, memory_space > > derivs_min3=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type3< BatchedInterpolationDDom >, Layout, memory_space > > derivs_max3=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type1_2< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_min1_min2=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type1_2< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_max1_min2=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type1_2< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_min1_max2=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type1_2< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_max1_max2=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type2_3< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_min2_min3=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type2_3< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_max2_min3=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type2_3< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_min2_max3=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type2_3< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_max2_max3=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type1_3< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_min1_min3=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type1_3< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_max1_min3=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type1_3< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_min1_max3=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type1_3< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_max1_max3=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_min1_min2_min3=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_max1_min2_min3=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_min1_max2_min3=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_max1_max2_min3=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_min1_min2_max3=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_max1_min2_max3=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_min1_max2_max3=std::nullopt, std::optional< ddc::ChunkSpan< double const, batched_derivs_domain_type< BatchedInterpolationDDom >, Layout, memory_space > > mixed_derivs_max1_max2_max3=std::nullopt) const
Compute a 3D spline approximation of a function.
~SplineBuilder3D()=default
Destructs.
batched_spline_domain_type< BatchedInterpolationDDom > batched_spline_domain(BatchedInterpolationDDom const &batched_interpolation_domain) const noexcept
Get the whole domain on which spline coefficients are defined.
SplineBuilder3D(BatchedInterpolationDDom const &batched_interpolation_domain, std::optional< std::size_t > cols_per_chunk=std::nullopt, std::optional< unsigned int > preconditioner_max_block_size=std::nullopt)
Build a SplineBuilder3D acting on the interpolation domain contained in batched_interpolation_domain.
ddc::DiscreteDomain< bsplines_type1, bsplines_type2, bsplines_type3 > spline_domain() const noexcept
Get the 3D domain on which spline coefficients are defined.
batch_domain_type< BatchedInterpolationDDom > batch_domain(BatchedInterpolationDDom const &batched_interpolation_domain) const noexcept
Get the batch domain.
interpolation_domain_type interpolation_domain() const noexcept
Get the domain for the 3D interpolation mesh used by this class.
SplineBuilder3D & operator=(SplineBuilder3D const &x)=delete
Copy-assignment is deleted.
SplineBuilder3D(interpolation_domain_type const &interpolation_domain, std::optional< std::size_t > cols_per_chunk=std::nullopt, std::optional< unsigned int > preconditioner_max_block_size=std::nullopt)
Build a SplineBuilder3D acting on interpolation_domain.
SplineBuilder3D(SplineBuilder3D &&x)=default
Move-constructs.
BatchedInterpolationDDom batched_interpolation_domain(BatchedInterpolationDDom const &batched_interpolation_domain) const noexcept
Get the whole domain representing interpolation points.
SplineBuilder3D & operator=(SplineBuilder3D &&x)=default
Move-assigns.
A class for creating a spline approximation of a function.
The top-level namespace of DDC.
BoundCond
An enum representing a spline boundary condition.
@ HERMITE
Hermite boundary condition.
SplineSolver
An enum determining the backend solver of a SplineBuilder or SplineBuilder2d.