COMPGROUPS.NET | Search | Post Question | Groups | Stream | About | Register

Minimax problem for matrices

• Email
• Follow

```Hi there

I'm facing a problem for which I haven't yet found an answer. Hopefully gathering all the expertise of the forum I'll be able to move forward!

The problem is as follows, I have two matrix that respectively represent two functions. Actually they are hipermatrix since they have three dimensions. What I want to do is calculate the matrix indexes in which the maximum is located but constrained to a condition in the other matrix. In other words, if the maximum for matrix A is in i,j,k position  it should be discarded as a maximum if the element in position i,j,k of matrix B doesn't fulfill a certain condition (i.e that element has to be higher than 1).

Any help will be appreciated

Thanks
Antonio
```
 0

See related articles to this posting

```"Pandora lafuente" <anlafuente@gmail.com> wrote in message <hq8lv4\$hek\$1@fred.mathworks.com>...
> Hi there
>
> I'm facing a problem for which I haven't yet found an answer. Hopefully gathering all the expertise of the forum I'll be able to move forward!
>
> The problem is as follows, I have two matrix that respectively represent two functions. Actually they are hipermatrix since they have three dimensions. What I want to do is calculate the matrix indexes in which the maximum is located but constrained to a condition in the other matrix. In other words, if the maximum for matrix A is in i,j,k position  it should be discarded as a maximum if the element in position i,j,k of matrix B doesn't fulfill a certain condition (i.e that element has to be higher than 1).
>
> Any help will be appreciated
>
> Thanks
> Antonio

p = find(B>1);
[t,q] = max(A(p));
[i,j,k] = ind2sub(size(A),p(q));

Roger Stafford
```
 0

1 Replies
458 Views

Similar Articles

12/11/2013 4:02:57 PM
page loaded in 2560 ms. (0)

Similar Artilces:

Memory problems with large sparse matrices
Hi again, I'm using some quite large sparse matrices while solving network/graph problems with MatlabBGL algorithms ( http://www.mathworks.com/matlabcentral/fileexchange/10922-matlabbgl ). My system is 32-bit Windows Vista with 4GB of physical ram (I know the restrictions of 32-bit OS and I have managed to override the default 2GB maximum memory allocation for a single program). Currently memory function gives maximum possible array 1325MB and memory for all arrays 2516MB Is it possible to make and operate bigger matrices than the memory -functions maximum possible array implies? ...

overwrite problem while storing data in 3D matrice
Hello, I am having trouble storing data(from a 2D array, called 'Data', of size 34305x5) into a 3D array. Data has the columns heading being as follows Days ship(number) X-coordinate Y-coordinate height There are a total of 569 different ships, whose height value has been recorded at different X and Y location, and at different time period(i.e different days). So for a given set of coordinates (x,y and time) I want to store the height value for a particular ship, at the concerned sets of coordinates within a 3D_array. The 3D_array(X, Y, Time) The array "Data&quo...

optimization problem over the space of the doubly stochastic matrices
Dear all, Are there any special solver/techniques that work for optimization problems over the space of doubly stochastic matrices? Thanks! In article <e7581758-1808-41ab-8abb-ec398d6551c1@d21g2000prf.googlegroups.com>, citi <loseminds2008@gmail.com> wrote: > Dear all, > > Are there any special solver/techniques that work for optimization > problems over the space of doubly stochastic matrices? I don't know. The (n-by-n) doubly stochastic matrices are the convex hull of the (n-by-n) permutation matrices, but you probably knew that. -- Gerry Myerson (ger...

db problem BIG PROBLEM
We are having a problem on our database, DB2 running on 0s/400 v5r1 and SAP 4.6b. We have a database table on Sap that isn't aligned with the table on the db, this was caused by a breakdown during a transportation. At this moment the table on Sap have one field more than the fields list that we see into db2 from as400. Someone can help us? thanks to all alberto How about running an ALTER TABLE and adding the missing field to the DB2 file? Sam "Alberto" <albe.net@caleffi.it> wrote in message news:1160089901.442664.271060@k70g2000cwa.googlegroups.com... > We are h...

Re: How many files can you have in a VMS directory without performance problems? performance problems? performance problems?
Jeff Cameron <roktsci@comcast.net> wrote on 08/17/2005 09:10:04 AM: > On 8/17/05 3:46 AM, in article > 1124275575.684487.287580@z14g2000cwz.googlegroups.com, "RAQ" > <_raq_@yahoo.com> wrote: > > > Hi > > > > Everytime I ask HP about > > "How many files can you have in a VMS directory without performance > > problems?" > > > > they send me an article that is about 10-15 years old for VMS 5.2 or > > even 1.0, that describes that more than 300 files in a catalog is > > bad... > > > > I...

Printing problem.. Is it my problem or the comercial printer?
Hello, I hope you guys can help me. I recently made an ad in adobe illustrator which has a greyscale image with an orange to transparent gradient on top made by creating an opacity mask. Well on the screen it looks fine and so I sent it to the comercial printer. However when the comercial printer gave us the proof it shows a sort of lighter hue band in the area where the orange gradient ends and meets with the grey image below. In other words, instead of the gradient blending smoothly with the grey image below (as it shows on screen!) there is like a lighter strip that just almost ends abroup...

JDBC to NonStop problems (problems with MXCS)
Anyone having problems using JDBC connecting to a NonStop server? We went live with this a few weeks ago and it has been nothing but trouble. I started with a single MXCS process with default parameters. Nothing exciting. Things went well for about a week, so I set up 5 MXCS processes on different TCP/IP processes on different adapters on another host. Now things are going terribly wrong. We are running out of memory, DP2 is starving and now I am getting assertion errors. It is to the point where I have to shoot individual process (when I can identify them) or recycle the entire subsyst...

Problem...
Hi all, I have a problem with my OGL application.... I realized a 3DLaser Sensor simulator: in a windows I put a point (glVertex)for every misure made by sensor... when I realize the 9434th misure and display the 9434th point I get an error: "A requested resource was not available". I think there is a limit in vertex number in OpenGL, is that True? Is there a way to jump over the problem? Any subjestion will be really appreciated Thank you in advance Walter Myzhar wrote: > Hi all, > I have a problem with my OGL application.... > I realized a 3DLaser Sensor simulator: ...

I have a problem
Hi, I have a problem and I`ll be really appreciated if you can solve it. My project is to read 2 Jpeg files (hand writings) and compare them by using correlation coefficient. I found out how to read a jpeg file and also I found out that I need to convert my images to arrays to wire them to correlation block But I couldn`t find how to convert them to arrays. Thank you so much best regards Parto Yazdani On May 20, 11:54=A0am, parto.yazd...@gmail.com wrote: > I found out how to read a jpeg file and also I found out that I need > to convert my images to arrays to wire them to co...

Terminal services problem and temp license problem
Hello I am having a problem with a user accessing W2K Terminal Server who has a temporary license that is about to expire. He uses RDC to access our Terminal Server from his Macintosh PowerBook. There are several problems that I have run into and I hope you can help me with them. A) The Terminal Server licensing was installed on our Primary Domain Controller and not the Terminal Server. When I open it I can see that he and four other computers have Temporary licenses and that the Licensing for terminal services is unlimited (Per Device). Also the temp license is assigned to him whereas the oth...

Problem....
I was member of one php forum...(i even paid 1/4 for webspace and domene for that site)..someone took my passward..and logged on my name wrote something stupid and offensiv to some other members... Now my acc is blocked.....I just wonder..is there anyway i can get into this site and delete all my posts and to delete my account?... Site is about pets..since im in many different organisations about lost and homeless pets..i dont have urge to destroy all forum and site...just my own account... or you can help me where i can find explenation how to do it?... Thanks... It would be differ...

Plasmon 6100 SCSI problems/solutions/more problems
Layout: -AHA2944 controller (latest drivers) -Win XP (updated) -AMD 64 CPU -Plasmon 6100 Optical drive (SCSI) -3GB memory -Both IDE and SATA (RAID0) drives -same effect on either -Updated Firmware -Problem: After offloading two 12GB platters, from the Plasmon 6100, I will get an error message while offloading the 3rd platter. "Error writing .TFF" (Most of the data offloaded are TFF's). When I reboot, in order to reset the SCSI drivers, the system goes into CHKDSK. I was getting many errors before I cooled the system down via liquid cool - which did wonders for the performance. B...

Table cell renderer problem
I have a table which uses a custom TableCellRender. In the code below, TColumn stores some configuration information about a given column. if it's renderComponentType member is not equal to "LABEL", it will return a custom component i created. That component is called "IconLabel" and it is simply a panel with two labels, one for an IconImage and the other for displaying the text. In this case, my table consists of only one column out of 7 that uses IconLabel. Further, when ever a cell is clicked, i disabled SelectionAllowed on the table and instead, i "outline&q...

Where is the problem?
I have just upgraded to the new ROM, installed hpgcc on a new laptop and updated a C program I had. When I try to run it I get Error: Not an ARM program. I compiled the hiworld example and still get the same error. Programs that were on my calculator before the ROM upgrade run fine. Any idea what is going on? Otherwise I will have to go through all the variables one by one :-( Thanks, Arnaud hello I have got the same problem you must have the good version of launcher go to gregory.thomas.free.fr/hpgcc.html and download arm toolbox bye Thanks a lot, I had my suspicions about the A...

problem with timing simulation (clear explanation of problem)
Hi all, to be more clear about my problem with timing simulation after i implement it using xilinx it is creating one TIME_SIM.VHD and TIME_SIM.SDF file under the folder "timing" it has an identifier "X_INV_PP" in both files when i compile TIME_SIM.VHD it is giving an error "Unknown identifier "X_INV_PP"" Cannot find component declaration did anyone come across similar kind of problem.please help me out thanks, Regards Ramakrishna you need to compile the simmprim vhdl library first. in your \$XILINX directory under /vhdl/src/simprims (replace \$XILIN...

problem again
Hey.. I made a starting set-up for my form dat sets my controls RECORD, EDIT, UPDATE into enabled NO.. then when i close the whole database and try to open it again.. the set-up is now different.. and it happens too in my other field names... HOw can i solve this? -- Message posted via http://www.accessmonster.com "hugz via AccessMonster.com" <u33625@uwe> wrote > Hey.. I made a starting set-up for my form > dat sets my controls RECORD, EDIT, > UPDATE into enabled NO.. then when i close > the whole database and try to open it again.. > the set-up is...

for problem...
hello, why this loop does not go to k=1 ? set pas 0.01 for {set k 0} {\$k<=1} {set k [expr {\$k+\$pas}]} { puts \$k } but if i take pas=0.1 then it works ! sorry for this (a priori) so simple question... -- cordialement david cobac Les Cargill <lcargill@worldnet.att.net> a �crit : > >Try adding this at the end: > >puts [format "%20.18lf" \$k] > > >-- >Les Cargill so the only sure way for using the for loop is using integers ? -- cordialement david cobac David Cobac <david.cobac@free.fr> a �crit : >Les Cargill <lc...

Sendmail domain problem and unknown user problem
Hi, I am trying to use sendmail on a Sun Solaris 8 platform, to send email over the internet. The mail goes from my Unix box via sendmail to a company mailserver. The company mailserver will not deliver the email because it has the machine name as part of the domain name. They will only deliver mail with the domain of mycompany.com and sendmail is sending mymachine.mycompany.com. I tried setting the Dj setting to Djmycompany.com, but then I get "unknown user" errors. Is the Dj setting the way to get passed the restriction and if it is, how do I fix the "unknown user" prob...

Norton Speed Disk problems recently, after years of *no* problems
What in the holy heck gives with Symantec Corp lately, they could not have done a better job of sabotoging the Mac platform if they tried! Did Bill Gates buy them out? Recently, trusting the latest incarnation of Norton's Speed Disk, (big-mistake) - I set up a 4.00 GB partition for a stripped-down Panther OS 10.3.2 install, about 1.6 GBs of files. As usual with a fresh Panther install, the files were scattered all over the relatively small 4.00 GB partition. In the past, Norton Speed Disk had no problem whipping such a partition into shape. In the past, Speed Disk has _never_ bit m...

Solaris 9, Internet access problem, DNS problem?
Hello, I just finished the installation of Solaris 9 on Sun Enterprise 450 server. I can not access the website by address, but I can ping the IP of internal and expternal IP addresses. During the installation in one of the screens it asked to choose one of the option NIS, NIS+, DNS, LDAP, None. I may have chosen the option 'NONE'. do you think this is the problem? How can I correct the problem? Please see my other post for the config details. http://groups-beta.google.com/group/comp.unix.solaris/browse_thread/thread/c9f937182b28bbf2/d25659701832b2ea#d25659701832b2ea Ok, I...