Community Tip - When posting, your subject should be specific and summarize your question. Here are some additional tips on asking a great question. X
Hi All-
I am attempting to model the first-order change of A --> B. The little programming loop below does the transformation of A to B in time steps of n just fine. The problem is I cannot view the A vs time data as is shown in the MathCAD document below.
I know there are many other ways to solve this simple system, but getting this little programming loop to solve the problem is my goal.
Solved! Go to Solution.
@Caleb01 wrote:
Hi All-
I am attempting to model the first-order change of A --> B. The little programming loop below does the transformation of A to B in time steps of n just fine. The problem is I cannot view the A vs time data as is shown in the MathCAD document below.
I know there are many other ways to solve this simple system, but getting this little programming loop to solve the problem is my goal.
Hi Caleb,
The reason your program isn't giving the expected result is that you are storing arrays. You either need to write a function/program to flatten them or store the values more directly. In this case, the latter option is the easier option. Use stack or augment when you want to create flat arrays of values.
I've only got Prime Express, so can't use programming, but I hope the following should help point you in the right direction (the program may even work!).
Cheers,
Stuart
Or you could play around with indexing the variables ... a bit messier.
Cheers,
Stuart
Hi Stuart,
Thanks for your help. You were spot on with the stacking. To say that I don't understand indexing and matrices fully would be an ocean of understatement. Your programing loop works wonderfully. See it in action below. I really do thank you for your insight and gracious response.
Best,
Caleb
How about this approach?
Clean and elegant! This is the result I had envisioned when I first started this little task. I just didn't quite know how to get there. Thank you.