Substitution to make it simple...

1 次查看(过去 30 天)
Masoud Ghanbari
Masoud Ghanbari 2013-11-8
there is recursive sequence and v(2)=...v(1) and v(3)=...v(2)+...v(1) and so on... i want to remove v(2) and replace it with v(2)=...v(1) , at the other hand i need v(3) to be just function of v(1). take a look at the code...
%
%%Initialization
clc;clear all;
VLL=63;
Vph=VLL/(sqrt(3));
N=5;
m=10;
n=5;
%%Body
syms v(k)
flag=0;
for counter=2:N
if counter==2
disp(['Number',num2str(counter)])
v=symfun([(2+1/m)*v(k-1)],k);
v(counter)
clear v
else
syms v(k)
disp(['Number',num2str(counter)])
v=symfun([(2+1/m)*v(k-1)]-v(k-2),k);
v(counter)
end
end
end

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Formula Manipulation and Simplification 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by