Challenge

Project - Data Handling and Interpolation

Ans:

Here we have used the command 'interp1' for interpolation. The output xq1 is put to the text file called 'interpolation'.

Code for interpolation:

clear
clc
T = readtable("VI.XLSX");
x= T.Current;
y=T.Volt;
xq = -17.3:0.1:0.9;
xq1 = interp1(y,x,xq);
fileID = fopen('interpolation.txt','w'); % Open the text file to write the output
fprintf(fileID,'%f','xq1'); % print the output xq1 to the text file
figure(1);
plot(x,y,'o',xq,xq1,':'); % plotting the interpolation
grid;
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.