| Login | | Don't have an account yet? You can create one. As a registered user you have some advantages like theme manager, comments configuration and post comments with your name. | |
| Who's Online | There are currently, 43 guest(s) and 1 member(s) that are online.
You are Anonymous user. You can register for free by clicking here | |
 | |
|
Verification Guild: Forums |
|
| View previous topic :: View next topic |
| Author |
Message |
Shail Senior


Joined: Mar 18, 2005 Posts: 44
|
Posted: Wed Apr 11, 2012 3:53 pm Post subject: constraint multiple arrays with interdependency |
|
|
Hi,
I could easily constraint array such that sum of its all elements is between certain range and that each value is still also between certain range etc. etc..
but now actually I have a constraint that involves mutiple dynamic arrays
1) if value occurs in array1 , it has to at last element
2) sum of all elements of array1 should be X "whose corresponding value at same index in array2 is 1"
3) if value at a specific index in array1 is A, value at same index in array3 must be between B and C..
I tried array.method with { item.. } constraints but it only works with one array...
I can do it procedurally, but then I loose the flexibility of constraining it from sequences...
any thoughts/ suggestions ? |
|
| Back to top |
|
 |
Shail Senior


Joined: Mar 18, 2005 Posts: 44
|
Posted: Sun Apr 15, 2012 9:23 pm Post subject: |
|
|
62 views without a reply indicates there is no way in SV to achieve, what I want to do with constraints.
I will find work-around |
|
| Back to top |
|
 |
dave_59 Senior


Joined: Jun 22, 2004 Posts: 974 Location: Fremont, CA
|
Posted: Sun Apr 15, 2012 9:45 pm Post subject: |
|
|
Or it could be that no one understands your question or requirements.
Can you give some examples?
Are some of these arrays just single bits? How are the sizes of the arrays related? If they are all the same size, perhaps you could use an array of structs. |
|
| Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
| |
|
|