LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Comparison of Collections

Booleans for RavensFanBooleans for RavensFan

Just for you 😉 But I also wasn't sure when I switched from block diagram to front panel and saw a bunch of blue dots what the significance was...

 


wiebe@CARYA wrote:

So it seems there is a difference between a virgin set and a 'used but empty' set?

Once used, everything works as expected (except when comparing it to a virgin set)?


Yes, that would be my conclusion.

 


wiebe@CARYA wrote:

Is there a difference between an empty set constant and an empty set control?


Control vs ConstantControl vs Constant

Seems like not.

 


wiebe@CARYA wrote:

I wander if a "Always Copy" after the constant takes the sets virginity. Maybe even a structure tunnel (put it in a sequence structure)? Of course (though you never know until you try) removing any item from the virgin set will spoil it?


Example_VI.png

Also seems like this isn't a problem/cause.


GCentral
Message 11 of 22
(1,893 Views)

wiebe@CARYA wrote:

I wander if a "Always Copy" after the constant takes the sets virginity. Maybe even a structure tunnel (put it in a sequence structure)? Of course (though you never know until you try) removing any item from the virgin set will spoil it?


Neither of those worked when I just now tried.



There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 12 of 22
(1,887 Views)

@crossrulz wrote:

wiebe@CARYA wrote:

I wander if a "Always Copy" after the constant takes the sets virginity. Maybe even a structure tunnel (put it in a sequence structure)? Of course (though you never know until you try) removing any item from the virgin set will spoil it?


Neither of those worked when I just now tried.


Do you mean you saw the same as I did, or the opposite?

To clarify, in my case the Always Copy and the Structure (FSS) made no difference at all.


GCentral
0 Kudos
Message 13 of 22
(1,883 Views)

@cbutcher wrote:

Booleans for RavensFanBooleans for RavensFan

Just for you 😉 But I also wasn't sure when I switched from block diagram to front panel and saw a bunch of blue dots what the significance was...

 


Thanks.  Actually, Silver is one that I don't like because the False visual has just enough brightness to the top of it that it doesn't look particularly off without seeing it in comparison to the True.

 

Now I realized your blue ones weren't silver but NXG, which I had never seen before.  But I still don't like them because the blue vs. white isn't as intuitive as on vs. off.  And the blue is rather dull and feels like it is a shade that would be in between an "on" blue vs. an "off" blue.  (not having seen that off is white in comparison.)

0 Kudos
Message 14 of 22
(1,872 Views)

@RavensFan wrote:

Now I realized your blue ones weren't silver but NXG, which I had never seen before.  But I still don't like them because the blue vs. white isn't as intuitive as on vs. off.  And the blue is rather dull and feels like it is a shade that would be in between an "on" blue vs. an "off" blue.  (not having seen that off is white in comparison.)


That could be age... I hate the Android Booleans. Left is on, right is off? Or vice versa? Who knows? Who comes up with this crap? What was wrong with a tag in a box?

 

Reminds me of the way non-programmers (or non-technical people?) tell someone how to tighten a screw. "Turn to the right". Sure, but turn the top or the bottom to the right. (Of course you can tell someone to turn clockwise, which would be clear).

 

We're getting OT (again)...

0 Kudos
Message 15 of 22
(1,866 Views)

It is a bit off topic, but I'm not a fan of most of the slide controls in LabVIEW.

Even with boolean text, I was never completely confident on the on/off positions. "Does that mean it is off, or that if I click it, it will turn off?" etc.

(answer for future readers, boolean text by default gives the current value - although nothing except decency stops you from switching that and confusing the hell out of users...)

 

To get back to the comparisons on sets and maps, I'm wondering if the special-ness of the originally empty "virgin" set is somehow related to my recent problems on cRIO, and Andre's recent similar problems.

Anyone want to blindly postulate ideas on that/those topics? 🙂


GCentral
0 Kudos
Message 16 of 22
(1,859 Views)

@cbutcher wrote:

@crossrulz wrote:

wiebe@CARYA wrote:

I wander if a "Always Copy" after the constant takes the sets virginity. Maybe even a structure tunnel (put it in a sequence structure)? Of course (though you never know until you try) removing any item from the virgin set will spoil it?


Neither of those worked when I just now tried.


Do you mean you saw the same as I did, or the opposite?

To clarify, in my case the Always Copy and the Structure (FSS) made no difference at all.


I tried them with your original snippet and it did not change the results.



There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
Message 17 of 22
(1,857 Views)

I'm seeing this same behavior (two identical sets not being equal), with one weird caveat. A force recompile (or any change that naturally causes a recompile) will suddenly make the equality true. Save and close the VI, then re-load it, and it's once again "broken."

 

Compounding things, this manifests in one particular project. If I put my VI to a different project, it no longer reproduces in that context. Closing that context and opening it in the first, will then revert to the "incorrect" behavior.

 

I have compiled code separated, but for some reason this exact behavior will reproduce on multiple machines given the same set of VIs which seems very odd.

--------------------------------------
0 Kudos
Message 18 of 22
(1,655 Views)

I've kinda sorta figured it this way....sets and collections are like bookshelves.   Just because you put copies of the exact same books on two different bookshelves does nothing to make bookshelf A bookshelf B.  The contents can be used to make some comparisons but they are still different collections that can have different things done to them without affecting the other collection. 

 

By extension then a collection is the same collection and equal to itself even though it might have had something done to its contents i.e. bookshelf A is still bookshelf A even if I add a book to it. And of course any potential bookshelf (empty set) is equivalent until I do something to it even adding books and then taking them all off means that this is now Mybookshelf I am using not just any potential bookshelf.

 

Of course,  I could be very wrong. 


"Should be" isn't "Is" -Jay
0 Kudos
Message 19 of 22
(1,643 Views)

@JÞB wrote:

I've kinda sorta figured it this way....sets and collections are like bookshelves.   Just because you put copies of the exact same books on two different bookshelves does nothing to make bookshelf A bookshelf B.  The contents can be used to make some comparisons but they are still different collections that can have different things done to them without affecting the other collection. 

 

By extension then a collection is the same collection and equal to itself even though it might have had something done to its contents i.e. bookshelf A is still bookshelf A even if I add a book to it. And of course any potential bookshelf (empty set) is equivalent until I do something to it even adding books and then taking them all off means that this is now Mybookshelf I am using not just any potential bookshelf.

 

Of course,  I could be very wrong. 


I could accept that... it's the fact it behaves differently after a recompile that really bothers me.

--------------------------------------
0 Kudos
Message 20 of 22
(1,627 Views)