MathGroup Archive 2008

[Date Index] [Thread Index] [Author Index]

Search the Archive

RE: Re: (genetic algorithms) Re: How to find the Max of a Piecewise function

  • To: mathgroup at smc.vnet.net
  • Subject: [mg90503] RE: [mg90459] Re: [mg90447] (genetic algorithms) Re: How to find the Max of a Piecewise function
  • From: "Tony Harker" <a.harker at ucl.ac.uk>
  • Date: Fri, 11 Jul 2008 02:03:01 -0400 (EDT)

 
 Have you tried "Illustrating Evolutionary Computation with Mathematica" (in
the Morgan Kaufmann series in Artificial Intelligence) by Christian Jacob?
It's quite readable, and has lots of coded examples (not just of genetic
algorithms).

   Tony

]-> -----Original Message-----
]-> From: Francisco Gutierrez [mailto:fgutiers2002 at yahoo.com] 
]-> Sent: 10 July 2008 11:34
]-> To: mathgroup at smc.vnet.net
]-> Subject: [mg90459] Re: [mg90447] Re: How to find the Max of 
]-> a Piecewise function
]-> 
]-> Friends:
]-> What are the best references you know for programming 
]-> genetic algorithms in Mathematica?
]-> Thanks
]-> Francisco
]-> 
]-> --- On Wed, 7/9/08, Jean-Marc Gulliet 
]-> <jeanmarc.gulliet at gmail.com> wrote:
]-> 
]-> From: Jean-Marc Gulliet <jeanmarc.gulliet at gmail.com>
]-> Subject: [mg90459] [mg90447] Re: How to find the Max of a 
]-> Piecewise function
]-> To: mathgroup at smc.vnet.net
]-> Date: Wednesday, July 9, 2008, 3:56 AM
]-> 
]-> Aaron Fude wrote:
]-> 
]-> > If f is deined according to
]-> > 
]-> > f[x_] := Piecewise[{{1, x < 1}, {2, x > 1}}]
]-> > 
]-> > then
]-> > 
]-> > Max[f[Range[0, 1, .001]]]
]-> > 
]-> > does not yield the desired result. What's the proper way 
]-> to approach 
]-> > this?
]-> 
]->      f[x_] := Piecewise[{{1, x < 1}, {2, x > 1}}]
]-> 
]->      SetAttributes[f, Listable]
]-> 
]->      Max[f[Range[0, 1, .001]]]
]-> 
]->      1
]-> 
]-> Regards,
]-> -- Jean-Marc
]-> 
]-> 
]-> 
]-> 



  • Prev by Date: Writing to an External file, ie .txt
  • Next by Date: Re: Almost symbolic computations (?)
  • Previous by thread: Re: Writing to an External file, ie .txt
  • Next by thread: Stop iteration iconstructing Table