Skip to content

pmbasis linearized #41

Open
gilvillard wants to merge 21 commits into
mainfrom
pmbasis_lin
Open

pmbasis linearized #41
gilvillard wants to merge 21 commits into
mainfrom
pmbasis_lin

Conversation

@gilvillard

@gilvillard gilvillard commented May 2, 2026

Copy link
Copy Markdown
Collaborator

New procedure nmod_poly_mat_pmbasis_linearized from nmod_poly_mat_pmbasis by changing the matrix multiplications involved.
Relies on new procedures for linearized matrix product.

Relies on #40 that seems to improve timings in the vast majority of cases.

  • nmod_poly_mat_mul_linearized for a product A(x).B(x), linearizes the columns of B into chunks of length related to the degree of A (to be tuned);
  • nmod_poly_mat_middle_product_linearized, uses nmod_poly_mat_mul_linearized;
  • the product of intermediate bases relies on nmod_poly_mat_mul_geometric;
  • the test for switching to mbasis is now (order <= (ipmat->r)) rather than if (order <= PMBASIS_THRES) (to be tuned).

The following tests give an idea of the range of superiority of nmod_poly_mat_pmbasis_linearized. A comparison is also made with nmod_poly_mat_middle_product_geometric as only modification in nmod_poly_mat_pmbasis.

pmbasis linearized.pdf

Rider: adding a .h that had been forgotten for some of the prototypes in maple.

@gilvillard

Copy link
Copy Markdown
Collaborator Author

See comment close to nmod_poly_mat_shift_right(BT, B, nlo-degA); in middle_product.c, problem over there, certainly (ASan check failed)

@vneiger vneiger mentioned this pull request May 17, 2026
8 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant