algebramix_doc 0.3
polynomial_quo_rem_helper< V, C > Struct Template Reference

#include <polynomial_unrolled.hpp>

List of all members.

Public Types

Static Public Member Functions


Detailed Description

template<typename V, typename C>
struct mmx::polynomial_quo_rem_helper< V, C >

Definition at line 139 of file polynomial_unrolled.hpp.


Member Typedef Documentation

typedef implementation<vector_linear,V> Vec

Definition at line 140 of file polynomial_unrolled.hpp.


Member Function Documentation

static void op ( C dest,
C s1,
const C s2,
nat  n1,
nat  n2 
) [inline, static]

Definition at line 143 of file polynomial_unrolled.hpp.

References mmx::C, and mmx::quo().

                                                   {
    // (s1, n1) contains the numerator on input and the remainder on output
    // (s2, n2) contains the denominator. We assume n2>0 and s2[n2-1] != 0
    // (dest, n1-n2+1) contains the quotient
    while (n1 >= n2 && n1 != 0) {
      int d= n1-n2;
      C q= quo (s1[n1-1], s2[n2-1]);
      dest[d]= q;
      Vec::template vec_binary_scalar<mul_add_op,C,C,C> (s1 + d, s2, -q, n2);
      n1--;
    }
  }

The documentation for this struct was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Friends Defines