Relative Content

Tag Archive for c++loopsoctave

Octave for/while loop to determine all possible variable combinations with a set condition

`Hello, I’m a novice at programming and am currently learning how to do simulations for my paper. I’m currently practicing on Octave. I have 3 variables v1, v2 and v3 equal to 1. So v1 + v2 + v3 = 1. I’m trying to get every possible combination of these three variables with increments of 0.1 via looping. I’m not aware of any advanced commands or tools so I just used the basics of C++ that we’ve been taught in one of our classes.