**Description of the
method:**

**The software is designed to find a
model-independent (regularised) flux of either photons or electrons using RHESSI
count flux.**

**FROM COUNTS TO ELECTRONS:
**

**The bremsstrahlung
produced photon flux spectrum I(eps) [ photons/sec/cm^2/keV]
at the Earth is given by the integral
I(eps)=
1/(4*!Pi*1AU^2)*\int_{eps}^{infinity}S(eps,e)F(e)de <
/STRONG>
**

**
I=S*F**

**where F(e) =
<V*n*Fe(e)>, F(e) - density and volume weighted mean electron flux
spectrum
, [ electrons/sec/cm^2/keV], n - average
number density of the surrounding plasma
, [cm^-3],
V - average emitting volume ,
[cm^3], S(eps,e) -
differential in photon energy bremsstrahlung cross-section
, [cm^2/keV], Fe(e) - mean electron flux spectrum
[electrons/sec/cm^2/keV]**

**The corresponding count flux spectrum in the X-ray
detectors C(eps)
[ counts/sec/cm^2/keV] can be
written in matrix form**

**
C = A*F, where A =
DRM*S < /STRONG>
**

** where we know C and A and
want to find F . This problem is ill-conditioned and regularision (additional
constraints) should be applied.**

** The code finds the solution for
the problem as a function of lambda:**

**
||A*F-C||^2+lambda*||L*(F-F0 )||^2=min<
/STRONG>
**

** where L - constraint matrix, F0 - thin-target fit from
SPEX/OSPEX, lambda - regularisation parameter found using discrepancy
principle:**

**
||A*F(lambda)-C||=reg_tweak*||dC||**

** where dC is 1 sigma
uncertanty on count flux, [ counts/sec/cm^2/keV]**

**FROM COUNTS TO
PHOTONS**

**The observed count flux spectrum in the X-ray
detectors C
(eps) [counts/sec/cm^2/keV] can be written in matrix
form**

** C = DRM*
F**

**where DRM - dynamic response matrix of
instrument. We know C and DRM and want to find a photon flux F
[ counts/sec/cm^2/keV].**

**This problem is
ill-conditioned and regularization (additional constraints) should be
applied.The code finds the solution for the problem as a
function of lambda**

** ||DRM*F-C||^2+lambda*||L*(F-F0)||^2= min**

**where ||...|| - L2 norm, L-
constraint matrix, F0 - a model of photon
spectrum from SPEX/OSPEX, lambda -
regularisation parameter found using descripancy principle:**

** ||A*F(lambda)-C||=reg_tweak*||dC||**

**where dC is 1 sigma uncertainty on
count flux, [ counts/sec/cm^2/keV]**

**Last updated 11/11/2005 **