How to Write cell array to Excel

Hi, I have finally been able to get results using the following script however each of the results come out as a (1 x 1 cell). I know that i can use celldisp to reveal each cells result but how do i write them to excel. The script is as follows.
numData = xlsread('Method 2 Worksheet');
%Pressure From Excel
P = numData(:,13);
Ruskin = numData(:,14);
Burst = numData(:,1);
%Variables from excel calcs
W = 0.392699;
K = 13.8125;
q = 10.13;
d = 9.5;
g = 9.81;
x = 1025;
%Use H=F(Min:Max) for values
Sx=cell(numel(P),1);
for ii = 1:length(P)
syms z
eqn = (P(ii).*10.^4./x)-(q.*10.^4./x)==((W.^2.*cosh(K.*(d+z)))/(sinh(K.*d)))-g.*z;
Sx{ii} = solve(eqn,z);
end
celldisp(Sx)

답변 (1개)

KSSV
KSSV 2020년 9월 4일

0 개 추천

Read about xlswrite and writetable.

댓글 수: 1

Joshua Foote
Joshua Foote 2020년 9월 4일
I have read that and tried those commands and they did not work. Could you be more specific on what to type exactly

댓글을 달려면 로그인하십시오.

카테고리

태그

질문:

2020년 9월 4일

댓글:

2020년 9월 4일

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by