4 views

Skip to first unread message

Sep 6, 2018, 1:55:43 PM9/6/18

to linbox-use

Hello,

How do I find the minimal polynomial of a compose? If I call the function in the same way as a sparse matrix I get the no matching function call error.

Thanks,

-Tom

Sep 6, 2018, 5:19:04 PM9/6/18

to linbo...@googlegroups.com

I guess more detail would be needed to see what the problem is. I made the attached diff to examples/minpoly.C and it worked fine.

--

You received this message because you are subscribed to the Google Groups "linbox-use" group.

To unsubscribe from this group and stop receiving emails from it, send an email to linbox-use+unsubscribe@googlegroups.com.

To post to this group, send email to linbo...@googlegroups.com.

Visit this group at https://groups.google.com/group/linbox-use.

For more options, visit https://groups.google.com/d/optout.

Sep 7, 2018, 9:00:45 AM9/7/18

to linbox-use

Hi Dr. Saunders,

Specifically,

//init matrix

DenseVector<Givaro::ZRing<Integer> > m_A(ZZ);

minpoly (m_A, SparseMatrix, Method::Blackbox());

minpoly (m_A, SparseMatrix, Method::Blackbox());

works no problem, but

//init matrices, create compose of two sparse matrices

DenseVector<Givaro::ZRing<Integer> > m_A(ZZ);

minpoly (m_A, Compose, Method::Blackbox());

minpoly (m_A, Compose, Method::Blackbox());

runs into a compile error of no matching function call.

On Thursday, September 6, 2018 at 5:19:04 PM UTC-4, B Saunders wrote:

I guess more detail would be needed to see what the problem is. I made the attached diff to examples/minpoly.C and it worked fine.

On Thu, Sep 6, 2018 at 1:55 PM, tom murtha <tom.mu...@gmail.com> wrote:

Hello,How do I find the minimal polynomial of a compose? If I call the function in the same way as a sparse matrix I get the no matching function call error.Thanks,-Tom

--

You received this message because you are subscribed to the Google Groups "linbox-use" group.

To unsubscribe from this group and stop receiving emails from it, send an email to linbox-use+...@googlegroups.com.

Sep 7, 2018, 9:12:16 AM9/7/18

to linbo...@googlegroups.com

OK. That should work. I'll look into it. Meanwhile, I think you'll find it works if the Method::Blackbox() argument is left out (and you will get the blackbox method anyway).

To unsubscribe from this group and stop receiving emails from it, send an email to linbox-use+unsubscribe@googlegroups.com.

Sep 7, 2018, 10:12:28 AM9/7/18

to linbox-use

Thanks. As an extra point, it gives the same error with a compose of a compose and a sparse matrix. Is there a method to convert a compose back into a sparse matrix to help keep things cleaner?

Sep 7, 2018, 12:15:12 PM9/7/18

to linbo...@googlegroups.com

Generally, one doesn't want to represent a product of sparse matrices as a sparse matrix. The blackbox algorithm cost is a function of the cost of applying the matrix to a vector. Suppose you have sparse matrices A and B with a and b nonzeroes respectively. The cost of matrix vector product, of A(Bx), is proportional to a + b. The product of A and B represented as a sparse matrix will usually have many more than a+b nonzeroes.

That said, the mechanisms in linbox for combining blackbox matrices (product(compose), sum, direct sum, side by side, etc.) are unwieldy. For instance Compose<T1,T2> is a distinct type of object for every T1 and T2 and distinct copies of each function such as apply (matrix vector product) are made (code bloat). This is unnecessary and changes are afoot to simplify and strengthen the "blackbox calculus". A start in this direction is to be found in bb.h, fibb.h, fibb-product.h. A compose.h compatible with bb.h is on my todo list.

To unsubscribe from this group and stop receiving emails from it, send an email to linbox-use+unsubscribe@googlegroups.com.

Sep 7, 2018, 12:36:10 PM9/7/18

to linbo...@googlegroups.com

Tom, looking back on your original problem, I realize you have an integer matrix, while my check of things was for matrix over a finite field. Sorry for that. The examples/minpoly.C illustrates both, and by absorbing some commented out code, I made the integer part work on a compose of two sparse matrices with explicit Method::Blackbox. The patch is attached.

So now I am again in the position of not being able to guess the problem.

Reply all

Reply to author

Forward

0 new messages

Search

Clear search

Close search

Google apps

Main menu