jinsuk Lee wrote:
Thank you for advice.
But I am sorry because I don't understand well.
So, Could you explain easily?
Not sure how and what exactly.
1) I don't see the "division by zero error" you are talking about
2) The first error you showed is because you used g1(mu) where you should probably have used g1(a, mu) as I had highlighted in yellow.
3) I predicted further errors because at first you define a function c(mu) but later you overwrite that function by a tabled vector c.
4) I was confused when I looked at your routine for a.r because you used something like "if mu <-- 0.05,0.1..0.3". After "if" there should always be a condintional expression, something which returns either true or false. In Mathcad false is equal to zero and everything different from zero is interpreted as true.
Hope this helps!