This is the coding for the driving cycle below .I want to do the same with simulink .I want to run the same cycle in simulink and reset.How can i do?

Ts=1

cycle_name = 'FTP.mat'

%% cycle data

CurrentFolder = pwd;

cd('..\cycledata')

load(cycle_name)

eval(['Speed = ' cycle_name(1:end-4) '.Data;']);

eval(['Time = ' cycle_name(1:end-4) '.Time;']);

%speed=Data.(cycle_name(1:end-4)).data;

%Time=Data.(cycle_name(1:end-4)).Time;

Time_interp = (Time(1):Ts:Time(end))';%1 driving cycle

Speed_interp = (interp1(Time,Speed,Time_interp));%1 driving cycle

plot(Time_interp,Speed_interp)

More Harini Pushparaj's questions See All
Similar questions and discussions