I have a problem plotting some data generated in a matrix derived from a nested FOR loop. I seem to have lots of problems with nested loops. The calculation proceedure is calculating fatigue crack growth from an initial crack size (depth = a and length = 2c) when exposed to stress levels applied a number of times in a block (day). The output matrix X looks to have the right data in columns but this does not seem to plot correctly?
Is there a problem with the FOR loop logic/syntax or the way I am calling the data up for the plot?
Any assistance would be appreciated.
You haven't defined j outside of the program that calculates X. You need to set j:=0..last(cycles). However, I can't really test this as you haven't supplied files "cycles.txt", "comp1membrane.txt", "comp1bending.txt".
I am amazed and grateful at your enthusiasm to help out.
I have attached the 3 input files and would appreciate if you can find a problem.
Yep it is! I have used similar syntax previously but there is obviously some subtle problem with this latest effort. One again I am indebted to you for the correction. It is frustratingly simple!
Cheers and have a good day.