LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

school project help

Solved!
Go to solution

count from 0 to 9
how to count from 0 to 5?

0 Kudos
Message 11 of 34
(1,367 Views)

You just need to put 5 instead of 10 in the first while loop.

🙂

If there is any other question just shoot. 

Regards,

Hossein

0 Kudos
Message 12 of 34
(1,320 Views)

to be attached VI and his Sub VI who can generate a 2D matrix with defined inputs number of rows number of columns and range of random numbers?

0 Kudos
Message 13 of 34
(1,292 Views)

strunf,

 

Are you asking how to do it or are you showing it?

I think you are asking, so I will create an example..

Since you did not mention type, I will assume that it is dbl because of random numbers.

0 Kudos
Message 14 of 34
(1,282 Views)

I ask how to do it

if you can with explanation please

0 Kudos
Message 15 of 34
(1,278 Views)

 

This is a very simple implementation.  A better version would first initialize the array.  But if you are dealing with a relatively small size (eg: 100 X100), then I would not be too concerned with it.

 

The outer For loop takes care of the rows while the inner For loop takes care of the columns.  The range difference is multiplied by the random number and added to the lower range.  This should be obvious..

 

You can drag or copy this snippet directly into your block diagram and it will become code.

0 Kudos
Message 16 of 34
(1,271 Views)

Thanks
if you can make this code to be instead of (for loop) in the (WHILE-LOOP) stops work when you detect the last character in the string

0 Kudos
Message 17 of 34
(1,255 Views)

Can you explain what you are trying to do?  I can make LabVIEW do just about anything, but it is usless if it's not what you want.. 

Are you trying to extract the last character of a string?  If so, you do not need any loop to do that.

 

What are you trying to do?

 

What's up with a,e,i,o,u.  Sounds like "voyelles" in french.  Do you need to count how many times they appear?

0 Kudos
Message 18 of 34
(1,240 Views)

must stand on the last string.
but we need to do all that code to work in the WHILE-LOOP.
the professor is in FOR-LOOP, said to do the same only in the WHILE-LOOP.

0 Kudos
Message 19 of 34
(1,231 Views)

I don't want to give you the answer because I would be doing your homework.  😉

I will give you hints:

 

What causes the decision to stop a While Loop for this example?  What can you use?

0 Kudos
Message 20 of 34
(1,226 Views)