Community Tip - You can subscribe to a forum, label or individual post and receive email notifications when someone posts a new topic or reply. Learn more! X
Hi
I want to create a loop that for the next interval add the results in the previous interval etc. I have made an attempt in the following program, but something is wrong. Any help is appreciated.
Solved! Go to Solution.
Maybe this is what you are looking for:
Because a "return" statement stops a program from running any further, you can also write
Prime 9 file attached
Not really, I want the diagram to look like this (Excel).
f(0) = 0
f(4,5) = 0 + 4,5x9 = 40,5
f(8,3) = f(4,5) + (8,3 - 4,5) x 7 = 67,1
f(11,3) = f(8,3) + (11,3 - 8,3) x 8 = 91,1 etc...
Hopefully you understand what I'm looking for 🙂
You are demanding now something different compared to your initial posting.
There your wrote " that for the next interval add the results in the previous interval etc." (and your function attempt also showed additios) and now you obviously want to subtract somehow?
In your program you wrote b <-- gamma2*z + a and NOT b <-- gamma2*(z - 4.5 m) + a
Maybe you can get more clear about what you actually need!
So far I guess that this could be what you are looking for:
Or you may use a more generic approach
Thank you, that's what I was looking for! 🙂
Very nice, I like that generic approach! That will be useful for me in the future, thank you!
I have a further query associated to that. The above example describes the vertical stress of a porous material saturated in water. It is common that a part of the material in above water and the other part of the material is submerged in water. Let's assume that the depth to water d=1 m and the weight above that level is 16 kN/m3 (for example). Below that water level (1 m) the conditions are as previously stated. How can I incoorporate that into your generic approach?
Thank you!
I am not sure if I fully understand your new question.
Doesn't it just mean that you have to add 16 on top of the "gamma" vector and -1 on top of the "limits" vector?
Nevermind, I found a way to solve it 🙂
Or, if you're using Express and can't program
Werner's formula is precise and well done!
But this is really a simple integration, Attached Prime 4 Express.
(Extension to the second problem, above the water) will require definition of sign conventions.
But this is really a simple integration,
😉 Its only simple once you found a way to automatically choose the correct gamma-value for every depth, like you did with