|
Impieghiamo R (ma potrebbe essere impiegato altro software);
vedi.source("http://macosa.dima.unige.it/r.R") # se non già caricato
f=function(x,y) (x*y)^2-1; g=function(x,y) 2*x^2-y^2-x*y-1
PLANE(-5,5, -5,5); CURVE(f, "brown"); CURVE(g,"seagreen")
# Ingrandisco:
PLANE(-1.5,1.5, -1.5,1.5); CURVE(f, "brown"); CURVE(g,"seagreen")
# (x*y)^2-1 equivale a (x*y)^2=1 e a (x*y=1 | x*y=-1). Dunque:
h = function(x) 2*x^2-(1/x)^2-2 # intersezione di "g" con due dei rami di "f"
x1 = solution(h,0, 1,2); y1=1/x1; more(x1); more(y1)
# 1.16877089448037 0.855599677167352
x2 = solution(h,0, -1,-2); y2=1/x2; more(x2); more(y2)
# -1.16877089448037 -0.855599677167352
h = function(x) 2*x^2-(1/x)^2 # intersezione di "g" con gli altri due rami di "f"
x3 = solution(h,0, 0.7,1); y3=-1/x3; more(x3); more(y3)
# 0.840896415253715 -1.18920711500272
x4 = solution(h,0, -1,-0.7); y4=-1/x4; more(x4); more(y4)
# -0.840896415253715 1.18920711500272
|