troubleshooting Question

How do I find the index number of a specific entry in a vector? (MATLAB)

Avatar of crossratio
crossratio asked on
Programming Languages-OtherMATLAB Programming
3 Comments1 Solution1297 ViewsLast Modified:
The question I'm working on asks me to find the entry of maximum ration between two vectors v1, v2. I want the actual ratio and the entry number of the vector.

I took v= abs(v1-v2).
Then max(v) gives me what the largest difference is between the entries of these vectors. How do I get it to give me the ratio? Also, how can I ask matlab to tell me the entry number of max(v) in vector v?

Any help would be very appreciated. Thank you in advance.
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 3 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 3 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros