Challenge

Problem set 2 -week 3 challenge

Followed the formulas mentioned in the help video.

%% Set 2 week 3
% Harsha Vardhan
clear
clc
%% Given
total_weight = 3750;
wheel_base = 98;
cg_height = 17;
tire_radius = 15;
throttle_acceleration = 16.25*12;
g = 32.2*12;
front_spring_rate = 450;
rear_spring_rate = 650;
front_motion_ratio = 0.76;
rear_motion_ratio = 0.72;
front_IC_vertical = 13.22;
front_IC_horizontal = 28.5;
rear_IC_vertical = 16;
rear_IC_horizontal = 42.5;
drive_ratio = 0; %front
%% first question
throttle_g = throttle_acceleration/g;
load_transfer = total_weight*throttle_g*cg_height/wheel_base;
front_weight = 0.55*total_weight-load_transfer;
rear_weight = total_weight-front_weight;
front_wheel_rate = (front_motion_ratio^2)*front_spring_rate;
rear_wheel_rate = (rear_motion_ratio^2)*rear_spring_rate;
front_deflection = load_transfer*0.5/front_wheel_rate;
rear_deflection = load_transfer*0.5/rear_wheel_rate;
pitch_angle = atan((front_deflection+rear_deflection)/wheel_base)*(180/pi);
pitch_gradient = pitch_angle/throttle_g;

%% second question
front_anti_lift_angle = atan((front_IC_vertical-tire_radius)/front_IC_horizontal)*(180/pi);
rear_anti_squat_angle = atan((rear_IC_vertical-tire_radius)/rear_IC_horizontal)*(180/pi);
front_swingarm_angle = atan(cg_height/wheel_base)*(180/pi);
rear_swingarm_angle = atan(cg_height/wheel_base)*(180/pi);
front_anti_lift_percentage = 0;
rear_anti_squat_percentage = (rear_anti_squat_angle/rear_swingarm_angle)*((100-drive_ratio)/100);
front_deflection_new = front_deflection*((100-front_anti_lift_percentage)/100);
rear_deflection_new = rear_deflection*((100-rear_anti_squat_percentage)/100);
pitch_angle_new = atan((front_deflection_new+rear_deflection_new)/wheel_base)*(180/pi)
pitch_angle_gradient_new = pitch_angle_new/throttle_g;

%% third question
% 3 in variables represent third question variables
% swing arm angles will not change
front_IC_vertical_3 = 20;
front_IC_horizontal_3 = 30;
rear_IC_horizontal_3 = 30;
front_anti_lift_angle_3 = atan((front_IC_vertical_3-tire_radius)/front_IC_horizontal_3)*(180/pi);
rear_anti_squat_angle_3 = atan((rear_IC_vertical-tire_radius)/rear_IC_horizontal_3)*(180/pi);
front_anti_lift_percentage_3 = (front_anti_lift_angle_3/front_swingarm_angle)*(drive_ratio/100);
rear_anti_squat_percentage_3 = (rear_anti_squat_angle_3/rear_swingarm_angle)*((100-drive_ratio)/100);
front_deflection_3 = front_deflection*((100-front_anti_lift_percentage_3)/100);
rear_deflection_3 = rear_deflection*((100-rear_anti_squat_percentage_3)/100);
pitch_angle_3 = atan((front_deflection_3+rear_deflection_3)/wheel_base)*(180/pi)

Your portfolio, next

Ship work like this
in your own course.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.

Talk to a career counsellor

Free 20-minute call. We'll map the right course to where you want to work.

By submitting you agree to our Terms and Privacy Policy.