0
|
3002 Views
|
5 Replies
|
5 Total Likes
View groups...
Share
GROUPS:

# Limit of a f(x,y) function

Posted 9 years ago
 Hi, Firstly: Why doesn't this work: In:= f[x_, y_] = (1/(4*Pi))*Log[(x - 20)^2 + y^2] Out= Log[(-20 + x)^2]/(4 [Pi])  Secondly: How do I calculate the Limit of a function with two varibales. For example x->20 and y->0 Thirdly, a bit off topic question. Is it really necessary to limit myself to numerical data? For example, instead of number 20 in my expression for f(x,y) I would like to have a constant a. And than calculate Limit x->a and y->0 and also plot the function. Is that possible? Thank you!
5 Replies
Sort By:
Posted 9 years ago
 Right! I should never answer these questions before my morning coffee...
Posted 9 years ago
 In addition to David Reiss' excellent analysis of the issues I will note that, prior to In, there was almost certainly something like y=0 executed.
Posted 9 years ago
 Well of course you cannot plot (x-a)^2 directly without specifying a value for a since it is not numerical with an arbitrary value of a. You can plot a two-dimensional plot varying both x and a line this: Plot3D[(x - a)^2, {x, -2, 2}, {a, -1, 1}] Or you could look at how a plot of (x-a)^2 varies as you change a dynamically using Manipulate, for example: Manipulate[Plot[(x - a)^2, {x, -2, 2}], {a, -1, 1}] And, of course, there are many other possibilities...
Posted 9 years ago
 Thanks for your answers, the first two work perfectly, about the third one:Looks like there was a misunderstanding. Let's say that my function is f(x):=(x-a)^2 where a is an arbitrary constant. Now I want to plot f(x). Is that possible?
Posted 9 years ago
 I think you are asking why your expression for f[x,y] returns an immediate result. This is because you used Set (=) rather than SetDelayed (:=).So you want In:= f[x_, y_] := (1/(4*Pi))*Log[(x - 20)^2 + y^2] For your question about limits, you need to take the limit of the limit. Remember that limits do not necessarily commute, depending on the nature of the function at the point in question. So, one example you may execute is, in your particular example, In:= Limit[Limit[f[x, y], x -> 20], y -> 0] Out= -\[Infinity] Which of course is not unexpected ;-) As for your off topic question, you don't have to limit yourself to numerical data. However be aware that by using a symbolic value for the limiting value of your parameter you may not capture behaviors in particular cases and that you need to analyze the function to see if there are any issues for particular values of that parameter. In:= Limit[Limit[f[x, y], x -> a], y -> 0] Out= Log[(-20 + a)^2]/(4 \[Pi])