Advertisement
Guest User

Untitled

a guest
Nov 20th, 2019
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
MatLab 1.04 KB | None | 0 0
  1. degrees_arr = [0.087266463 0.174532925 0.261799388 0.34906585 0.436332313 0.523598776 0.610865238 0.698131701 0.785398163 0.872664626 0.959931089];
  2. visibility_arr = [0.936170213 0.914893617 0.870967742 0.784946237 0.677419355 0.548387097 0.397849462 0.268817204 0.086956522 0.078651685 0.288888889];
  3. colors_arr = [[1,0,0] [0,1,0] [0 ,0, 1] [0, 1, 1] [1, 0 ,1] [1, 1, 0] [0, 0 ,0] [0.8500 ,0.3250 ,0.0980] [0.4940 ,0.1840, 0.5560] [0.4660, 0.6740 ,0.1880] [0.6350, 0.0780, 0.1840]];
  4. length_arr = length(visibility_arr);
  5.  
  6. theta = linspace(0, 2*pi);
  7.  
  8. for i = 1:length_arr
  9.     x = visibility_arr(i) * cos(degrees_arr(i)) * cos(theta);
  10.     y = visibility_arr(i) * sin(degrees_arr(i)) * sin(theta);
  11.    
  12.     plot(x,y, 'Color' ,colors_arr(3 * i - 2 : 3 * i), 'LineWidth',3);
  13.     title('Ellipses of the measured angles of  Quarter-wave plate and the Visibility calculated');
  14.     xlabel('X = calculated visibility \cdot cos(angle) \cdot cos(t)')
  15.     ylabel('Y= calculated visibility \cdot sin(angle) \cdot sin(t)')
  16.    
  17.     axis equal;
  18.     hold on;
  19. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement