comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: IDL fitting of piecewise continuous function
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: IDL fitting of piecewise continuous function [message #76115 is a reply to message #76114] Tue, 17 May 2011 12:26 Go to previous messageGo to previous message
Sasha Singh is currently offline  Sasha Singh
Messages: 13
Registered: November 2010
Junior Member
Thanks Jeremy,

I did look look at MPFIT. I am confused as to how do I define the
constraints x<x_m and x > x_m in the function. Sorry I am quite new to
IDL.

Sasha

On May 17, 3:21 pm, Jeremy Bailin <astroco...@gmail.com> wrote:
> Craigh Markwardt's MPFIT (and its varients) is most people's preferred fitting routine:
>
> http://www.physics.wisc.edu/~craigm/idl/fitting.html
>
> You define your own function to feed in, so it can have whatever behaviour you want. To ensure continuity, I would recommend re-parametrizing the functional form so that it is continuous by definition. In this, case, A and B aren't actually independent, so calculate B in terms of A by setting them equal at x=x_m, which gives
> B = A x_m^(3/2)
>
> So you're actually fitting:
>
> f(x) = A x_m^(1/2) x^(1/2)   x < x_m
>   A x_m^(3/2) x^(-1)   x > x_m
>
> -Jeremy.
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: IDL fitting of piecewise continuous function
Next Topic: HISTOGRAM, binsize, and max

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 19:20:23 PDT 2025

Total time taken to generate the page: 0.00403 seconds