set Interval seconds is faster than, local time second
<p>I made a clock, using jquery. it was good. now i noted that, the time is varying from my actual system time, while my clock starts it is good. in case if my clock run a long time, i am getting variation from system time.</p>

<p>my function is :</p>

<pre><code>$(document).ready(function(){

                var paper = new Raphael(document.getElementById('USClock'),500,500);

                var secondHand = paper.path('m 250,250, l 0 -200');
                var minuteHand = paper.path('m 250,250, l 0 -200');
                var hourHand = paper.path('m 250,250, l 0 -150')
                minuteHand.attr({'stroke':"#f00",'stroke-width':5});
                hourHand.attr({'stroke':"#0ff",'stroke-width':10})

                 var myDate = new Date();
                 var actualSeconds = myDate.getSeconds();
                 var actualMinutes = myDate.getMinutes();
                 var actualHours = myDate.getHours();
               // 

               var currentSecondDeg = actualSeconds*6;
               var currentMinuteDeg = actualMinutes*6;
               var currentHourDeg  =  actualHours*30 + ((actualMinutes)*0.5);

               var num = currentSecondDeg;

               secondHand.rotate(currentSecondDeg,250,250);
               minuteHand.rotate(currentMinuteDeg,250,250);
               hourHand.rotate(currentHourDeg,250,250);

               var update = function(){
                    num +=6;
                    currentSecondDeg = num;
                    secondHand.rotate(currentSecondDeg,250,250);
                    if(( currentSecondDeg % 360) == 0){
                        num = 0;
                        currentMinuteDeg +=6;

                        minuteHand.rotate(currentMinuteDeg,250,250);

                        currentHourDeg += 0.5; // 360/12 = 30deg per hour so per min 30/60 = 0.5

                        hourHand.rotate(currentHourDeg,250,250);

                        if(currentMinuteDeg == 360){
                            currentMinuteDeg = 0;
                        }

                        if(currentHourDeg == 360){
                            currentHourDeg = 0;
                        }
                    }
                    //$('p').html('SecondsDeg'+(currentSecondDeg)+'&lt;br&gt; currentMinuteDeg'+currentMinuteDeg+'&lt;br&gt;currentHourDeg'+currentHourDeg);
               }
               var myInterval = setInterval(update,1000);
            })
</code></pre>

<p>actually my question is why the set interval varys from long time process. as well if any one find the issue or wrong approach of work with my function let me know. Else, if any one know a good way to do as well appreciated.</p>

<p>thanks in advance! Any way to solve it, else how can i show 4 different clock in to my website? only way to get time from server?</p>
