- #1
bakin
- 58
- 0
Hello. I have to do a beam project in MATLAB. Similar to this: (I just google imaged this)
http://teaching.ust.hk/~mech101/images/4_poin22.gif
Just a simple beam with one or more applied loads.
What I'm trying to do, is ask the user how many total loads are being applied to the beam. Once I have this answer, I want to have the user enter how much the load is, and what the position is. But, my problem is that once I have a number for how many loads there are, I don't know how to have that many questions asked. For example, if there are two loads, how do I get it to ask the user two times? Or if there are 4 loads, ask them for 4 separate values? I'm thinking it might be a for loop, or some type of loop depending on the number inputted.
Thanks!
http://teaching.ust.hk/~mech101/images/4_poin22.gif
Just a simple beam with one or more applied loads.
What I'm trying to do, is ask the user how many total loads are being applied to the beam. Once I have this answer, I want to have the user enter how much the load is, and what the position is. But, my problem is that once I have a number for how many loads there are, I don't know how to have that many questions asked. For example, if there are two loads, how do I get it to ask the user two times? Or if there are 4 loads, ask them for 4 separate values? I'm thinking it might be a for loop, or some type of loop depending on the number inputted.
Thanks!
Last edited by a moderator: