% Script polarPrinter
% Compute pivot angle corresponding to turntable angle to print straight
% line.

% Initializations
r= 10; % Turntable radius and arm length [cm]
phi= 22.5; % Turntable angle [deg]

fprintf('Turntable has radius %.2f cm and is rotated %.2f deg from reference position\n', r, phi)

% Graphics setup
close all
figure
axis([0 60 -30 30])
xlabel('pivot angle (theta) [deg]')
ylabel('error signal (phi - nozzle angle) [deg]')
hold on

% Add code to pivot until angle to nozzle exceeds phi, then print pivot
% angle and radial distance to nozzle.

hold off