Bug #1050

GModelSpectralLogParabola: Curvature can't get fit

Added by Mayer Michael over 10 years ago. Updated over 10 years ago.

Status:ClosedStart date:12/27/2013
Priority:NormalDue date:
Assigned To:Mayer Michael% Done:

100%

Category:-
Target version:00-08-00
Duration:

Description

In GModelSpectralLogParabola a bug occurred in the function update_eval_cache().
In line 963 of GModelSpectralLogParabola.cpp m_last_power is calculated to

m_last_exponent   = m_last_index + m_last_curvature * m_last_log_e_norm;
m_last_power      = std::pow(m_last_e_norm, m_last_index);

in the eval() and eval_gradient()-methods, the function value is then calculated by:
double value = m_norm.value() * m_last_power;
However, this only returns the power law value without any curvature. The correct line of code in line 963 should be:
m_last_power      = std::pow(m_last_e_norm, m_last_exponent);

Is it worth to create a feature branch for changing one word? :)


Recurrence

No recurrence.

History

#1 Updated by Knödlseder Jürgen over 10 years ago

  • Status changed from New to Feedback
  • Assigned To set to Mayer Michael
  • Target version set to 00-08-00
  • % Done changed from 0 to 100

Changed and merged into devel.

#2 Updated by Mayer Michael over 10 years ago

looks good. Curvature can be fit again.

#3 Updated by Knödlseder Jürgen over 10 years ago

  • Status changed from Feedback to Closed

Also available in: Atom PDF