Discussion Forum

wrong number of function arguments

 Topics: 4.3, Materials and functions
RSS feed   |   Turn on email notifications   |   3 Replies   Last post: October 12, 2012 5:32pm UTC

Kelley Rabjohns

October 10, 2012 6:57pm UTC

wrong number of function arguments

Hello,

I keep getting the same error for my analytical function

"Wrong number of function arguments
Number of arguments expected: 3"

But as far as I can tell, I have defined 3 arguments in my function.. so I don't understand the error!

expression: a_c*pore_V(x,y,z)
Arguments: x, y, z

(a_c = a variable and pore_V(x,y,z) = random fxn)

Does anyone know whats happening?

Thank you!

Kelley

Ivar Kjelberg

October 11, 2012 5:30am UTC in response to Kelley Rabjohns

Re: wrong number of function arguments

Hi

no, not like that, probably you must make a simple model example and post that too (you do not need to give the full model, "just" reproduce the error in a simple new model

--
Good luck
Ivar

Kelley Rabjohns

October 12, 2012 5:07pm UTC in response to Ivar Kjelberg

Re: wrong number of function arguments

Here is a simplified (but very similar) model with the same error. Maybe I am misunderstanding how to define the arguments?

Kelley Rabjohns

October 12, 2012 5:32pm UTC in response to Kelley Rabjohns

Re: wrong number of function arguments

I think I figured out the error... I was trying to use the analytic function in the model in an anisotropic flow field. I was defining the flow field like

f(x) f(y) f(z)

but I think I needed to do

f(x,x,x) f(y,y,y) f(z,z,z)

for there to be 3 arguments in the model. Does that sound correct?
or should it be defined

f(x,y,z) for each flow direction (xx, yy, zz)?

Rules and guidelines