Note that there are some explanatory texts on larger screens.

plurals
  1. POphp array combinatorics/combination analyzes
    primarykey
    data
    text
    <p>i need to discover all possible combinations for some arrays that have an specific char.</p> <p>let me explain.</p> <p>i have this text that have vectors organized as rows:</p> <pre><code>1342;-;+;V;+;-;V;V;V;ND;-;-;ND;ND;+;+;ND;-;ND;ND;ND;-;+;ND;+;-;-;-;ND;-;-;ND;ND;-;ND;ND;F;ND 2343;-;-;-;-;-;-;ND;-;ND;-;-;ND;ND;-;V;ND;V;ND;ND;ND;-;+;ND;-;-;-;V;ND;V;-;ND;ND;-;ND;ND;O;ND 2344;-;-;-;-;-;-;ND;-;ND;-;ND;ND;ND;ND;+;ND;+;ND;ND;ND;-;+;ND;+;-;-;-;ND;V;ND;ND;ND;-;ND;ND;O;ND 2345;-;V;V;+;V;V;ND;-;+;-;-;-;ND;-;V;ND;+;ND;V;ND;-;+;ND;-;-;-;-;V;-;+;ND;ND;-;-;+;F;- </code></pre> <p>each row is an vector..the attributes values are separeted by ";"</p> <ul> <li>all possible values are: numbers, +, -, O, F, ND and 'V'</li> <li>but the char V means + and -</li> </ul> <p>what i need to to is to check for EACH ROW when the vector has in any attibute the char "V" because if have it means that this row must be replicated to all possibilities of V.</p> <p>see this little example:</p> <pre><code>109 ; + ; - ; V ; ND ; + </code></pre> <p>i checked that this row has one or more than one "V" so now will calculate all possibilities that can be generated for this row</p> <h3>as we know V = + and - so this one row will generate:</h3> <pre><code>109 ; + ; - ; + ; ND ; + 109 ; + ; - ; - ; ND ; + </code></pre> <h3>as we have just one V so we will have 2 possibilities... the problem is when there is more than one 'V' .. how to calculate all combinations to it..</h3> <p>when creating the new text with all rows combinations the new text must not contain the origin row with the 'V'. note that all other attributes values remains the same.</p> <p>thank you,</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload