Defining a new kinetic model for the electrochemical hydrogen oxidation (MultiReactionMcfc class)


#34

i forgot last semicolon after last equation, i’ve corrected it, but the errors are the same anyway


#35

Rcat is made of two terms (p3… and p5…) I suggest you break it up further as in:

Value Rcat1 = p3... ...;
Value Rcat2 = p5... ...;
Value Rcat = Rcat1 + Rcat2;
Rarea = Rohm + Rcat + Ran;

This should help in isolating the error.


#37

i’ve also separated the line , now seems to be in 124


#38

Rcat1 can be further broken down in numerator (p3 …) and denominator (p…):

Value num = p3... ...;
Value deb = p... ...;
Value Rcat1 = num / den;

try that !


#41

if i removed parenthesis the errors is only in 125 line, but i think it’s correct to left them


#42

There is an excess of parentheses, for example this:

could be:

Value num = p3*T*exp(p4/Teq);

try simplifying things until the matter gets clearer


#43

now it told me that i’ve just 4 errors, better than before , i try topical the cursor in the parenthesis to correct them and it seems ok,
but now there’s a problem with pow!
and the problems of parenthesis is moved to line 128


#44

if i remove parenthesis i have just this, but 17 errors


#45

from your last screenshot:


#46

Yes, but in the previous screenshot I put the parenthesis in the correct way, but I have 4 errors anyway


#47

As you see in the previuos screen, not the last one, parentheses matched


#48

in the screenshot before the last one the first error on line 124 is about the pow function, and it is complaining because the function is called with just one argument.

pow should be called with 2 args, one is the mantissa the other is the exponent

try expanding the line 124 as in:

Value man = ... ...;
Value expo(-1);
den = P1*log(pow(man, expo));

#55

it’s done