着急求知:我的MATLAB配置xcode9打包出来有问题什么问题吗?请高手帮帮忙!

查看: 1454|回复: 13
急!!Matlab解微分方程的问题,请高手帮忙!谢谢!
程序如下所示:
syms A B zz
A=1.75*z^3/(z^3+0.15^3);
B=taylor(A)
14000/27*z^3
&& zz=dsolve('Dz=1.0446*(1-z)-2*z-1400/27*z^3')
Warning: Explicit solutio implicit solution returned.
& In dsolve at 310
t+Int(-1/(223/5000*_a-1400/27*_a^3),_a =&&.. z)+C1 = 0
上面的方程没有彻底解出,还包含有省略号,请问高手们,怎么样才可以解出这个微分方程?
因为我要的是关于(t,z)的曲线,
接下来我用ezplot(zz)就是错误了
??? Error using ==& char
Cell elements must be character arrays.
Error in ==& ezplot at 154
& && && && &fmsg = char(f);
Error in ==& sym.ezplot at 46
& &h = ezplot(f.s);
请大家帮忙解解这个微分方程,谢谢!!
拜托大家帮帮忙,万分感谢!!!
虽然我不是高手,但是不好意思,我连你的要求都没有看懂?求什么微分方程?那里有t参数?
回复 3# ccna1984 的帖子
微分方程是
dz/dt=1.0446*(1-z)-2*z-1400/27*z^3
谢谢你!呵呵
怎么没人帮忙啊?
回复 5# luxinxinger 的帖子
看不懂你写的什么&&把原方程贴出来
原方程是:
dz/dt=1.0446*(1-z)-2*z-1.75*z^3/(z^3+0.15^3)
请大家帮帮忙,谢谢!
回复 9# ijkl995 的帖子
解不出来精确解
你就求解数值解吧
数值解 随便取的初值
Powered by请各位高手帮帮忙 用matlab 编写个程序 将-2,-1,0,1,2这五个数的120种排列组合全部显示出来?_百度知道
请各位高手帮帮忙 用matlab 编写个程序 将-2,-1,0,1,2这五个数的120种排列组合全部显示出来?
提问者采纳
给你贴个函数原型吧,function P = perms(V)%PERMS
All possible permutations.%
PERMS(1:N), or PERMS(V) where V is a vector of length N, creates a%
matrix with N! rows and N columns containing all possible%
permutations of the N elements.%%
This function is only practical for situations where N is less%
than about 10 (for N=11, the output takes over 3 giga-bytes).%%
Class support for input V:%
float: double, single%%
See also NCHOOSEK, RANDPERM, PERMUTE.%
The MathWorks, Inc.%
$Revision: 1.12.4.1 $
17:02:07 $V = V(:).'; % Make sure V is a row vectorn = length(V);if n &= 1, P = V; endq = perms(1:n-1);
% recursive callsm = size(q,1);P = zeros(n*m,n);P(1:m,:) = [n * ones(m,1) q];for i = n-1:-1:1,
t(t == i) =
P((n-i)*m+1:(n-i+1)*m,:) = [i*ones(m,1) t]; % assign the next m
% rows in P.endP = V(P);
其他类似问题
其他2条回答
perms([-2 -1,0,1,2])
perms([-2 -1 0 1 2])
等待您来回答
下载知道APP
随时随地咨询
出门在外也不愁求matlab高手帮帮忙,问题可能很菜鸟,就是算出来一个这么复杂的函数,_百度知道
求matlab高手帮帮忙,问题可能很菜鸟,就是算出来一个这么复杂的函数,
P3=subs(4*cos(2*l*((m/2 - n/2)^2 + k^2)^(1/2))^2*cos(k*l)^2*sin(k*l)^2 + (k^2*sin(2*l*((m/2 - n/2)^2 + k^2)^(1/2))^2*cos(k*l)^4)/((m/2 - n/2)^2 + k^2) + (k^2*sin(2*l*((m/2 - n/2)^2 + k^2)^(1/2))^2*sin(k*l)^4)/((m/2 - n/2)^2 + k^2) - (2*k^2*sin(2*l*((m/2 - n/2)^2 + k^2)^(1/2))^2*cos(k*l)^2*sin(k*l)^2)/((m/2 - n/2)^2 + k^2) - (4*k*cos(2*l*((m/2 - n/2)^2 + k^2)^(1/2))*sin(2*l*((m/2 - n/2)^2 + k^2)^(1/2))*cos(k*l)*sin(k*l)^3)/((m/2 - n/2)^2 + k^2)^(1/2) + (4*k*cos(2*l*((m/2 - n/2)^2 + k^2)^(1/2))*sin(2*l*((m/2 - n/2)^2 + k^2)^(1/2))*cos(k*l)^3*sin(k*l))/((m/2 - n/2)^2 + k^2)^(1/2),{(m/2 - n/2),k,l},{1/lambda,})lambda=1.30:0.01:1.60;ezplot(P3,lambda)最后有K,l,lambda 三个变量,我的目的是想找到K,l的值使的P3的值随lambda变化不明显,几乎与lambda无关,lambda的值在1310nm到1600nm,我上面用subs函数是假设K,l为某一个定值,可是这样手动的改,找不到最优解,也没有说服力,有没有高手帮帮我该怎么办
提问者采纳
其实你只要把式子改成点乘,因为是矩阵,就可以实现你的要求啦,跟C语言一样的
提问者评价
谢谢,看到楼上两位的回答,我感到很无奈,这个平台。。。。。。
采纳率100%
其他类似问题
matlab的相关知识
按默认排序
其他1条回答
,也没有说服力,有没有高手帮
您可能关注的推广
等待您来回答
下载知道APP
随时随地咨询
出门在外也不愁用matlab拟合函数,将这两组数据给拟合,算出xy的关系式。这个数据应该是指数函数,请各位高手帮帮忙,谢_百度知道
用matlab拟合函数,将这两组数据给拟合,算出xy的关系式。这个数据应该是指数函数,请各位高手帮帮忙,谢
x=[98 103 117 142 186 232 291 363 435 526 615 61 16 45 50 26 29
65491];y=[0.3 0.5 0.7 1 1.3 1.7 2.1 2.5 3 3.5 4 6.3 9 11.7 14.5 17.2 19.8 22.5 25.2 27.8 30.5 33.1 35.5 37.9 40.4 42.7 44.9 47.1 49.1 53 57.5 61.5 65.5 68.5 72.2 85.4 101.2 114 121 123 132 140 148 152 157 187 193 240 282 329 568 786 818 879 45 65];
谢谢qibbxxt的提供,但是我没有fittype这个函数,请问还有什么好办法吗?
提问者采纳
function createFit(x,y)%CREATEFIT Create plot of data sets and fits%
CREATEFIT(X,Y)%
Creates a plot, similar to the plot in the main Curve Fitting Tool,%
using the data that you provide as input.
use this function with the same data you used with CFTOOL%
or with different data.
You may want to edit the function to%
customize the code and this help message.%%
Number of data sets:
Number of fits:
1% Data from data set &y vs. x&:%
Unweighted% Auto-generated by MATLAB on 01-Dec-:25if nargin==0
x=[98 103 117 142 186 232 291 363 435 526 615 61 16 45 50 26 29
65491];y=[0.3 0.5 0.7 1 1.3 1.7 2.1 2.5 3 3.5 4 6.3 9 11.7 14.5 17.2 19.8 22.5 25.2 27.8 30.5 33.1 35.5 37.9 40.4 42.7 44.9 47.1 49.1 53 57.5 61.5 65.5 68.5 72.2 85.4 101.2 114 121 123 132 140 148 152 157 187 193 240 282 329 568 786 818 879 45 65];end% Set up figure to receive data sets and fitsf_ =figure(f_);set(f_,'Units','Pixels','Position',[578 254 688 485]);% Line handles and text for the legend.legh_ = [];legt_ = {};% Limits of the x-axis.xlim_ = [Inf -Inf];% Axes for the plot.ax_ =set(ax_,'Units','normalized','OuterPosition',[0 0 1 1]);set(ax_,'Box','on');axes(ax_);% --- Plot data that was originally in data set &y vs. x&x = x(:);y = y(:);h_ = line(x,y,'Parent',ax_,'Color',[0. 0.666667],...
'LineStyle','none', 'LineWidth',1,...
'Marker','.', 'MarkerSize',12);xlim_(1) = min(xlim_(1),min(x));xlim_(2) = max(xlim_(2),max(x));legh_(end+1) = h_;legt_{end+1} = 'y vs. x';% Nudge axis limits beyond data limitsif all(isfinite(xlim_))
xlim_ = xlim_ + [-1 1] * 0.01 * diff(xlim_);
set(ax_,'XLim',xlim_)else
set(ax_, 'XLim',[-555.06, 999993]);end% --- Create fit &fit 1&ok_ = isfinite(x) & isfinite(y);if ~all( ok_ )
warning( 'GenerateMFile:IgnoringNansAndInfs',...
'Ignoring NaNs and Infs in data.' );endst_ = [35.622 5. ];ft_ = fittype('exp1');% Fit this model using new datacf_ = fit(x(ok_),y(ok_),ft_,'Startpoint',st_);% Alternatively uncomment the following lines to use coefficients from the% original fit. You can use this choice to plot the original fit against new% data.%
cv_ = { 23.728, 6.};%
cf_ = cfit(ft_,cv_{:});% Plot this fith_ = plot(cf_,'fit',0.95);set(h_(1),'Color',[1 0 0],...
'LineStyle','-', 'LineWidth',2,...
'Marker','none', 'MarkerSize',6);% Turn off legend created by plot method.% Store line handle and fit name for legend.legh_(end+1) = h_(1);legt_{end+1} = 'fit 1';% --- Finished fitting and plotting data. Clean up.% Display legendleginfo_ = {'Orientation', 'vertical', 'Location', 'NorthEast'};h_ = legend(ax_,legh_,legt_,leginfo_{:});set(h_,'Interpreter','none');% Remove labels from x- and y-axes.xlabel(ax_,'');ylabel(ax_,'');
提问者评价
问题已经解决了,谢谢
其他类似问题
按默认排序
其他1条回答
x=[98 103 117 142 186 232 291 363 435 526 615 61 16 45 50 26 29
65491];y=[0.3 0.5 0.7 1 1.3 1.7 2.1 2.5 3 3.5 4 6.3 9 11.7 14.5 17.2 19.8 22.5 25.2 27.8 30.5 33.1 35.5 37.9 40.4 42.7 44.9 47.1 49.1 53 57.5 61.5 65.5 68.5 72.2 85.4 101.2 114 121 123 132 140 148 152 157 187 193 240 282 329 568 786 818 879 45 65];%y=ae^(bx)z=log(y');m=[ones(60,1),x'];c=m\z;a=exp(c(1))b=c(2)a =8.5835b = 8.y=8.5835*exp(8.*x)
指数函数的相关知识
等待您来回答
下载知道APP
随时随地咨询
出门在外也不愁

我要回帖

更多关于 让人回答不出来的问题 的文章

 

随机推荐