# Search the Community

Showing results for tags 'numeric'.

• ### Search By Tags

Type tags separated by commas.

### Forums

• Software & Hardware Discussions
• LabVIEW Community Edition
• LabVIEW General
• LabVIEW (By Category)
• Hardware
• Resources
• LabVIEW Getting Started
• GCentral
• Code Repository (Certified)
• LAVA Code on LabVIEW Tools Network
• Code In-Development
• OpenG
• Community
• LAVA Lounge
• LabVIEW Feedback for NI
• LabVIEW Ecosystem
• LAVA Site Related
• Site Feedback & Support
• Wiki Help

### Categories

• *Uncertified*
• LabVIEW Tools Network Certified
• LabVIEW API
• VI Scripting
• JKI Right-Click Framework Plugins
• Quick Drop Plugins
• XNodes
• General
• User Interface
• X-Controls
• LabVIEW IDE
• Custom Probes
• LabVIEW OOP
• Database & File IO
• Machine Vision & Imaging
• Remote Control, Monitoring and the Internet
• Hardware

• 0 Replies

• 0 Reviews

• 0 Views

Found 4 results

1. ## Floating Point Steps

So I have a serious question. Does LabVIEW have a way (built in or library) of calculating the next larger or next smaller floating point value. C standard library "math.h" has two functions: nextafter, and nexttowards. I have put together a c function: that seems to do the trick nicely for single floats (well only for stepup): #include <math.h> #include <stdint.h> uint32_t nextUpFloat(uint32_t v){ uint32_t sign; = v&0x80000000; if (v==0x80000000||v==0){ //For zero and neg zero return 1; } if ((v>=0x7F800000 && v<0x80000000)||(v>0xff800000)){ //Check for Inf and NAN return v; //no higher value in these cases. } sign = v&0x80000000; //Get sign bit v&=0x7FFFFFFF; //strip sign bit if(sign==0){ v++; }else{ v--; } v=v|sign; //re merge sign return v; } I could put this in labVIEW, but these things are tricky and there are some unexpected cases. So its always better to use a reference.
2. ## Prevent numeric increment/decrement buttons from incrementing by 10, 100...

When the cursor in the numeric field of a numeric control is for example after the 10s/100s digit, the increment/decrement buttons have a step of 10/100. How can I prevent that? I always want a step of 1. I tried setting the Data Entry Increment property to 1 but that did not change this behaviour..
3. ## release OpenG Numeric Library 4.1.0.8 Release

This package will be available for download through VIPM in a few days and covers some new VIs. [MOD] 3419758 - Create new Random Number Within Range - I32 VI [NEW] 3422921 - Add Timestamp Constant Kind regards Jonathon Green OpenG Manager I would also like to thank Ed Dickens for reviewing this package for release.
4. ## closed review Random Number - Integer (Numeric Package)

This OpenG Review is closed. Based on Jim's suggestion in my post Select Random Array Indices, I submit this VI: 'Random Int Number - Within range'. The existing OpenG Random Number VI would presumably be renamed and added to a polymorphic VI. I chose I32 data types for compatibility with array indexing functions. The default values of one and zero allow this to be used with 'Not Equal to Zero?' to simulate a coin toss. Discuss. Random Int Number - Within Range__ogtk.vi UPDATE: I was going to provide a link to the existing OpenG 'Random Number' documentation. A Google search found that Jim already submitted something similar to the old OpenG forums, see here. Jim mentions that the high and low are negatively biased and solves this by adding one to the high value and then rounding down. I think his is better. Rather than duplicate Jim's post and test code, is there a way we can import the discussion from the OpenG board to the LAVA board?
×