diff --git a/Resample/Processed/Slicer.cpp b/Resample/Processed/Slicer.cpp index 5802e9b1e0b03c9f4e5b2b4ade7440b6e46e2fff..d5cf65a21e356dcdd1fb517e54de429227ddd032 100644 --- a/Resample/Processed/Slicer.cpp +++ b/Resample/Processed/Slicer.cpp @@ -46,13 +46,11 @@ IFormFactor* doSlice(const IFormFactor* ff, double dz_bottom, double dz_top) double dradius = dz_bottom * Math::cot(f->alpha()); return new Cone(f->radius() - dradius, f->height() - dz_bottom - dz_top, f->alpha()); } - /* TODO repair if (const auto* f = dynamic_cast<const Pyramid6*>(ff)) { - double dbase_edge = dz_bottom * Math::cot(f->alpha()); + double dbase_edge = 2 / sqrt(3) * dz_bottom * Math::cot(f->alpha()); return new Pyramid6(f->baseEdge() - dbase_edge, f->height() - dz_bottom - dz_top, f->alpha()); } - */ if (const auto* f = dynamic_cast<const Bipyramid4*>(ff)) { if (dz_bottom > f->base_height()) { double dbase_edge = 2 * (dz_bottom - f->base_height()) * Math::cot(f->alpha()); diff --git a/Tests/Py/Functional/auto_slicing.py b/Tests/Py/Functional/auto_slicing.py index 6c09e631f1b52d74cbb0ca4212999cf1af0e0720..e1e5380be0d6f536e6750c8cb7eae0f18717f44f 100644 --- a/Tests/Py/Functional/auto_slicing.py +++ b/Tests/Py/Functional/auto_slicing.py @@ -65,7 +65,7 @@ class SlicedSpheresTest(unittest.TestCase): self.runPlainFF(ba.Prism6(4., 9.)) self.runPlainFF(ba.Pyramid3(8., 10., 80*ba.deg)) self.runPlainFF(ba.Pyramid4(8., 9., 80*ba.deg)) - # self.runPlainFF(ba.Pyramid6(18., 8., 40*ba.deg)) TODO wrong, disabled + self.runPlainFF(ba.Pyramid6(18., 8., 40*ba.deg)) if __name__ == '__main__':