Message Boards Message Boards

0
|
3614 Views
|
1 Reply
|
0 Total Likes
View groups...
Share
Share this post:

Find the region after using Minimize?

Posted 7 years ago

i use below command calculator mininum

Minimize[Sum[Abs[x - (3*k - 55)], {k, 1, 28}], x]

the answer is {588, {x -> -13}} mininum is right but x must be a region.how can i find the right region. thank

POSTED BY: dirac fang

Maybe so:

func = Sum[Abs[x - (3*k - 55)], {k, 1, 28}];
sol = Minimize[func, x]

Plot[Labeled[func, {"minimum"}, {Below}], {x, -20, 0}, 
PlotRange -> {Automatic, {580, 630}}, 
Epilog -> {Black, PointSize[0.02], 
Point[{x /. sol[[2, 1]], sol[[1]]}]}]

Plot

POSTED BY: Mariusz Iwaniuk
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract