matlab问题,高分求matlab求三元方程的极值。

形式如图片,这个式子应该有一个最大值,我就是想求得这个值是多少,是不是1,如果是如何得到的,最好能有一个程序求出。再写一下如果用xz-x+1>0与xz-y-1>0约束一下... 形式如图片,这个式子应该有一个最大值,我就是想求得这个值是多少,是不是1,如果是如何得到的,最好能有一个程序求出。
再写一下 如果用xz-x+1>0与xz-y-1>0约束一下,看是否有最值,我的想法是如果约束后那么(x-1)(1+y-xz)-(1+y)(x-1)+(xz)^2=xz(xz-x+1)>0,说明整个值是小于1的。
展开
 我来答
dbb627
2011-10-14 · TA获得超过1.2万个赞
知道大有可为答主
回答量:2127
采纳率:88%
帮助的人:1470万
展开全部
如果用xz-x+>0与xz-y-1>0约束一下,第一个约束不清晰
xz-x+>0====》xz-x+1>0

function aa
y=@(x)-(x(1)-1).*(1+x(2)-x(1).*x(3))./((1+x(2)).*(x(1)-1)-(x(1).*x(3)).^2);
[X,FVAL,EXITFLAG] =fmincon(y,[1.5 1 0.5],[],[],[],[],[1 0 0],[inf inf 1],@(x)con(x))

function [c,cq]=con(x)
c(1)=-x(1).*x(3)+x(1)-1;
c(2)=1+x(2)-x(1).*x(3);
cq=[];

Warning: Trust-region-reflective algorithm does not solve this type of problem, using
active-set algorithm. You could also try the interior-point or sqp algorithms: set the
Algorithm option to 'interior-point' or 'sqp' and rerun. For more help, see Choosing the
Algorithm in the documentation.
> In fmincon at 472
In AAAA at 3

Local minimum found that satisfies the constraints.

Optimization completed because the objective function is non-decreasing in
feasible directions, to within the default value of the function tolerance,
and constraints were satisfied to within the default value of the constraint tolerance.

<stopping criteria details>

Active inequalities (to within options.TolCon = 1e-006):
lower upper ineqlin ineqnonlin
1 3 1
2 2

X =

1 0 1

FVAL =

0

EXITFLAG =

1

这个式子的最大值,估计是趋于0的
(x-1)(1+y-xz)-(1+y)(x-1)+(xz)^2化简后为
xz(xz-x+1)没错
可是x>1 0<z<1
xz>0
(xz-x+1)=1-x(1-z)
这个值不确定
若1-z>1/x xz(xz-x+1)<0
若1-z=1/x xz(xz-x+1)=0
若1-z<1/x xz(xz-x+1)>0
百度网友2c32892
2011-10-13 · TA获得超过1555个赞
知道小有建树答主
回答量:704
采纳率:0%
帮助的人:352万
展开全部
这个式子没有上界。可以构造x,y,z在定义域里使分母是0。
比如x->3/2,y->1,z->2/3
已赞过 已踩过<
你对这个回答的评价是?
评论 收起
推荐律师服务: 若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询

为你推荐:

下载百度知道APP,抢鲜体验
使用百度知道APP,立即抢鲜体验。你的手机镜头里或许有别人想知道的答案。
扫描二维码下载
×

类别

我们会通过消息、邮箱等方式尽快将举报结果通知您。

说明

0/200

提交
取消

辅 助

模 式