Skip to content
Permalink
master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
Latest commit 482822a Nov 18, 2017 History
1 contributor

Users who have contributed to this file

function [Cd_out] = sphere_drag(Re_in,spline_type)
% interpolation for drag coeff based upon Reynolds number
% output is
% Cd: drag coeff
% input is
% Re_in: Reynolds number
% and
% spline_type: 'linear', 'cubic', or 'spline'/'pchip'
%function [Cd_out]=sphere_drag(Re_in,spline_type)
data = [2 0.52
5.8 0.52
16.8 0.52
27.2 0.5
29.9 0.49
33.9 0.44
36.3 0.18
40 0.074
46 0.067
60 0.08
100 0.12
200 0.16
400 0.19];
Cd_out = interp1(data(:,1),data(:,2),Re_in,spline_type);
end