MathGroup Archive 1995

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

Search the Archive

Piecewise function generator


   I want to generate a piecewise continuous linear function by giving a 
function, call it F, a list of {x,y} values defining the corners of the 
function.  I can't seem to do it.  Does anyone out there have a quick way 
of doing it?
   
   pts={{20,0.08},{50,0.8},{250,0.8},{5000,0.004}}
   
   F[pts_] := ????
   
   F[pts]
   
   Out:
   {(0.72 f-12)/30 /; 20<=f<=50,
   ...}
   
   Thanks in advance,
   Daryl



  • Prev by Date: Help: General Protection Fault caused by Mathematica for Windows
  • Next by Date: Books on Mma graphics
  • Previous by thread: Graphics Blank Margin
  • Next by thread: Re: Piecewise function generator