Skip to main content

convex_smawk

Function convex_smawk 

Source
pub(super) fn convex_smawk<T>(arbitrary: &[T], convex: &[T]) -> Vec<T>
where T: Signed,
Examples found in repository?
crates/competitive/src/math/min_plus_convolution/convex.rs (line 270)
259pub fn min_plus_convolution_convex_smawk<T>(a: &[T], b: &[T]) -> Vec<T>
260where
261    T: Signed,
262{
263    let len = output_len(a.len(), b.len());
264    if len == 0 {
265        return Vec::new();
266    }
267    assert_finite(a);
268    assert_finite(b);
269    let (arbitrary, convex) = orient_one_convex(a, b);
270    convex_smawk(arbitrary, convex)
271}