필터 지우기
필터 지우기

Solution of dsolve with varible f which is not declared with syms

조회 수: 1 (최근 30일)
Vladan Radulovic
Vladan Radulovic 2012년 10월 8일
편집: Walter Roberson 2015년 7월 8일
I am trying to get solution of the differential equation of second order with code given bellow:
clc
clear
syms L C R E w t uc
u=dsolve('L*C*D2uc+R*C*Duc+uc-E*cos(w*t)=0','uc(0)=E','Duc(0)=0','t');
MATLAB 7.0 gives me solution in which exists variable "f". As it can be seen, this variable has not been declared. Consequently, If I want to implement subs function, I can not substitute all variables.
What seems to be problem and please, what would be solution?

답변 (1개)

RahulTandon
RahulTandon 2015년 7월 7일
편집: Walter Roberson 2015년 7월 8일
%% Section 1
% IT WORKS, HERE IS THE SOLUTION
clc;
syms L C R E w t uc CLEAR;
u=dsolve('L*C*D2uc+R*C*Duc+uc-E*cos(w*t)==0','uc(0)=E','Duc(0)=0','t');
% THERE IS NO F IN THE SOLUTION
% BUT IT IS A LONG AND COMPLEX ONE

카테고리

Help CenterFile Exchange에서 Assumptions에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by