{"id":315,"date":"2017-09-14T10:32:43","date_gmt":"2017-09-14T13:32:43","guid":{"rendered":"http:\/\/www.professores.uff.br\/diomarcesarlobao\/?page_id=315"},"modified":"2017-09-14T10:32:43","modified_gmt":"2017-09-14T13:32:43","slug":"implicit-function-matlab-script-by-dio","status":"publish","type":"page","link":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/implicit-function-matlab-script-by-dio\/","title":{"rendered":"Implicit Function matlab script by Dio"},"content":{"rendered":"<pre>%==========================================================================\r\n%\r\n%\r\n% Examples of Implicit Function\r\n%\r\n% Implemented by Prof. Diomar Cesar Lobao\r\n% UFF-Volta Redonda, RJ, Brazil.\r\n% Sept 09th, 2008.\r\n%==========================================================================\r\n%\r\nclear all; clc; close all;\r\n%\r\nx=-1:.1:2;\r\ny=-2:.1:2;\r\n[x,y]=meshgrid(x,y);\r\n% 2y3 + y2 ? y5 = x4 ? 2x3 + x2. ==&gt; F(x,y)=0\r\nF=2*y.^3+y.^2-y.^5-x.^4+2*x.^3-x.^2;\r\n%\r\nfigure(1);\r\nsurfc(x,y,F);\r\n%\r\nfigure(2);\r\n%contour(x,y,z,[0,0]): plots an implicit function of one variable: \r\n% z = F(x,y) = 0\r\n%====&gt; This graph is clearly not the graph of a function.\r\n%====&gt; There are at least two y values for each x value.\r\n[c,h]=contour(x,y,F,[0,0],'k'); clabel(c,h); colorbar;\r\n%\r\nfigure(3);\r\n[c,h]=contour(x,y,F,10); clabel(c,h); colorbar;\r\n%\r\n%\r\nx=-2:.1:2;\r\ny=-2:.1:2;\r\n[x,y]=meshgrid(x,y);\r\nF=x.^2.*y.^2+y.^2.*cos(x)-3;\r\n%\r\nfigure(4);\r\nsurfc(x,y,F);\r\n%\r\nfigure(5);\r\ncontour(x,y,F,[0,0],'k')\r\n%\r\nx=-3:.1:3;\r\ny=-3:.1:3;\r\n[x,y]=meshgrid(x,y);\r\nG=exp(x.*y)-x.^2-y.^2;\r\nfigure(6);\r\nsurfc(x,y,G);\r\n%\r\nfigure(7);\r\ncontour(x,y,G,[0,0],'k')\r\n%\r\nx=-4:.1:4;\r\ny=-4:.1:4;\r\n[x,y]=meshgrid(x,y);\r\nG=x.^2 + 4*y.^2 - 52;\r\nfigure(8);\r\nsurfc(x,y,G);\r\nfigure(9);\r\ncontour(x,y,G,[0,0],'k')\r\n%\r\nx=-4.0:.1:4.0;\r\ny=-4.0:.1:4.0;\r\n[x,y]=meshgrid(x,y);\r\nG=3*x.*y.^2 - 2*y.*x.^3 + 10;\r\nfigure(10);\r\nsurfc(x,y,G);\r\nfigure(11);\r\ncontour(x,y,G,[0,0],'k')<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>%========================================================================== % % % Examples of Implicit Function % % Implemented by Prof. Diomar Cesar Lobao % UFF-Volta Redonda, RJ, Brazil. % Sept 09th, 2008. %========================================================================== % clear all; clc; close all; % x=-1:.1:2; y=-2:.1:2; [x,y]=meshgrid(x,y); % 2y3 + y2 ? y5 = x4 ? 2&#215;3 + x2. ==&gt; F(x,y)=0 F=2*y.^3+y.^2-y.^5-x.^4+2*x.^3-x.^2; % figure(1); surfc(x,y,F); % [&hellip;]<\/p>\n","protected":false},"author":22,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_exactmetrics_skip_tracking":false,"_exactmetrics_sitenote_active":false,"_exactmetrics_sitenote_note":"","_exactmetrics_sitenote_category":0,"footnotes":""},"categories":[],"tags":[],"class_list":["post-315","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/pages\/315","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/users\/22"}],"replies":[{"embeddable":true,"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/comments?post=315"}],"version-history":[{"count":1,"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/pages\/315\/revisions"}],"predecessor-version":[{"id":316,"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/pages\/315\/revisions\/316"}],"wp:attachment":[{"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/media?parent=315"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/categories?post=315"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.professores.uff.br\/diomarcesarlobao\/wp-json\/wp\/v2\/tags?post=315"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}