Quantcast
Channel: PTC Community : All Content - Programming & Extending Mathcad
Viewing all articles
Browse latest Browse all 680

returning values in a given "band" from a vector?

$
0
0

To all,

 

Is there a mathcad command to return all the values within a given band/tolerance?

Example

Assume have a vector fv:=[10,11,12..20]

I want to get a new vector containing all the values (from f) within a given band/tolerance of a given value fi

let 's pick a value within the given vector: fv=15

tolerance = 1.5

vector to be returned : fvband:=[14,15,16]

 

with tolerance = 4

vector to be returned : fvband:=[11,12,13,14,15,16,17,18,19]

 

in other words. the new vector should include the values in range: fi-tolerance:fi+tolerance

 

I can think of a way of iterating but to create 'fvband' but was wandering if there is something built-in!

 

Thanks

Regards


Viewing all articles
Browse latest Browse all 680

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>