Message Boards Message Boards

0
|
1845 Views
|
2 Replies
|
2 Total Likes
View groups...
Share
Share this post:

[?] Evaluate a function in two variables at a particular point (a,b)?

Posted 5 years ago

I need evaluate a a function in two variables in a particular point, I mean, if f(x,y)=x^2+y^2, and p=(1,1), I want to get f(1,1).

POSTED BY: Kratos Desparta
2 Replies
Posted 5 years ago

If you can get your input into this form then

f[x_,y_]:=x^2+y^2;
p={1,2};
f@@p

should give you

5

You can look up @@ or Apply in the help system to find information about how this works

POSTED BY: Bill Nelson

Thank you, that works

POSTED BY: Kratos Desparta
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract