[mesa-users] The choice of interpolant in interp_1d_lib
Ehsan Moravveji
e.moravveji at gmail.com
Fri Nov 28 12:10:05 EST 2014
Thanks Bill for your reply.
Among the whole list of available interpolants, interp_m3 refuses to build, interp_m3a, interp_m3b and interp_meq all fail to interpolate (without any clear error message).
Only interp_pm and interpolate_vector_pm() work, where both of them give identically awful result in a sense that they fail to preserve the shape of the kappa profile. Please take a look at the attached figure. Before interpolation nz=984 and after interpolation it is 1035. I use s% m(1:nz) for my interpolation, and I do it in one shot:
call interpolate_vector(n_old, m_old, n_new, m_new, y_old, y_new, interp_pm, &
pm_work_size, work, ‘do interpolate', ierr)
Do I instead have to walk through the mesh grid, and interpolate locally? interp_4_to_1() perhaps?
The first challenge for me is to get the interpolation work. The question of the choice of interpolant comes after.
Best regards,
Ehsan
On Nov 28, 2014, at 5:38 PM, Bill Paxton <paxton at kitp.ucsb.edu> wrote:
> Hi Ehsan,
>
> All of those options are doing cubic interpolation, so on a monotonic data set they should be giving essentially the same results.
> They differ in how the deal with non-monotonicity. You should makes plots using all of them and decide what you like.
>
> -B
>
>
>
> On Nov 28, 2014, at 8:27 AM, Ehsan Moravveji wrote:
>
>> Dear all,
>> I would like to interpolate some of the profiles in MESA on a new mass grid. The reason is that from one timestep to the next, the s% nz does not necessarily stay constant, but goes up and down. For that, I looked into interp_1d_lib public module to check what is on the menu!
>> The interpolate_vector() there can fully serve me, since I need to interpolate a 1d vector. However, there are multiple choices of the interpolant, like:
>> - interp_pm
>> - interp_m3
>> - interp_m3a
>> - interp_m3b
>> - interp_m3q
>>
>> To make the best decision, I would like to know which of these are more suitable for monotonically decreasing profiles like temperature, and which are better suited for bumpy profiles like eps_nuc, opacity etc.
>>
>> I would be grateful to receive your feedbacks.
>>
>> Have a nice weekend,
>> Ehsan.
>> ------------------------------------------------------------------------------
>> Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
>> from Actuate! Instantly Supercharge Your Business Reports and Dashboards
>> with Interactivity, Sharing, Native Excel Exports, App Integration & more
>> Get technology previously reserved for billion-dollar corporations, FREE
>> http://pubads.g.doubleclick.net/gampad/clk?id=157005751&iu=/4140/ostg.clktrk
>> _______________________________________________
>> mesa-users mailing list
>> mesa-users at lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/mesa-users
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.mesastar.org/pipermail/mesa-users/attachments/20141128/b19c83ac/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: comp-interp-before-after.png
Type: image/png
Size: 49253 bytes
Desc: not available
URL: <https://lists.mesastar.org/pipermail/mesa-users/attachments/20141128/b19c83ac/attachment.png>
More information about the Mesa-users
mailing list