Shadow length Implimentation

Here my Tracker Desired angle calculated for single tracker. Since there array of tracker tracker has to be modified to get more output.

In my below code Angle is being decremented instead of increment, tracker desired and Angle are not matching

COde here
http://paste.ubuntu.com/7173040/

void  calc_back_track()
{
  static int D_min;
  static float  height=1200;
  static float  D_max;
  static int altiude;
  float phi_a = azimuth*M_PI/180;

  //  D_max=1500*D_min;

  // D_min= D_max*cos(180-phi_a);

  // tracker_desire=(atan(h/D_min)*(180/M_PI));
  //tracker_desire=tracker_desire-90;

  //  D_min= D_max*cos(phi_a-180);
calcElevationAngle();
  D_max=height/tan(conv_elevation*0.0174532925);
  Serial.print("DMAX:");
  Serial.println(D_max);
  D_min= D_max*cos(180-phi_a);
  Serial.print("D_min:");
  Serial.println(D_min);
Angle=(atan(height/D_max)*(180/M_PI));
 Serial.print("Shadow_angle:");
  Serial.println(Angle);
  if(conv_elevation>0)
    tracker_desire = 90-conv_elevation;
  else
    tracker_desire = -(90+conv_elevation);

  limitTrackerDesAngle();
  
  

}
void limitTrackerDesAngle(){
  tracker_desire = constrain(tracker_desire,-MAX_TRACK_ANGLE,MAX_TRACK_ANGLE);

}