Team:Peking/drawingcurvetest

From 2013.igem.org

(Difference between revisions)
Line 82: Line 82:
document.getElementById("ncIPlus").onclick=function()        //increase ncI
document.getElementById("ncIPlus").onclick=function()        //increase ncI
{
{
-
   if(ncI<4)
+
   if(ncI<2.6)
   {
   {
-
   ncI=ncI+0.5;
+
   ncI=ncI+0.2;
ctx.clearRect(0,0,c.width,c.height);
ctx.clearRect(0,0,c.width,c.height);
DrawCurve(ctx,convasheight,CorXmin,CorXmax,300,0.01,1000,Kphi,ncI);
DrawCurve(ctx,convasheight,CorXmin,CorXmax,300,0.01,1000,Kphi,ncI);
Line 94: Line 94:
document.getElementById("ncIMinus").onclick=function()        //decrease ncI
document.getElementById("ncIMinus").onclick=function()        //decrease ncI
{
{
-
   if(ncI>0.5)
+
   if(ncI>1)
   {
   {
-
   ncI=ncI-0.5;
+
   ncI=ncI-0.2;
ctx.clearRect(0,0,c.width,c.height);
ctx.clearRect(0,0,c.width,c.height);
DrawCurve(ctx,convasheight,CorXmin,CorXmax,300,0.01,1000,Kphi,ncI);
DrawCurve(ctx,convasheight,CorXmin,CorXmax,300,0.01,1000,Kphi,ncI);

Revision as of 12:34, 24 September 2013

Your browser does not support the HTML5 canvas tag.

Kphi=

-

+

ncI=

-