14#include "spline_boundary_conditions.hpp"
15#include "spline_builder.hpp"
16#include "spline_builder_2d.hpp"
21
22
23
24
25
26
27
48 using exec_space = ExecSpace;
51 using memory_space = MemorySpace;
54 using builder_type1 =
ddc::
55 SplineBuilder<ExecSpace, MemorySpace, BSpline1, DDimI1, BcLower1, BcUpper1, Solver>;
72 using continuous_dimension_type1 =
typename builder_type1::continuous_dimension_type;
75 using continuous_dimension_type2 =
typename builder_type_2_3::continuous_dimension_type1;
78 using continuous_dimension_type3 =
typename builder_type_2_3::continuous_dimension_type2;
81 using interpolation_discrete_dimension_type1 =
82 typename builder_type1::interpolation_discrete_dimension_type;
85 using interpolation_discrete_dimension_type2 =
86 typename builder_type_2_3::interpolation_discrete_dimension_type1;
89 using interpolation_discrete_dimension_type3 =
90 typename builder_type_2_3::interpolation_discrete_dimension_type2;
93 using bsplines_type1 =
typename builder_type1::bsplines_type;
96 using bsplines_type2 =
typename builder_type_2_3::bsplines_type1;
99 using bsplines_type3 =
typename builder_type_2_3::bsplines_type2;
102 using deriv_type1 =
typename builder_type1::deriv_type;
105 using deriv_type2 =
typename builder_type_2_3::deriv_type1;
108 using deriv_type3 =
typename builder_type_2_3::deriv_type2;
111 using interpolation_domain_type1 =
112 typename builder_type1::interpolation_discrete_dimension_type;
115 using interpolation_domain_type2 =
116 typename builder_type_2_3::interpolation_discrete_dimension_type1;
119 using interpolation_domain_type3 =
120 typename builder_type_2_3::interpolation_discrete_dimension_type2;
124 interpolation_discrete_dimension_type1,
125 interpolation_discrete_dimension_type2,
126 interpolation_discrete_dimension_type3>;
129
130
131
132
134 class BatchedInterpolationDDom,
135 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
136 using batched_interpolation_domain_type = BatchedInterpolationDDom;
139
140
141
142
143
144
145
146
148 class BatchedInterpolationDDom,
149 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
150 using batch_domain_type =
ddc::remove_dims_of_t<
151 BatchedInterpolationDDom,
152 interpolation_discrete_dimension_type1,
153 interpolation_discrete_dimension_type2,
154 interpolation_discrete_dimension_type3>;
157
158
159
160
161
162
163
164
166 class BatchedInterpolationDDom,
167 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
168 using batched_spline_domain_type
169 =
ddc::detail::convert_type_seq_to_discrete_domain_t<
ddc::type_seq_replace_t<
170 ddc::to_type_seq_t<BatchedInterpolationDDom>,
171 ddc::detail::TypeSeq<
172 interpolation_discrete_dimension_type1,
173 interpolation_discrete_dimension_type2,
174 interpolation_discrete_dimension_type3>,
175 ddc::detail::TypeSeq<bsplines_type1, bsplines_type2, bsplines_type3>>>;
178
179
180
181
182
183
184
185
187 class BatchedInterpolationDDom,
188 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
189 using batched_derivs_domain_type1 =
ddc::replace_dim_of_t<
190 BatchedInterpolationDDom,
191 interpolation_discrete_dimension_type1,
195
196
197
198
199
200
201
202
204 class BatchedInterpolationDDom,
205 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
206 using batched_derivs_domain_type2 =
ddc::replace_dim_of_t<
207 BatchedInterpolationDDom,
208 interpolation_discrete_dimension_type2,
212
213
214
215
216
217
218
219
221 class BatchedInterpolationDDom,
222 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
223 using batched_derivs_domain_type3 =
ddc::replace_dim_of_t<
224 BatchedInterpolationDDom,
225 interpolation_discrete_dimension_type3,
229
230
231
232
233
234
235
236
237
239 class BatchedInterpolationDDom,
240 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
241 using batched_derivs_domain_type1_2 =
ddc::replace_dim_of_t<
242 ddc::replace_dim_of_t<
243 BatchedInterpolationDDom,
244 interpolation_discrete_dimension_type1,
246 interpolation_domain_type2,
250
251
252
253
254
255
256
257
258
260 class BatchedInterpolationDDom,
261 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
262 using batched_derivs_domain_type2_3 =
ddc::replace_dim_of_t<
263 ddc::replace_dim_of_t<
264 BatchedInterpolationDDom,
265 interpolation_discrete_dimension_type2,
267 interpolation_domain_type3,
271
272
273
274
275
276
277
278
279
281 class BatchedInterpolationDDom,
282 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
283 using batched_derivs_domain_type1_3 =
ddc::replace_dim_of_t<
284 ddc::replace_dim_of_t<
285 BatchedInterpolationDDom,
286 interpolation_discrete_dimension_type1,
288 interpolation_domain_type3,
292
293
294
295
296
297
298
299
301 class BatchedInterpolationDDom,
302 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
303 using batched_derivs_domain_type
304 =
ddc::detail::convert_type_seq_to_discrete_domain_t<
ddc::type_seq_replace_t<
305 ddc::to_type_seq_t<BatchedInterpolationDDom>,
306 ddc::detail::TypeSeq<
307 interpolation_discrete_dimension_type1,
308 interpolation_discrete_dimension_type2,
309 interpolation_discrete_dimension_type3>,
310 ddc::detail::TypeSeq<deriv_type1, deriv_type2, deriv_type3>>>;
313 builder_type1 m_spline_builder1;
314 builder_type_2_3 m_spline_builder_2_3;
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
334 interpolation_domain_type
const& interpolation_domain,
335 std::optional<std::size_t> cols_per_chunk = std::nullopt,
336 std::optional<
unsigned int> preconditioner_max_block_size = std::nullopt)
337 : m_spline_builder1(interpolation_domain, cols_per_chunk, preconditioner_max_block_size)
338 , m_spline_builder_2_3(interpolation_domain, cols_per_chunk, preconditioner_max_block_size)
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
359 class BatchedInterpolationDDom,
360 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
362 BatchedInterpolationDDom
const& batched_interpolation_domain,
363 std::optional<std::size_t> cols_per_chunk = std::nullopt,
364 std::optional<
unsigned int> preconditioner_max_block_size = std::nullopt)
366 interpolation_domain_type(batched_interpolation_domain),
368 preconditioner_max_block_size)
376
377
378
379
389
390
391
392
396
397
398
399
400
401
405 interpolation_domain_type1,
406 interpolation_domain_type2,
407 interpolation_domain_type3>(
408 m_spline_builder1.interpolation_domain(),
409 m_spline_builder_2_3.interpolation_domain());
413
414
415
416
417
418
419
420
421
423 class BatchedInterpolationDDom,
424 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
426 BatchedInterpolationDDom
const& batched_interpolation_domain)
const noexcept
428 assert(interpolation_domain() == interpolation_domain_type(batched_interpolation_domain));
429 return batched_interpolation_domain;
433
434
435
436
437
438
439
440
442 class BatchedInterpolationDDom,
443 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
444 batch_domain_type<BatchedInterpolationDDom>
batch_domain(
445 BatchedInterpolationDDom
const& batched_interpolation_domain)
const noexcept
447 assert(interpolation_domain() == interpolation_domain_type(batched_interpolation_domain));
452
453
454
455
456
457
462 ddc::discrete_space<bsplines_type1>().full_domain(),
463 ddc::discrete_space<bsplines_type2>().full_domain(),
464 ddc::discrete_space<bsplines_type3>().full_domain());
468
469
470
471
472
473
474
475
477 class BatchedInterpolationDDom,
478 class = std::enable_if_t<
ddc::is_discrete_domain_v<BatchedInterpolationDDom>>>
480 BatchedInterpolationDDom
const& batched_interpolation_domain)
const noexcept
482 assert(interpolation_domain() == interpolation_domain_type(batched_interpolation_domain));
483 return ddc::replace_dim_of<interpolation_discrete_dimension_type1, bsplines_type1>(
484 ddc::replace_dim_of<interpolation_discrete_dimension_type2, bsplines_type2>(
486 interpolation_discrete_dimension_type3,
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
560 template <
class Layout,
class BatchedInterpolationDDom>
564 batched_spline_domain_type<BatchedInterpolationDDom>,
566 memory_space> spline,
567 ddc::
ChunkSpan<
double const, BatchedInterpolationDDom, Layout, memory_space> vals,
570 batched_derivs_domain_type1<BatchedInterpolationDDom>,
572 memory_space>> derivs_min1
576 batched_derivs_domain_type1<BatchedInterpolationDDom>,
578 memory_space>> derivs_max1
582 batched_derivs_domain_type2<BatchedInterpolationDDom>,
584 memory_space>> derivs_min2
588 batched_derivs_domain_type2<BatchedInterpolationDDom>,
590 memory_space>> derivs_max2
594 batched_derivs_domain_type3<BatchedInterpolationDDom>,
596 memory_space>> derivs_min3
600 batched_derivs_domain_type3<BatchedInterpolationDDom>,
602 memory_space>> derivs_max3
606 batched_derivs_domain_type1_2<BatchedInterpolationDDom>,
608 memory_space>> mixed_derivs_min1_min2
612 batched_derivs_domain_type1_2<BatchedInterpolationDDom>,
614 memory_space>> mixed_derivs_max1_min2
618 batched_derivs_domain_type1_2<BatchedInterpolationDDom>,
620 memory_space>> mixed_derivs_min1_max2
624 batched_derivs_domain_type1_2<BatchedInterpolationDDom>,
626 memory_space>> mixed_derivs_max1_max2
630 batched_derivs_domain_type2_3<BatchedInterpolationDDom>,
632 memory_space>> mixed_derivs_min2_min3
636 batched_derivs_domain_type2_3<BatchedInterpolationDDom>,
638 memory_space>> mixed_derivs_max2_min3
642 batched_derivs_domain_type2_3<BatchedInterpolationDDom>,
644 memory_space>> mixed_derivs_min2_max3
648 batched_derivs_domain_type2_3<BatchedInterpolationDDom>,
650 memory_space>> mixed_derivs_max2_max3
654 batched_derivs_domain_type1_3<BatchedInterpolationDDom>,
656 memory_space>> mixed_derivs_min1_min3
660 batched_derivs_domain_type1_3<BatchedInterpolationDDom>,
662 memory_space>> mixed_derivs_max1_min3
666 batched_derivs_domain_type1_3<BatchedInterpolationDDom>,
668 memory_space>> mixed_derivs_min1_max3
672 batched_derivs_domain_type1_3<BatchedInterpolationDDom>,
674 memory_space>> mixed_derivs_max1_max3
678 batched_derivs_domain_type<BatchedInterpolationDDom>,
680 memory_space>> mixed_derivs_min1_min2_min3
684 batched_derivs_domain_type<BatchedInterpolationDDom>,
686 memory_space>> mixed_derivs_max1_min2_min3
690 batched_derivs_domain_type<BatchedInterpolationDDom>,
692 memory_space>> mixed_derivs_min1_max2_min3
696 batched_derivs_domain_type<BatchedInterpolationDDom>,
698 memory_space>> mixed_derivs_max1_max2_min3
702 batched_derivs_domain_type<BatchedInterpolationDDom>,
704 memory_space>> mixed_derivs_min1_min2_max3
708 batched_derivs_domain_type<BatchedInterpolationDDom>,
710 memory_space>> mixed_derivs_max1_min2_max3
714 batched_derivs_domain_type<BatchedInterpolationDDom>,
716 memory_space>> mixed_derivs_min1_max2_max3
720 batched_derivs_domain_type<BatchedInterpolationDDom>,
722 memory_space>> mixed_derivs_max1_max2_max3
723 = std::nullopt)
const;
743template <
class Layout,
class BatchedInterpolationDDom>
763 batched_spline_domain_type<BatchedInterpolationDDom>,
765 memory_space> spline,
766 ddc::
ChunkSpan<
double const, BatchedInterpolationDDom, Layout, memory_space> vals,
769 batched_derivs_domain_type1<BatchedInterpolationDDom>,
771 memory_space>> derivs_min1,
774 batched_derivs_domain_type1<BatchedInterpolationDDom>,
776 memory_space>> derivs_max1,
779 batched_derivs_domain_type2<BatchedInterpolationDDom>,
781 memory_space>> derivs_min2,
784 batched_derivs_domain_type2<BatchedInterpolationDDom>,
786 memory_space>> derivs_max2,
789 batched_derivs_domain_type3<BatchedInterpolationDDom>,
791 memory_space>> derivs_min3,
794 batched_derivs_domain_type3<BatchedInterpolationDDom>,
796 memory_space>> derivs_max3,
799 batched_derivs_domain_type1_2<BatchedInterpolationDDom>,
801 memory_space>> mixed_derivs_min1_min2,
804 batched_derivs_domain_type1_2<BatchedInterpolationDDom>,
806 memory_space>> mixed_derivs_max1_min2,
809 batched_derivs_domain_type1_2<BatchedInterpolationDDom>,
811 memory_space>> mixed_derivs_min1_max2,
814 batched_derivs_domain_type1_2<BatchedInterpolationDDom>,
816 memory_space>> mixed_derivs_max1_max2,
819 batched_derivs_domain_type2_3<BatchedInterpolationDDom>,
821 memory_space>> mixed_derivs_min2_min3,
824 batched_derivs_domain_type2_3<BatchedInterpolationDDom>,
826 memory_space>> mixed_derivs_max2_min3,
829 batched_derivs_domain_type2_3<BatchedInterpolationDDom>,
831 memory_space>> mixed_derivs_min2_max3,
834 batched_derivs_domain_type2_3<BatchedInterpolationDDom>,
836 memory_space>> mixed_derivs_max2_max3,
839 batched_derivs_domain_type1_3<BatchedInterpolationDDom>,
841 memory_space>> mixed_derivs_min1_min3,
844 batched_derivs_domain_type1_3<BatchedInterpolationDDom>,
846 memory_space>> mixed_derivs_max1_min3,
849 batched_derivs_domain_type1_3<BatchedInterpolationDDom>,
851 memory_space>> mixed_derivs_min1_max3,
854 batched_derivs_domain_type1_3<BatchedInterpolationDDom>,
856 memory_space>> mixed_derivs_max1_max3,
859 batched_derivs_domain_type<BatchedInterpolationDDom>,
861 memory_space>> mixed_derivs_min1_min2_min3,
864 batched_derivs_domain_type<BatchedInterpolationDDom>,
866 memory_space>> mixed_derivs_max1_min2_min3,
869 batched_derivs_domain_type<BatchedInterpolationDDom>,
871 memory_space>> mixed_derivs_min1_max2_min3,
874 batched_derivs_domain_type<BatchedInterpolationDDom>,
876 memory_space>> mixed_derivs_max1_max2_min3,
879 batched_derivs_domain_type<BatchedInterpolationDDom>,
881 memory_space>> mixed_derivs_min1_min2_max3,
884 batched_derivs_domain_type<BatchedInterpolationDDom>,
886 memory_space>> mixed_derivs_max1_min2_max3,
889 batched_derivs_domain_type<BatchedInterpolationDDom>,
891 memory_space>> mixed_derivs_min1_max2_max3,
894 batched_derivs_domain_type<BatchedInterpolationDDom>,
896 memory_space>> mixed_derivs_max1_max2_max3)
const
898 auto const batched_interpolation_domain = vals.domain();
900 assert(interpolation_domain() == interpolation_domain_type(batched_interpolation_domain));
903 auto const batched_interpolation_deriv_domain2
904 =
ddc::replace_dim_of<interpolation_discrete_dimension_type2, deriv_type2>(
905 batched_interpolation_domain,
907 ddc::DiscreteElement<deriv_type2>(1),
910 ddc::
Chunk spline_derivs_min2_alloc(
911 m_spline_builder1.batched_spline_domain(batched_interpolation_deriv_domain2),
913 auto spline_derivs_min2 = spline_derivs_min2_alloc.span_view();
914 auto spline_derivs_min2_opt = std::optional(spline_derivs_min2.span_cview());
919 mixed_derivs_min1_min2,
920 mixed_derivs_max1_min2);
922 spline_derivs_min2_opt = std::nullopt;
925 ddc::
Chunk spline_derivs_max2_alloc(
926 m_spline_builder1.batched_spline_domain(batched_interpolation_deriv_domain2),
928 auto spline_derivs_max2 = spline_derivs_max2_alloc.span_view();
929 auto spline_derivs_max2_opt = std::optional(spline_derivs_max2.span_cview());
934 mixed_derivs_min1_max2,
935 mixed_derivs_max1_max2);
937 spline_derivs_max2_opt = std::nullopt;
941 auto const batched_interpolation_deriv_domain3
942 =
ddc::replace_dim_of<interpolation_discrete_dimension_type3, deriv_type3>(
943 batched_interpolation_domain,
945 ddc::DiscreteElement<deriv_type3>(1),
948 ddc::
Chunk spline_derivs_min3_alloc(
949 m_spline_builder1.batched_spline_domain(batched_interpolation_deriv_domain3),
951 auto spline_derivs_min3 = spline_derivs_min3_alloc.span_view();
952 auto spline_derivs_min3_opt = std::optional(spline_derivs_min3.span_cview());
957 mixed_derivs_min1_min3,
958 mixed_derivs_max1_min3);
960 spline_derivs_min3_opt = std::nullopt;
963 ddc::
Chunk spline_derivs_max3_alloc(
964 m_spline_builder1.batched_spline_domain(batched_interpolation_deriv_domain3),
966 auto spline_derivs_max3 = spline_derivs_max3_alloc.span_view();
967 auto spline_derivs_max3_opt = std::optional(spline_derivs_max3.span_cview());
972 mixed_derivs_min1_max3,
973 mixed_derivs_max1_max3);
975 spline_derivs_max3_opt = std::nullopt;
979 auto batched_interpolation_deriv_domain2_3
980 =
ddc::replace_dim_of<interpolation_discrete_dimension_type3, deriv_type3>(
981 batched_interpolation_deriv_domain2,
983 ddc::DiscreteElement<deriv_type3>(1),
986 ddc::
Chunk spline_derivs_min2_min3_alloc(
987 m_spline_builder1.batched_spline_domain(batched_interpolation_deriv_domain2_3),
989 auto spline_derivs_min2_min3 = spline_derivs_min2_min3_alloc.span_view();
990 auto spline_derivs_min2_min3_opt = std::optional(spline_derivs_min2_min3.span_cview());
993 spline_derivs_min2_min3,
994 *mixed_derivs_min2_min3,
995 mixed_derivs_min1_min2_min3,
996 mixed_derivs_max1_min2_min3);
998 spline_derivs_min2_min3_opt = std::nullopt;
1001 ddc::
Chunk spline_derivs_min2_max3_alloc(
1002 m_spline_builder1.batched_spline_domain(batched_interpolation_deriv_domain2_3),
1004 auto spline_derivs_min2_max3 = spline_derivs_min2_max3_alloc.span_view();
1005 auto spline_derivs_min2_max3_opt = std::optional(spline_derivs_min2_max3.span_cview());
1008 spline_derivs_min2_max3,
1009 *mixed_derivs_min2_max3,
1010 mixed_derivs_min1_min2_max3,
1011 mixed_derivs_max1_min2_max3);
1013 spline_derivs_min2_max3_opt = std::nullopt;
1016 ddc::
Chunk spline_derivs_max2_min3_alloc(
1017 m_spline_builder1.batched_spline_domain(batched_interpolation_deriv_domain2_3),
1019 auto spline_derivs_max2_min3 = spline_derivs_max2_min3_alloc.span_view();
1020 auto spline_derivs_max2_min3_opt = std::optional(spline_derivs_max2_min3.span_cview());
1023 spline_derivs_max2_min3,
1024 *mixed_derivs_max2_min3,
1025 mixed_derivs_min1_max2_min3,
1026 mixed_derivs_max1_max2_min3);
1028 spline_derivs_max2_min3_opt = std::nullopt;
1031 ddc::
Chunk spline_derivs_max2_max3_alloc(
1032 m_spline_builder1.batched_spline_domain(batched_interpolation_deriv_domain2_3),
1034 auto spline_derivs_max2_max3 = spline_derivs_max2_max3_alloc.span_view();
1035 auto spline_derivs_max2_max3_opt = std::optional(spline_derivs_max2_max3.span_cview());
1038 spline_derivs_max2_max3,
1039 *mixed_derivs_max2_max3,
1040 mixed_derivs_min1_max2_max3,
1041 mixed_derivs_max1_max2_max3);
1043 spline_derivs_max2_max3_opt = std::nullopt;
1048 m_spline_builder1.batched_spline_domain(batched_interpolation_domain),
1050 ddc::
ChunkSpan const spline1 = spline1_alloc.span_view();
1052 m_spline_builder1(spline1, vals, derivs_min1, derivs_max1);
1054 m_spline_builder_2_3(
1056 spline1.span_cview(),
1057 spline_derivs_min2_opt,
1058 spline_derivs_max2_opt,
1059 spline_derivs_min3_opt,
1060 spline_derivs_max3_opt,
1061 spline_derivs_min2_min3_opt,
1062 spline_derivs_max2_min3_opt,
1063 spline_derivs_min2_max3_opt,
1064 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.