Carpet Plot Toolkit
18 Mar 2013
A set of routines to make carpet plotting easier.
|Cconv=carpetcontourconvert(x1, x2, y, offset, C)
function Cconv=carpetcontourconvert(x1, x2, y, offset, C)
%CARPETCONTOURCONVERT Converts contour curves into carpet plot coordinates.
% Cconv=carpetcontourconvert(x1, x2, y, offset, C) converts the contour
% curves in C into carpet plot coordinates defined by (x1, x2, y, offset)
% as described in CARPET.
% The converted contour curves are returned in Cconv.
% See also CARPET, CARPETCONVERT.
% Rob McDonald
% 19 February 2013 v. 1.0
Cconv=C; % Initialize to same size.
% Pick off contour points
% Convert curves to carpet coordinates.
[xc, yc] = carpetconvert(x1, x2, y, offset, x1c, x2c);
% Reconstruct converted contour curves
Cconv(1,icont+1:icont+n) = xc;
Cconv(2,icont+1:icont+n) = yc;