Origin Ver. and Service Release (Select Help-->About Origin): 9.0 and 9.1
Operating System: Win7
Hi @ all
I am a beginner in programming with Labtalk. My Problem is to use an if/else Statement in "set Column Values". For Example I have Col(B) with 10 Values from 1 to 10. If the value is smaller than 5 (e.g. 4 3 2 1), I want to calculate Col(B)*Col(B).
If the Value is greater than 5, I want to calculate Col(B)*sqrt(Col(B)+1).
Formula: Col(C)= Col(B)*dN
I wrote the script in that way:
if Col(B) < 5
{
dN = Col(B);
}
else
{
dN = sqrt(Col(B)+1);
}
Can Someone explain, what I forgot in this code, please? Maybe the declaration of dN?
Thanks for Helping