{"id":948,"date":"2020-11-10T19:56:22","date_gmt":"2020-11-10T18:56:22","guid":{"rendered":"https:\/\/interactivemicroeconomics.com\/?page_id=948"},"modified":"2021-07-16T10:07:30","modified_gmt":"2021-07-16T08:07:30","slug":"comparative-statics","status":"publish","type":"page","link":"https:\/\/interactivemicroeconomics.com\/index.php\/sample-page\/comparative-statics\/","title":{"rendered":"Comparative statics"},"content":{"rendered":"\t\t<div data-elementor-type=\"wp-page\" data-elementor-id=\"948\" class=\"elementor elementor-948\">\n\t\t\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-5e242f6 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"5e242f6\" data-element_type=\"section\" data-e-type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-a205048\" data-id=\"a205048\" data-element_type=\"column\" data-e-type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-fd2ce23 elementor-widget elementor-widget-html\" data-id=\"fd2ce23\" data-element_type=\"widget\" data-e-type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t <style>\n \n .botondef {\n\t\tborder: none;\n\t\tbackground-color:transparent;\n\t\tpadding: 3px;\n\t\tfont-family:inherit;\n\t\tfont-size:inherit;\n\t\tfont-weight:bolder;\n\t\ttext-decoration: none;\n\t\tcolor: blue;\n\t\tcursor: pointer;\n\t\t}\n\t\t\n     .mostrar{\n\tpadding: 5px;\n\tbackground: lightblue;\n\twidth: 120px;\n\tborder-radius:6px;\n\tcursor: pointer;\n\tmargin-top: 10px;\n\tmargin-bottom: 10px;\n\tbox-shadow: 2px 2px 5px #000;\n\tdisplay: inline-block;\n\tfont-size: 12pt;\n\tcolor: black;\n\tfont-weight: 100;\n}\n@media screen and (max-width: 750px) {\n  .mostrar {\n   font-size: 10pt;\n  }\n}\n.textomath{\n\tdisplay: none; \n\tborder-left: 10px solid lightblue; \n\tpadding: 0px 0px 00px 10px;\n}\n <\/style>\n <script>\n     \nfunction divMostrar(x){ \n   if(document.getElementById(x).style.display == \"block\" ){\n   document.getElementById(x).style.display = \"none\";\n   } else{\n    document.getElementById(x).style.display = \"block\";      \n   }   \n}\n\nfunction divMostrarOno(x){ \n   if(document.getElementById(x).childNodes[0].nodeValue == \"Hide Math\"){\n   document.getElementById(x).childNodes[0].nodeValue= \"Show Math\";\n   } else{\n    document.getElementById(x).childNodes[0].nodeValue= \"Hide Math\";      \n   }   \n}\n\nfunction itemAbrir(x){ \n   if(document.getElementById(x).style.display == \"block\" ){\n   document.getElementById(x).style.display = \"none\";\n   } else{\n    document.getElementById(x).style.display = \"block\";      \n   }   \n}\n <\/script><style>\n.texto  {\n\tpadding: 0px 60px 0px 60px;\n\tmargin: 0px 0px 0px 0px;\n\toverflow:auto;\n\tfont-size:12pt;\n\tcolor: black;\n\ttext-align: justify;\n    text-justify: inter-word;\n\twidth:100%;\n}\n@media screen and (max-width: 750px) {\n  .texto {\n    padding: 0px 20px 0px 20px;\n\t font-size:10pt;\n  }\n}\n\n\n\n.myDefaultFont  {\nfont-size: 20pt\n}\n@media screen and (max-width: 750px) {\n  .myDefaultFont  {\n   font-size: 10pt\n   \n  }\n}\n\n.sol {\n\t\tcolor: green;\n\t\tbackground-color: lightgreen;\n\t\tborder-style: solid;\n\t\tborder-color: brown;border-width: 1px;\n\t\tpadding: 0px 3px 0px 3px;\n\t\tmargin: 5px;\n\t\tfont-size: 11pt;\n\t\tborder-radius:5px;\n\t\tbox-shadow: 0px 0px gray;\n\t\tcursor: pointer;}\n\t.ejemplo {\n\t\tcolor: green;\n\t\tbackground-color: lightgreen;\n\t\tborder: thin solid green;\n\t\tpadding: 4px;\n\t\tborder-radius:8px;\n\t\tbox-shadow: 3px 3px grey;\n\t\tcursor: pointer;\n\t\tfont-size:12pt}\n\n<\/style>\n\n<link rel=\"stylesheet\" type=\"text\/css\" href=\"\/myStyles\/tooltipster.bundle.css\" \/>\n<link rel=\"stylesheet\" type=\"text\/css\" href=\"\/myStyles\/tooltipster-sideTip-light.min.css\" \/>\n<link rel=\"stylesheet\" type=\"text\/css\" href=\"\/myStyles\/tooltipster-sideTip-shadow.min.css\" \/>\n\n<link rel=\"stylesheet\" type=\"text\/css\" href=\"\/myStyles\/jsxgraph.css\" \/>\n\n<script type=\"text\/javascript\" src=\"\/myScripts\/jsxgraphcore.js\"><\/script>\n\n<style>\n\n.tooltipster-sidetip.tooltipster-light.tooltipster-light-customized .tooltipster-box {\n\tcolor: blue;\n\tbackground: gray;\n\tborder: 3px solid green;\n\tborder-radius: 6px;\n\tbox-shadow: 5px 5px 2px 0 rgba(0,0,0,0.4);\n}\n\n.tooltipster-sidetip.tooltipster-light.tooltipster-light-customized .tooltipster-content {\n\tcolor: black;\n\tbackground-color: #E8E89C;\n\tpadding: 5px;\n\tfont-size:12pt;\n\t\n}\n\n.tooltipster-sidetip.tooltipster-shadow.tooltipster-shadow-customized .tooltipster-box {\n\t\/*color: blue;\n\tbackground: gray;\n\tborder: 3px solid red;\n\tborder-radius: 6px;\n\tbox-shadow: 5px 5px 2px 0 rgba(0,0,0,0.4);*\/\n}\n.tooltipster-sidetip.tooltipster-shadow.tooltipster-shadow-customized .tooltipster-content {\n\tcolor: black;\n\tbackground-color: lightyellow;\n\tpadding: 3px;\n\tfont-size:12pt;\n\t\n}\n\n.tooltip_templates { display: none; }\n.tooltip {\n\t\tcolor: blue;\n\t\tcursor: pointer;}\n.tooltipfig {\n\t\tcolor: black;}\n.botondef {\n\t\tborder: none;\n\t\tbackground-color:transparent;\n\t\tpadding: 0px;\n\t\tfont-family:inherit;\n\t\tfont-size:inherit;\n\t\tfont-weight:bolder;\n\t\ttext-decoration: none;\n\t\tcolor: blue;\n\t\tcursor: pointer;\n\t\t}\n\n<\/style>\n\n<script type=\"text\/javascript\" src=\"\/myScripts\/jquery-3.5.1.min.js\"><\/script>\n<script type=\"text\/javascript\" src=\"\/myScripts\/tooltipster.bundle.min.js\"><\/script>\n<script type=\"text\/javascript\" src=\"\/myScripts\/tooltipster-scrollableTip.min.js\"><\/script>\n\n<script type=\"text\/javascript\" src=\"\/myScripts\/options.js\"><\/script>\n\n<script>\n    $(document).ready(function() {\n            $('.tooltip').tooltipster();\n        });\n\t\t\n\t$(document).ready(function() {\n            $('.botondef').tooltipster();\n        });\n\t$(document).ready(function() {\n            $('.btnmark').tooltipster();\n        });\n    $(document).ready(function() {\n            $('.ejemplo').tooltipster();\n        });\n\t$(document).ready(function() {\n            $('.sol').tooltipster();\n        });\t\n\t$(document).ready(function() {\n            $('.resputest').tooltipster();\n        });\n\t$(document).ready(function() {\n            $('.interactivesol').tooltipster();\n        }); \n<\/script>\n<h2>Comparative statics<\/h2>\n<div class=\"texto\">\n<p>Generally, a comparative statistics exercise consists in observing how the solution to a problem changes in response to a change in some of its data.<\/p>\n      <p>The demand curve links the price to the amount that consumers demand of that good, but there may be other variables that also influence consumer's decisions. For example, think of a good $x$ for which there is a close substitute good. The demand for good $x$ depends on its price but also the other good's price.  So we have that \\[x_d=x_d(p_x,p_y)\\] <\/p>\n      <p>\nHow will $x_d$ depend on $p_x$? <span class=\"sol\"  data-tooltip-content=\"#tip1\" >Sol.<\/span>\n<div class=\"tooltip_templates\">\n<span id=\"tip1\" style=\"maxWidth=400;\" >\nThe higher the price, the less the demand will be.\n<\/span><\/div>What about its dependency on $p_y$? <span class=\"sol\"  data-tooltip-content=\"#tip2\" >Sol.<\/span>\n<div class=\"tooltip_templates\">\n<span id=\"tip2\" style=\"maxWidth=400;\" >\nAs good $x$ and $y$ are substitutes, if good $y$ becomes more expensive, we can expect the demand for good $x$ to increase, even though its price does not change.\n    \n<\/span><\/div>\n<p><button class=\"mostrar\"  id=\"ButSh1\" onclick=\"divMostrar('cuadro1'); divMostrarOno('ButSh1') \">Show Math <\/button><\/p>\n\n<div class=\"textomath\" id=\"cuadro1\">\n<p>We can express it using the partial derivatives \\[ \\frac{\\partial x_d(p_x, p_y)}{\\partial p_x} < 0 \\]\n        which means that the greater the $p_x$, the lower the demand for good $x$.<\/p>\n    <p>And by being substitutes\n    \\[ \\frac{\\partial x_d(p_x, p_y)}{\\partial p_x} > 0 \\]\n    the greater the $p_y$, the greater the demand for good $x$.<\/p>\n    \n<\/div>\n\n\n    <p>We pose the following comparative statics question: How will a rise in $p_y$ affect the equilibrium price of good $x$?<\/p>\n    \n    \n    <p>If you had a specific case, you could calculate the initial and final equilibrium and compare them. But before looking at an example, let's see what happens graphically.<\/p>\n\n\n<\/div> <!-- texto -->\n\n\n\n\n\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<section class=\"elementor-section elementor-inner-section elementor-element elementor-element-423bf01 elementor-section-content-bottom elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"423bf01\" data-element_type=\"section\" data-e-type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-50 elementor-inner-column elementor-element elementor-element-9dce57e\" data-id=\"9dce57e\" data-element_type=\"column\" data-e-type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-0297c87 elementor-widget elementor-widget-html\" data-id=\"0297c87\" data-element_type=\"widget\" data-e-type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<div align=\"center\">\n    <div id=\"fig\" class=\"jxgbox\" style=\"width:290px; height:270px; border:none; border-color:lightgray; margin:3px \"><\/div>\n<\/div>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t<div class=\"elementor-column elementor-col-50 elementor-inner-column elementor-element elementor-element-1153ded\" data-id=\"1153ded\" data-element_type=\"column\" data-e-type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-35dad30 elementor-widget elementor-widget-html\" data-id=\"35dad30\" data-element_type=\"widget\" data-e-type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<div align=\"center\">\n    <div id=\"controles\" class=\"jxgbox\" style=\"width:290px; height:270px; background-color:transparent; border:none\"><\/div>\n\n\n<script type=\"text\/javascript\"> \n\n\nvar panel = JXG.JSXGraph.initBoard('controles', {\n\tboundingbox: [0, 21, 20, 2], \n\tshowNavigation:false, \n\tshowCopyright: false, \n\taxis:false, \n\tpan: {enabled:false},\n\tzoom: {\n \t\t\tenabled:false\n\t\t}\n\t});\n\npanel.create('text',[2,18.5,'Demand:'], {fontSize: 14, fixed:true});\npanel.create('text',[6.5,18.5,function(){return '\\\\[ x_d =  \\\\frac{a- p_x + 0.5 p_y}{b}\\\\]';}], {fontSize: 14, fixed:true, useMathJax:true });\t\n\npanel.create('text',[14,15,'$p_y^0 = 40$'], {fontSize: 14, fixed:true, useMathJax:true});\n\npanel.create('text',[4,16,'$a$'], {fontSize: 14, fixed:true, useMathJax:true, parse:false});\nvar a1 = panel.create('slider',[[5,16],[10,16],[40,70,100]], {\n\t\tname:'Demand', \n\t\tsize:3, \n\t\twithLabel: false,\n\t\twithTicks: false, \n\t\tstrokeWidth:1,\n\t\tfillColor: 'lightgray', \n\t\tstrokeColor: 'gray',\n\t\tbaseline: {strokeWidth:3, strokeColor:'gray', linecap: 'round'},\n\t\thighline: {strokeWidth:0}});\npanel.create('text',[10.5,16,function(){return JXG.toFixed(a1.Value(), 0) ;}], {fontSize: 12, fixed:true });\t\n\npanel.create('text',[4,14,'$b$'], {fontSize: 14, fixed:true, useMathJax:true});\nvar b1 = panel.create('slider',[[5,14],[10,14],[.5,.8,2.5]], {\n\t\tname:'Demand', \n\t\tsnapWidth:0.1,\n\t\tsize:3, \n\t\twithLabel: false,\n\t\twithTicks: false, \n\t\tstrokeWidth:1,\n\t\tfillColor: 'lightgray', \n\t\tstrokeColor: 'gray',\n\t\tbaseline: {strokeWidth:3, strokeColor:'gray', linecap: 'round'},\n\t\thighline: {strokeWidth:0}});\npanel.create('text',[10.5,14,function(){return JXG.toFixed(b1.Value(), 1) ;}], {fontSize: 12, fixed:true });\t\n\npanel.create('text',[2.7,12,'$\\\\Delta p_y$'], {fontSize: 14, fixed:true, useMathJax:true, parse:false});\nvar varpy = panel.create('slider',[[5,12],[10,12],[-30,0,30]], {\n\t\tname:'Demand', \n\t\tsnapWidth:0.1,\n\t\tsize:3, \n\t\twithLabel: false,\n\t\twithTicks: false, \n\t\tstrokeWidth:1,\n\t\tfillColor: 'lightgray', \n\t\tstrokeColor: 'gray',\n\t\tbaseline: {strokeWidth:3, strokeColor:'gray', linecap: 'round'},\n\t\thighline: {strokeWidth:0}});\npanel.create('text',[10.5,12,function(){return JXG.toFixed(varpy.Value(), 1) ;}], {fontSize: 12, fixed:true });\n\n\npanel.create('text',[4,8.7,'Supply: '], {fontSize: 14, fixed:true});\npanel.create('text',[8.2,8.7,function(){return '\\\\[ q_s =  \\\\frac{p- c}{d}\\\\]';}], {fontSize: 14, fixed:true, useMathJax:true });\n\npanel.create('text',[4,6,'$c$'], {fontSize: 14, fixed:true, useMathJax:true});\nvar c1 = panel.create('slider',[[5,6],[10,6],[0,10,40]], {\n\t\tname:'Demand', \n\t\tsize:3, \n\t\twithLabel: false,\n\t\twithTicks: false, \n\t\tstrokeWidth:1,\n\t\tfillColor: 'lightgray', \n\t\tstrokeColor: 'gray',\n\t\tbaseline: {strokeWidth:3, strokeColor:'gray', linecap: 'round'},\n\t\thighline: {strokeWidth:0}});\npanel.create('text',[10.5,6,function(){return JXG.toFixed(c1.Value(), 0) ;}], {fontSize: 12, fixed:true });\t\n\npanel.create('text',[4,4,'$d$'], {fontSize: 14, fixed:true, useMathJax:true});\nvar d1 = panel.create('slider',[[5,4],[10,4],[.5,.8,2]], {\n\t\tname:'Demand', \n\t\tsnapWidth:0.1,\n\t\tsize:3, \n\t\twithLabel: false,\n\t\twithTicks: false, \n\t\tstrokeWidth:1,\n\t\tfillColor: 'lightgray', \n\t\tstrokeColor: 'gray',\n\t\tbaseline: {strokeWidth:3, strokeColor:'gray', linecap: 'round'},\n\t\thighline: {strokeWidth:0}});\npanel.create('text',[10.5,4,function(){return JXG.toFixed(d1.Value(), 1) ;}], {fontSize: 12, fixed:true });\t\n\n   <\/script>\n\n\n<script>\nJXG.Options.axis.ticks.majorHeight = 10;\nJXG.Options.axis.ticks.minorHeight = 5;\nvar figura = JXG.JSXGraph.initBoard('fig', {\n  boundingbox:[-13, 115, 109,-13],\n  showCopyright:false, \n  showNavigation: false,\n\/\/  grid:false,\n  pan: {enabled:false},\nzoom: { enabled:false,\n  \t\tfactorX: 0,  \/\/ horizontal zoom factor (multiplied to JXG.Board#zoomX)\n  \t\tfactorY: 0,  \/\/ vertical zoom factor (multiplied to JXG.Board#zoomY)\n  \t\twheel: false,     \/\/ allow zooming by mouse wheel or\n  \t\tneedShift: true \/\/ mouse wheel zooming needs pressing of the shift key\n\t\t} }\n);\npanel.addChild(figura);\nvar xaxis = figura.create('axis',\n\t[ [0,0],[100,0] ], {\n\t name: '$x$',\n\t withlabel: true, \n\tstraightLast: false,\n\t strokeWidth: 1,\n\t label: {offset: [245, 2], fontSize:11}, \/\/ Doesn't do anything here.\n\t drawZero:false, \/\/ Doesn't do anything here.\n\tstrokeColor: 'black', straightFirst: false, lastArrow: false}\n); \nxaxis.removeAllTicks();\nfigura.create('ticks', [xaxis, 20], { \/\/ The number here is the distance between Major ticks\n\tminorHeight: 4,\n\tstrokeWidth: 1,\n\tstrokeColor:'black',\n\tmajorHeight: 8, \/\/ Need this because the JXG.Options one doesn't apply\n\tdrawLabels:true, \n\tlabel: {offset: [-6, -10], fontSize:11},\n\tminorTicks:3, \/\/ The NUMBER of small ticks between each Major tick\n\tdrawZero:false,\n\ttickEndings: [1,0] }\n);\n\n\nvar yaxis = figura.create('axis',\t[ [0,0],[0,100] ], {\n\tstrokeColor: 'black', \n\tstraightLast: false,\n\tstrokeWidth: 1, \n\tname: '$p$',\n\twithlabel: true, \n\tlabel: {offset: [-2, 225], fontSize:11},\n\tstraightFirst: false, \n\tlastArrow: false});\nyaxis.removeAllTicks();\n\nfigura.create('ticks', [yaxis, 20], {\n\tstrokeColor:'black',\n\tmajorHeight: 8, \/\/ Need this because the JXG.Options one doesn't apply\n\tdrawLabels:true, \/\/ Only works for equidistant ticks\n\tlabel: {offset: [-18, -1], fontSize:11},\n\tminorTicks:3, \/\/ The NUMBER of small ticks between each Major tick\n\tdrawZero: false,\n\ttickEndings: [0,1]\n }\n);\n\nvar newqopt = function(){return (a1.Value()- c1.Value() +0.5* (40+varpy.Value()))\/(b1.Value()+d1.Value())};\nvar newpopt = function(){return d1.Value()* newqopt() + c1.Value()};\n\nvar newtickqstar = figura.create('line',[[newqopt, -3],[newqopt, +3]], {strokeColor:'black',strokeWidth:1, \n\tstraightFirst:false, straightLast:false});\nvar newqstarlabel = figura.create('text',[newqopt,-7,'q\\''], {fontSize: 11});\t\n\nvar newtickpstar = figura.create('line',[[-2.5, newpopt], [2.5, newpopt]], {strokeColor:'black',strokeWidth:1, \n\tstraightFirst:false, straightLast:false});\nvar newpstarlabel = figura.create('text',[-10, newpopt,'p\\''], {fontSize: 11});\t\n\n\n\n\t\nvar newdemlabel = 0;\n\nvar newdemanda = figura.create('functiongraph', [function(x){return a1.Value()-b1.Value()*x+ 0.5*(40+varpy.Value());},0,100], {strokeColor:'green',strokeWidth:2,  withLabel: true, name:'New demand curve', label:{color:'green', visible:function(){ return (newdemlabel<0.5 )? false : true ;}}});\n\nnewdemanda.on('down', function(){return (newdemlabel<0.5 && Math.abs(varpy.Value())>5) ? newdemlabel=1: newdemlabel=0});\n\n\n\nvar qopt = function(){return (a1.Value()- c1.Value() +0.5* (40))\/(b1.Value()+d1.Value())};\nvar popt = function(){return d1.Value()* qopt() + c1.Value()};\n\nvar tickqstar = figura.create('line',[[qopt, -3],[qopt, +3]], {strokeColor:'black',strokeWidth:1, \n\tstraightFirst:false, straightLast:false});\nvar qstarlabel = figura.create('text',[qopt,-7,'q*'], {fontSize: 11});\t\n\nvar tickpstar = figura.create('line',[[-2.5, popt], [2.5, popt]], {strokeColor:'black',strokeWidth:1, \n\tstraightFirst:false, straightLast:false});\nvar pstarlabel = figura.create('text',[-10, popt,'p*'], {fontSize: 11});\t\n\n\n\n\t\nvar demlabel = 0;\n\nvar demanda = figura.create('functiongraph', [function(x){return a1.Value()-b1.Value()*x+ 20;},0,100], {strokeColor:'blue',strokeWidth:2,  withLabel: true, name:'Demand curve', label:{color:'blue', visible:function(){ return (demlabel<0.5)? false : true ;}}});\n\ndemanda.on('down', function(){return demlabel<0.5 ? demlabel=1: demlabel=0});\n\n\n\nvar oferlabel = 0;\n\nvar oferta = figura.create('functiongraph', [function(x){return c1.Value() + d1.Value() * x;},0,100], { strokeColor:'orange', strokeWidth:2, name:'Curva de oferta', withLabel: true , label:{color:'orange', visible:function(){ return (oferlabel<0.5)? false : true ;}}});\n\noferta.on('down', function(){return oferlabel<0.5 ? oferlabel=1: oferlabel=0});\n\n\nvar newequilabel=0;\nvar newequilibrio = figura.create('point',[newqopt, newpopt], { size:2, color:\"red\", showInfobox:false, withLabel: true, name:\"new equilibrium\", label:{visible:function(){ return (newequilabel<0.5 )? false : true ;}} });\nnewequilibrio.on('down', function(){ if(newequilabel<0.5 && Math.abs(varpy.Value())>5) { newequilabel=1; newdemlabel=0; oferlabel=0;} else {newequilabel=0; newdemlabel=0; oferlabel=0;}; return newequilabel});\n\nvar newli = figura.create('line',[newequilibrio,[newqopt, 0]], {strokeColor:'gray',strokeWidth:1, straightFirst:false, straightLast:false,dash:2});\nvar newli2 = figura.create('line',[newequilibrio,[0, newpopt]], {strokeColor:'gray',strokeWidth:1, straightFirst:false, straightLast:false,dash:2});\n\t\nvar equilabel=0;\nvar equilibrio = figura.create('point',[qopt, popt], { size:2, color:\"red\", showInfobox:false, withLabel: true, name:\"equilibrium\", label:{visible:function(){ return (equilabel<0.5)? false : true ;}} });\nequilibrio.on('down', function(){ if(equilabel<0.5) { equilabel=1; demlabel=0; oferlabel=0;} else {equilabel=0; demlabel=0; oferlabel=0;};\nreturn equilabel});\n\nvar li = figura.create('line',[equilibrio,[qopt, 0]], {strokeColor:'gray',strokeWidth:1, straightFirst:false, straightLast:false,dash:2});\nvar li2 = figura.create('line',[equilibrio,[0, popt]], {strokeColor:'gray',strokeWidth:1, straightFirst:false, straightLast:false,dash:2});\n\n\t\n\n\n\nfigura.create('polygon', [[0, 100], [0,150], [150,150], [150,100]], { layer:8, borders: { visible:false, color:'black'},vertices: {visible: false, fixed:true}, color:'white', highlight:false, opacity:1});\n\nfigura.create('polygon', [[0, 0], [110,0], [110,-20], [0,-20]], { layer:8, borders: { visible:false, color:'black'},vertices: {visible: false, fixed:true}, color:'white', highlight:false, opacity:1});\n\n\n\n<\/script>\n<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-1433d5b elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"1433d5b\" data-element_type=\"section\" data-e-type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-9c13980\" data-id=\"9c13980\" data-element_type=\"column\" data-e-type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t<div class=\"elementor-element elementor-element-51fd151 elementor-widget elementor-widget-html\" data-id=\"51fd151\" data-element_type=\"widget\" data-e-type=\"widget\" data-widget_type=\"html.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t<div class=\"texto\">\n    \n    <p>The initial demand curve corresponds to an initial price of the substitute good, $p_y^o$. What happens if this $p_y$ varies?<\/p>\n    <p>The figure allows you to propose a specific <a class=\"botondef\"  href=\"\/index.php\/sample-page\/comparative-statics\/defi-variation\/\"> variation<\/a> of $p_y$. A positive value, $\\Delta p_y>0$, means a price increase (if, $\\Delta p_y<0$ we are looking at a decrease).<\/p>\n        <ul>\n    <li>Before moving $\\Delta p_y$, can you anticipate what will happen to the demand curve in the figure? <span class=\"sol\"  data-tooltip-content=\"#tip3\" >Sol.<\/span>\n<div class=\"tooltip_templates\">\n<span id=\"tip3\" style=\"maxWidth=400;\" >\nRemember that $x$ and $y$ are substitutes for each other. An increase in $p_y$ will increase the demand for the good $x$ at any price $p_x$. Thus, a new demand curve emerges further to the right than the initial one.\n<\/span><\/div> Use the slider and check.\n\n            <\/li>\n    \n        <li>Will the rise of $p_y$ affect the market equilibrium of the good $x$? How? <span class=\"sol\"  data-tooltip-content=\"#tip4\" >Sol.<\/span>\n<div class=\"tooltip_templates\">\n<span id=\"tip4\" style=\"maxWidth=400;\" >\nThe new equilibrium, $(x',p')$, will be the point where the new demand curve and the <span class=\"tooltip\"  data-tooltip-content=\"#tip5\" >supply curve<\/span><span class=\"tooltip_templates\"><span id=\"tip5\" style=\"maxWidth=400;\" >\nThe supply curve remains the same.\n<\/span><\/span>\n intersect\n<\/span><\/div>\n\n            <\/li>\n      <li>How does the $p_y$ increase affect the equilibrium price of the good $x$? and how does it affect the amount exchanged? <span class=\"sol\"  data-tooltip-content=\"#tip6\" >Sol.<\/span>\n<div class=\"tooltip_templates\">\n<span id=\"tip6\" style=\"maxWidth=400;\" >\nThe new equilibrium price is higher than the initial one. Even so, the expansion of demand causes an increase in the amount exchanged (the rise in the amount is not as high as it would have been if the price of the good $x$ had remained the same, but still increases).<\/span><\/div>\n\n            <\/li>\n      <li>The above answer is based on what the figure shows, can you make an economic reading of what happens? <span class=\"sol\"  data-tooltip-content=\"#tip7\" >Sol.<\/span>\n<div class=\"tooltip_templates\">\n<span id=\"tip7\" style=\"maxWidth=400;\" >\nAs $p_y$ rises, the demand for the $x$ good increases at any $p_x$. But companies are already offering everything they want to sell at that price, so there would be an excess demand that would push up the price. This rise means that companies are willing to sell more at the same time as consumers no longer want to buy so much. The process stops when the new market equilibrium is reached at $(x',p')$.\n<\/span><\/div>\n      <\/li>\n    <\/ul>\n    \n  <p><span class=\"ejemplo\"  data-tooltip-content=\"#tip8\"  >Example<\/span><\/p>\n<div class=\"tooltip_templates\">\n<span id=\"tip8\" style=\"maxWidth=400;\" >\nWe have a supply curve for the good $x$ \\[x_s=p_x-8\\]\nwhile the demand for the good $x$ is given by \n\\[x_d=80+p_y-2 p_x\\]\n($y$ good is a substitutive for $x$) Initially, $p_y^o=20$\n        \n    <ul>\n    <li>\nWhat is the initial market equilibrium for the $x$ good? <span class=\"sol\"  data-tooltip-content=\"#tip9\" >Sol.<\/span>\n<div class=\"tooltip_templates\">\n<span id=\"tip9\" style=\"maxWidth=400;\" >\nMatching supply and demand (and using $p_y=20$)\\[80+20-2 p_x=p_x-8 \\Longrightarrow p_x^*=36 \\;\\mathrm{ ,}\\;\\;x^*=28\\]\n<\/span><\/div>\n            <\/li>\n      <li>What would be the equilibrium if $p_y$ rises up to $p_y'=32$? <span class=\"sol\"  data-tooltip-content=\"#tip10\" >Sol.<\/span>\n<div class=\"tooltip_templates\">\n<span id=\"tip10\" style=\"maxWidth=400;\" >\nWe repeat the calculation for the new $p_y$ \\[80+32-2 p_x=p_x-8 \\Longrightarrow p_x'=\\frac{120}{3}=40 \\;\\mathrm{ ,}\\;\\;x'=28\\]\n<\/span><\/div>\n\n            <\/li>\n\n      <li>What was the impact of the $p_y$ increase? <span class=\"sol\"  data-tooltip-content=\"#tip11\" >Sol.<\/span>\n<div class=\"tooltip_templates\">\n<span id=\"tip11\" style=\"maxWidth=400;\" >\nBy comparing the initial and final equilibria we have that an increase $\\Delta p_y=12$ causes the following variations in the equilibrium\n    \\[\\Delta p_x=40-36=4 \\quad \\textrm{and}\\quad \\Delta x=32-28=4\\]\n<\/span><\/div>\n\n            <\/li>\n          \n    <\/ul>\n<\/span>\n<\/div>\n  \n <button class=\"mostrar\"  id=\"ButSh2\" onclick=\"divMostrar('cuadro2'); divMostrarOno('ButSh2') \">Show Math <\/button>\n\n<div class=\"textomath\" id=\"cuadro2\">\n<p>A bit of calculation allows us to obtain a general expression for the impact of the $p_y$ change on the equilibrium $p_x$. We have a supply of $x$ that depends on $p_x$ and a demand that depends on $p_x$ and also on $p_y$. The equilibrium equation will be<\/p>\n\\[x_d(p_x,p_y)=x_s(p_x)\\]\nBy clearing $p_x$ in this equation, we obtain an expression in which the price of equilibrium, $p_x^*$, depends on $p_y$ \\[x_d(p_x(p_y),p_y)=x_s(p_x(p_y))\\]\n<p>Deriving the expression with respect to $p_y$ we have<\/p>\n\\[\\frac{\\partial x_d(\\cdot)}{\\partial p_x}\\frac{\\mathrm{d}p_x(\\cdot)}{\\mathrm{d}p_y}+\\frac{\\partial x_d(\\cdot)}{\\partial p_y}=\\frac{\\mathrm{d}x_s(\\cdot)}{\\mathrm{d}p_x}\\frac{\\mathrm{d} p_x(\\cdot)}{\\mathrm{d}p_y}\\] \n\nand rearranging\n\\[\\frac{\\mathrm{d}p_x(\\cdot)}{\\mathrm{d}p_y}\\left(\\frac{\\mathrm{d} x_s(\\cdot)}{\\mathrm{d} p_x}-\\frac{\\partial x_d(\\cdot)}{\\partial  p_x}\\right)=\\frac{\\partial x_d(\\cdot)}{\\partial p_y}\\] \n\nFinally, \n\\[\\frac{\\mathrm{d}p_x(\\cdot)}{\\mathrm{d}p_y}=\\frac{\\frac{\\partial x_d(\\cdot)}{\\partial p_y}}{\\left(\\frac{\\mathrm{d} x_s(\\cdot)}{\\mathrm{d} p_x}-\\frac{\\partial x_d(\\cdot)}{\\partial  p_x}\\right)}\\] \nThe effect of a change in $p_y$ on the equilibrium price of the $x$ good is determined by the $x_d$ derivative with respect to the $p_y$ (which would be the horizontal shift in $x$'s demand per unit of rise in $p_y$) and the difference between the derivatives in $p_x$ of supply and demand (which are the inverse of the slopes).\n<\/div>\n\n<script>\n       \n\t\t\n\t$('.tooltip').tooltipster({\n    \t\ttheme: ['tooltipster-light', 'tooltipster-light-customized'],\n\t\t\ttrigger: 'click',\n\t\t\tmaxWidth: '250',\n\t\t\tinteractive: true\n\n\t\t});\n     \n\t$('.tooltipfig').tooltipster({\n    \t\ttheme: ['tooltipster-light', 'tooltipster-light-customized'],\n\t\t\ttrigger: 'click',\n\t\t\tmaxWidth: '150'\n\t\t});\n\n\t$('.botondef').tooltipster({\n    \t\ttheme: ['tooltipster-light', 'tooltipster-light-customized'],\n\t\t\tmaxWidth: '250'\n\t\t});\n\t$('.btnmark').tooltipster({\n    \t\ttheme: ['tooltipster-light', 'tooltipster-light-customized'],\n\t\t\tmaxWidth: '250'\n\t\t});\n\t$('.ejemplo').tooltipster({\n    \t\ttheme: ['tooltipster-light', 'tooltipster-light-customized'],\n\t\t\tplugins: ['sideTip', 'scrollableTip'],\n\t\t\ttrigger: 'click',\n\t\t\tmaxWidth: '450',\n\t\t\tinteractive: true\n\t\t});\n\t$('.sol').tooltipster({\n    \t\ttheme: ['tooltipster-light', 'tooltipster-light-customized'],\n\t\t\tplugins: ['sideTip', 'scrollableTip'],\n\t\t\ttrigger: 'click',\n\t\t\tmaxWidth: '220',\n\t\t\tinteractive: true\n\t\t});\n\t\n\t$('.resputest').tooltipster({\n\t   \t\ttheme: ['tooltipster-shadow', 'tooltipster-shadow-customized'],\n\t\t\ttrigger: 'custom',\n\t\t\tinteractive: true,\n   \t\t\ttriggerOpen: {\n        \t\t\/\/click: true,\n        \t\t\/\/tap: true\n   \t\t\t },\n    \t\ttriggerClose: {\n        \t\tclick: true,\n        \t\ttap: true\n   \t\t\t },\n\t\t\tmaxWidth: '250'\n\t\t});\n\t\t\n\t\t$('.interactivesol').tooltipster({\n    \t\ttheme: ['tooltipster-light', 'tooltipster-light-customized'],\n\t\t\tplugins: ['sideTip', 'scrollableTip'],\n\t\t\ttrigger: 'click',\n\t\t\tmaxWidth: '220',\n\t\t\tinteractive: true\n\t\t});\n\t\n    <\/script>\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<\/div>\n\t\t","protected":false},"excerpt":{"rendered":"<p>Comparative statics Generally, a comparative statistics exercise consists in observing how the solution to a problem changes in response to a change in some of its data. The demand curve links the price to the amount that consumers demand of that good, but there may be other variables that also influence consumer&#8217;s decisions. For example, &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/interactivemicroeconomics.com\/index.php\/sample-page\/comparative-statics\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Comparative statics&#8221;<\/span><\/a><\/p>\n","protected":false},"author":3,"featured_media":0,"parent":2,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"elementor_header_footer","meta":{"_monsterinsights_skip_tracking":false,"_monsterinsights_sitenote_active":false,"_monsterinsights_sitenote_note":"","_monsterinsights_sitenote_category":0,"footnotes":""},"class_list":["post-948","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/interactivemicroeconomics.com\/index.php\/wp-json\/wp\/v2\/pages\/948","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/interactivemicroeconomics.com\/index.php\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/interactivemicroeconomics.com\/index.php\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/interactivemicroeconomics.com\/index.php\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/interactivemicroeconomics.com\/index.php\/wp-json\/wp\/v2\/comments?post=948"}],"version-history":[{"count":110,"href":"https:\/\/interactivemicroeconomics.com\/index.php\/wp-json\/wp\/v2\/pages\/948\/revisions"}],"predecessor-version":[{"id":1653,"href":"https:\/\/interactivemicroeconomics.com\/index.php\/wp-json\/wp\/v2\/pages\/948\/revisions\/1653"}],"up":[{"embeddable":true,"href":"https:\/\/interactivemicroeconomics.com\/index.php\/wp-json\/wp\/v2\/pages\/2"}],"wp:attachment":[{"href":"https:\/\/interactivemicroeconomics.com\/index.php\/wp-json\/wp\/v2\/media?parent=948"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}