Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
arithmetic operations count

Subject: arithmetic operations count

From: John Gar

Date: 19 Aug, 2010 07:52:06

Message: 1 of 3

Hi all,

I have a matlab code with a lot of matrix, vector and scalar multiplications and additions. I would like to count the number of arithmetic operations.

Since I don't want to count them manually, anyone have any hints of how count?
Maybe there's some function or wathever else?..

John

Subject: arithmetic operations count

From: Stefan

Date: 19 Aug, 2010 09:41:09

Message: 2 of 3

With some restrictions you could use this:

http://icl.cs.utk.edu/papi/

On this page:

http://icl.cs.utk.edu/papi/custom/index.html?lid=51&slid=69

search for

PAPI 3.0 beta 3 for Matlab on Windows (June 6, 2004)

Regards,
Stefan


"John Gar" <jonathangarzon@gmail.com> wrote in message <i4inr6$7os$1@fred.mathworks.com>...
> Hi all,
>
> I have a matlab code with a lot of matrix, vector and scalar multiplications and additions. I would like to count the number of arithmetic operations.
>
> Since I don't want to count them manually, anyone have any hints of how count?
> Maybe there's some function or wathever else?..
>
> John

Subject: arithmetic operations count

From: Steven_Lord

Date: 19 Aug, 2010 13:42:19

Message: 3 of 3



"John Gar" <jonathangarzon@gmail.com> wrote in message
news:i4inr6$7os$1@fred.mathworks.com...
> Hi all,
>
> I have a matlab code with a lot of matrix, vector and scalar
> multiplications and additions. I would like to count the number of
> arithmetic operations.

Why? What would you do with this information if you had an easy way to
obtain it?

Since you mentioned you wanted to know about matrix multiplications, you
should probably read the last few paragraphs of this Cleve's Corner article:

http://www.mathworks.com/company/newsletters/news_notes/clevescorner/winter2000.cleve.html

--
Steve Lord
slord@mathworks.com
comp.soft-sys.matlab (CSSM) FAQ: http://matlabwiki.mathworks.com/MATLAB_FAQ
To contact Technical Support use the Contact Us link on
http://www.mathworks.com

Tags for this Thread

No tags are associated with this thread.

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us