%% dimensional parameters of TCF dataset
delta_nu		= 1.0006E-3;		% plus unit
Ub				= 0.99994;			% bulk velocity
Uc				= 1.1312;			% centerline velocity
u_tau			= 4.9968E-2;		% friction velocity
nu				= 5E-5;				% kinematic viscosity
T_sim			= [0 25.9935];		% simulation duration
t_sim_step		= 0.0013;			% simulation timestep
t_save_step		= 0.0065;			% timestep for snapshots
h				= 1;				% half height
length			= 8*pi;				% channel length
width			= 3*pi;				% channel width

%% scale for database to reconstruction coordinates
dns_length_mm	= 300 / (2*h);	% channel height = 300mm
% match viscosity to water, i.e. 1mm^2/s
nu_mms			= 1;
dns_time_s		= nu_mms / nu / dns_length_mm^2;
dns_vel_mms		= dns_length_mm / dns_time_s;

%% rescale
re_h			= h * dns_length_mm;
re_length		= length * dns_length_mm;
re_width		= width * dns_length_mm;
re_delta_nu		= delta_nu * dns_length_mm;
re_Ub			= Ub * dns_vel_mms;
re_Uc			= Uc * dns_vel_mms;
re_u_tau		= u_tau * dns_vel_mms;
re_nu			= nu * dns_length_mm^2 / dns_time_s;
re_T_sim		= T_sim * dns_time_s;

fprintf('rescaled units:\n');
fprintf('channel height:    %f mm\n', re_h);
fprintf('channel length:    %f mm\n', re_length);
fprintf('channel width:     %f mm\n', re_width);
fprintf('U_bulk:            %f mm/s\n', re_Ub);
fprintf('U_cl:              %f mm/s\n', re_Uc);
fprintf('u_tau:             %f mm/s\n', re_u_tau);
fprintf('delta_nu:          %f mm\n', re_delta_nu);
