Message Boards Message Boards

3
|
5836 Views
|
15 Replies
|
4 Total Likes
View groups...
Share
Share this post:

Numerical value of FoxH in solving trinomial equation?

Posted 2 years ago

There is a possible issue on solving the following trinomial equation

$$x^\alpha+x=y$$ for real $\alpha,x,y $. From Belkic [1], it is known that for $\alpha>1$ a solution is found using the confluent Fox-Wright function [[2]] as

$$x = y\cdot\,_{1}\Psi_{1}([1,\alpha];[2,\alpha-1];-y^{\alpha-1})=y\cdot H_{1,2}^{1,1}([(0,\alpha)];[(0,1),(-1,\alpha-1)];y^{\alpha-1})$$ where we have used the known relationship between the generalized Fox-Wright and Fox-H functions. (See Wikipedia Fox-Wright Function for example). $ $Translated to Wolfram language, this equation can be written as (I am not sure if it is lacking something, convergence, additional parameters for numerics perhaps)

N[y*FoxH[{{{0, \[Alpha]}}, {}}, {{{0, 1}}, {{-1, \[Alpha] - 1}}}, 
      y^(\[Alpha] - 1)] /. \[Alpha] -> 2 /. y -> 1]

trying compute it numerically, for either $\alpha=2, y=1$ (a quadratic equation) or any other numerical values, it does not return. Any help on this subject is welcome.

[1] Dževad Belkic."All the trinomial roots, their powers and logarithms from the Lambert series, Bell polynomials and Fox–Wright function: illustration for genome multiplicity in survival of irradiated cells". Journal of Mathematical Chemistry (2019) 57:59–106 https://doi.org/10.1007/s10910-018-0985-3

POSTED BY: Jorge Zuniga
15 Replies
Posted 2 years ago

Hi Brad,

Thanks a lot for your reply. Well, It is correct to say that, in a strict sense, FoxH and Wright's Psi are not hypergeometric functions in general (when any of the real parameters A, B is irrational in your example above). They are in fact "generalizations of" instead of "generalized" hypergeometric functions. However if all parameters A, B, are rationals there is always a p-recurrence and such functions are diferentially finite, being this the case of most applications. For this reason, I think, several researchers (me included), put pFq, MeijerG, Wright's Psi and FoxH functions under the same umbrella: Hypergeometric Functions. For instance this freely available work by Reiner Zorn (2020) "Hypergeometric Functions. Every Thing You Always Wanted to Know About Them (But Were Afraid to Ask)" provides the image below and contains relationships between these 4 functions with some rare FoxH's symbolic expressions and good references to the subject.

Links between pFq, MeijerG, Wright's Psi and FoxH functions (ibid. Reiner Zorn)

Getting back to trinomial equations, (a "simple" and popular application that let us to introduce Fox-Wright function). The starting point is section 4 of the following reference by Müller & Moskowitz (1995), "Reduction of a Class of Fox-Wright Psi Functions for Certain Rational Parameters" Computers Math. Applic. Vol. 30, No. 11, pp. 73-82, 1995, Pergamon.

For positive reals $x,y$ and $\alpha>1$ the principal branch of the inverse function of $y=y(x)$ (sometimes the unique real root $x$) in

$$x+y x^{\alpha}=1$$ is given by the confluent Fox-Wright function as

$$x=\,_1 \Psi_{1}[(1,\alpha);(2,\alpha -1);-y]$$ a special case of $\,_p \Psi_q$, the generalized Wright function that can be introduced as follows $$\,_p \Psi_q [(a_1,A_1),(a_2,A_2)...(a_p,A_p); (b_1,B_1),(b_2,B_2)...(b_q,B_q);\zeta]$$ with $A_j>0,\; B_k>0,\; j=1,..p,\; k=1,...q,\;$ and $ \,_p \Psi_q (\zeta)\; $ is given by the series

$$\,_p \Psi_q (\zeta)= \sum_{n=0} ^\infty \frac{\prod_{j=1}^{p}\Gamma(a_j+n\,A_j)}{\prod_{k=1}^{q}\Gamma(b_k+n\,B_k)} \cdot \frac{\zeta^n}{n!}$$

where numerator has no poles for $n\in\mathbb{N}_0\;$. For $\kappa=\sum B_k - \sum A_j + 1<0\;$ this series is divergent $\forall \;\zeta \neq 0$. It converges absolutely and uniformly to an entire function if either $\kappa>0\;$ or series terminates due to denominator poles for all $n > m\,$ being $\,_p \Psi_q (\zeta)\;$ a polynomial of degree $m\,$. If $\kappa=0$ it converges with radius of convergence $\rho=\prod |B_k|^{B_k}/\prod |A_j|^{A_j}\;$ and additionally it converges absolutely on the boundary $|\zeta|=\rho\;$ if $\kappa=0\land\Re( \sum a_j - \sum b_k )< \frac{p-q-1}{2}$

The following Mellin-Barnes integral gives a wider representation for $\,_p \Psi_q (\zeta)\;$ $$\,_p \Psi_q (\zeta) =\frac{1}{2\pi i}\int_{\mathcal{L}}\frac{\Gamma(s)\,\prod_{j=1}^{p}\Gamma(a_j-s\,A_j)}{\prod_{k=1}^{q}\Gamma(b_k-s\,B_k)}(-\zeta)^{-s}\mathcal{d}s$$

provided |arg( $\zeta\,$)| < $\pi-\epsilon\,$ with $\epsilon\,$ > 0 and $\mathcal{L}\;$ is any of the same three contours of Fox-H function $\mathcal{L_+}\;$, $\mathcal{L_-}\;$ and $\mathcal{L_{i\infty}}\;$ separating the integrand sequence of poles of $\Gamma(s)\;$ from the rest in this case. For contour $\mathcal{L_{i\infty}}\;$ the integral converges if $\epsilon=\frac{\kappa\pi}{2}\;$ and if $\kappa=0\;$ it provides an analytical continuation of $\,_p \Psi_q (\zeta)\;$ for $\zeta\in\mathbb{C}\;$ \ [ $\rho,\infty)$

From this point the connection to Fox-H is evident. In fact $$\,_p \Psi_q (\zeta) =H_{p,1+q}^{1,p}\,[(1-a_j,A_j)_{j=1}^{p};(0,1),(1-b_k,B_k)_{k=1}^{q};-\zeta\;]$$ $$\,_p \Psi_q (\zeta) =H_{1+q,p}^{p,1}\,[(1,1),(b_k,B_k)_{k=1}^{q};(a_j,A_j)_{j=1}^{p};-\zeta^{-1}\;]$$ where one of these converges and the other is an asymptotic expansion.

From the trinomial solution valid for $\alpha>1\;$ we have $$x=H_{1,2}^{1,1}\,[(0,\alpha);(0,1),(-1,\alpha-1);y\;]$$ $$x=H_{2,1}^{1,1}\,[(1,1),(2,\alpha-1);(1,\alpha);y^{-1}\;]$$ For $0<\alpha<1\;$ and $\beta=\alpha^{-1}\;$ the trinomial equation can be set as $$1-x+[(1-x)/y]^{\beta}=1\;$$ giving $$x=1-H_{1,2}^{1,1}\,[(0,\beta);(0,1),(-1,\beta-1);y^{-\beta}\;]$$ $$x=1-H_{2,1}^{1,1}\,[(1,1),(2,\beta-1);(1,\beta);y^{\beta}\;]$$ Note that if the trinomial equation is set in this form $$y=c\,x+x^\alpha$$ a variation of such solutions provides the inverse function.

For $\alpha > 1\;$ $$x=\frac{y}{c}H_{1,2}^{1,1}\,[(0,\alpha);(0,1),(-1,\alpha-1);(y/c)^{\alpha}/y\;]$$ $$x=\frac{y}{c}H_{2,1}^{1,1}\,[(1,1),(2,\alpha-1);(1,\alpha);y(y/c)^{-\alpha}\;]$$ For $0<\alpha<1\;$ and $\beta=\alpha^{-1}\;$ the trinomial equation is set as $$1-\frac{cx}{y}+cy^{\beta-1}(1-\frac{cx}{y})^\beta=1$$ giving $$x=\frac{y}{c}(1-H_{1,2}^{1,1}\,[(0,\beta);(0,1),(-1,\beta-1);c\,y^{\beta-1}\;])$$ $$x=\frac{y}{c}(1-H_{2,1}^{1,1}\,[(1,1),(2,\beta-1);(1,\beta);y^{-\beta+1}/c\;])$$

From some failed attempts with these formulae it is seen that some basic features of FoxH (in Mathematica v.13) has not been developed. Trinomial equations are very common in scientific practice, it should be very useful to build these direct solutions inside Mathematica (for both symbolics and numerics) now that FoxH functionalities are being expanded.

My Best Regards

Jorge Zuniga

POSTED BY: Jorge Zuniga

Thanks for sending that paper, it looks really interesting! According to Stephen Wolfram's Blog:

And in Version 13.0 we’re finally done! All the functions in Abramowitz & Stegun are now fully computable in the Wolfram Language.

It looks like you have found a special function, which isn't in A&S. Depending on your constraints for the exponent (as discussed in your source) the Lambert W Function might work. If you have non-integer exponents, then you may need to sum using the Gamma Function, which should also be somewhere in A&S.

The real problem implementing such functions is that, as presented, they may not be well-defined. For example, wikipedia compares your Fox functions with Meijer G and Hypergeometric F,as does the source article. Like newly added Heun G--which solves some of the differential equations in my recent dissertation--Meijer G and Hypergeometric F. are both differentiably finite, meaning that they satisfy (relatively) simple ordinary differential equations. I don't know, but my guess is that your two Fox functions, as being essentially inversive, are more like LambertW, whose defining equation contains a tricky non-linear term.

The Bell polynomials are very interesting from a combinatorial perspective, and powerful technology if utilized correctly. However, most natural scientific researchers ultimately have to decide pragmatically against too much formalism in order to get ahead of schedule on important applications and "neat examples".

Hope that helps.

--Brad

POSTED BY: Brad Klee
Posted 2 years ago

Hi Brad,

Thanks a lot for your answer, for non-integer exponents a trinomial equation can be solved in terms of confluent Fox-Wright function, that is a simple series generalization of 1F1 hypergeometric function adding two sets more of positive parameters. It plays a similar role as Lambert W to solve trascendent equations having logarithm and linear terms (in this case unknown variable with non-integer -real or complex- power exponents and linear terms) . Fox-Wright $\,_{p}\Psi_{q}$ function is not new, it is a classical function. Together with Fox-H, MeijerG, and pFq are the four classical generalized (multi-parameter) univariate hypergeometric functions.

Now that Mathematica has implemented Fox-H, the generalized Fox Wright $\,_{p}\Psi_{q}$ can also be easily implemented since it is a special case of that function. It is also a "superfunction" but it is much simpler, since , besides a Mellin-Barnes integral, it has also a series form much like pFq, it does not depends on m, n and the confusing splitting brackets that these indices produce on FoxH.

I do not know what happens with FoxH in this particular case but roots of Trinomial equations with non integer (real) exponents are excellent test probes to evaluate the numerical performance of such functions. I posted in StackExchange MO and StackExchange Mathematica Forums math formulae for the root of trinomial equations based on these higher hypergeometric functions informing that Wolfram had implemented FoxH function since v12.3

At last, I would like if you can address this reply to Mr. Tigran Ishkhanyan. Perhaps he can explain the behavior of FoxH in this particular case.

Thanks a lot for your reply,

Jorge

POSTED BY: Jorge Zuniga

Together with Fox-H, MeijerG, and pFq are the four classical generalized (multi-parameter) univariate hypergeometric functions.

That is what I'm willing to debate, whether or not even Fox-Wright belongs in the hypergeometric class. Refer back to your preferred reference, equations 13.5 and 13.7. The analogy is based on similarity between one particular expansion, not upon fundamental definitions. For example compare the following:

FullSimplify[Times[Gamma[a + n ]/Gamma[b + n],
  Gamma[b + n + 1]/Gamma[a + n + 1]]]
Out[]=(b+n)/(a+n)

FullSimplify[Times[Gamma[a + n A ]/Gamma[b + n B],
  Gamma[b + (n + 1) B]/Gamma[a + (n + 1) A]]]
Out[]=(Gamma[a + A n] Gamma[b + B + B n])/(
Gamma[a + A + A n] Gamma[b + B n])

Is the second expression the result of incomplete programming of FullSimplify? Or does it refuse to simplify to a ratio of $n$-polynomials because such a simplification does not exist? You should try and answer this question by analyzing the coefficient ratio. The term Hypergeometric refers to those deferentially finite functions whose p-recurrences take a most simple (but not necessarily trivial) form. As an academic researcher, you need to understand what that statement means in terms of the calls written above.

However, it looks like you beat me to finding out about inclusion of FoxH. Now here is something else interesting I noticed in theory. Under "neat examples" there is a table of closed forms, all of which I think are Differentiably finite. This table caused me to doubt my earlier conjecture, but maybe not. It could be a case of introducing a simplicity bias. For example, elliptic functions are highly non-linear, but have a harmonic limit. Something similar could be happening here.

Comparing those examples with your posted code, I thought that your list nesting looks correct, but checking the series expansions nothing happened. If you think the series definition will work, it should be easy for you to program yourself. That's what I was getting at in my previous thread.

If you're not worried about getting results right away, you could try to perform some calculus on Mellin-Barnes integrals. However, this is not really recommendable unless you've already mastered a range of easy examples. For example here's a nice demo on relatively easy integrals.

POSTED BY: Brad Klee

I have code that FoxH function can be computed by Meijer's G Function, but I don't remember from what web site I borrowed.

POSTED BY: Mariusz Iwaniuk

Hi Mariusz,

Do you have an opinion whether the Fox Wright or Fox H functions are Differentiably Finite?

I'm tuck on trying to answer this question before rushing on to calculate values according to some theory I don't have time to fully understand.

The code looks promising. Funny example calculating the Golden Ratio by the most complicated means possible! I ran another simple test, and found the implementation does pretty well on integer coefficients:

dat1 = With[{exp = #}, FOXH[
      {{{0, exp}}, {}}, {{{0, 1}}, {{-1, exp - 1}}}, 1]
     ] & /@ Range[2, 6];
Print[]=G,G,G...

dat2 = Flatten[Select[Cases[x /. NSolve[x^(#) + x == 1, x],
      _Real], # > 0 &] & /@ Range[2, 6]];

Union[Chop[dat1 - dat2]]
Out[]={0}

All values computed using Meijer G. For decimals the method was unpredictable and I found at least one suspicious output, probably wrong. There's enough error room in these tests for non-D-Finite hypothesis to remain plausible.

POSTED BY: Brad Klee

However if all parameters A, B, are rationals there is always a p-recurrence and such functions are diferentiably finite, being this the case of most applications.

Do you have a constructive, computable proof? If what you say is true, it should be possible to write an algorithm that produces an ordinary differential equation or it's associated p-recurrence. This is a useful ask, because p-recurrences + boundary conditions usually make for fast calculations (For example, ch. 4 of my dissertation). I think it is a selling point that some root solving calls could be optimized.

The two documents you sent look useful, and I like the way that Reiner Zorn has set up his manual page. One suggestion, possibly have a convention for using darker colors, because the lime green is difficult to read.

The black and white document has some relevant definitions between $_1\Psi_1$ / $_pF_q$, eq. 2.4 and eq. 3.4. If the math is correct, then $_1\Psi_1$ does look to be easily computable for integer or rational parameter choice. However I also note that larger integers, numerators, and denominators lead to more complex defining data. What is going to happen if $A=2343234/1111111111111$?

So I think this does prove my intuition. Irrational choice of $A$ will have a series of rational approximants in which the length of the associated differential equation is strictly increasing (assuming no unexpected cancellations), but ordinary differential equations have only finitely many terms, a proof by contradiction.

POSTED BY: Brad Klee
Posted 2 years ago

Hi Brad,

Concerning FoxH or Fox-Wright, it is known that just when all parameters $A_j\;$and $B_k\;$ are rationals both functions can be converted always to (most times non-trivial) finite linear combinations of Meijer G and sometimes also to pFq (A,B integers). Since Meijer G and pFq are true hypergeometric functions they have p-recurrences and are diferentiably finite.

For generalized FoxH and $\,_p \Psi_q$ I have read it with some of the reduction formulae to Meijer G, in some of the works and books by Kilbas, Saxena, Mathai, Haubold, Karp, Kiryakova, if I remember.

For trinomial equations reducible to rational exponents $\alpha=\frac{m}{n}$ of this kind $y=x^m+c\,x^n,\;m,n\;$ integers $\,_1 \Psi_1\;$solutions based on pFq finite sums or Meijer G relationships is found in Müller & Moskowitz (1995) paper I uploaded in my previous reply. Look there at Eqs 3.3, 3.5, 3.6 and 3.7 for finite sums of pFq or 5.1 and 5.2 for Meijer G.

A good algorithm strategy for FoxH (and Fox-Wright) is to separate the symbolic case from numerical cases. For irrational parameters and rational parameters A,B having great irreducible denominators as you point out, I think that there is not much to do with symbolics even if you have huge computing resources. Numerics on the other side could be approached in an unified way through quadratures.

For the trinomial equation having A,B irrationals or rationals with great irreducible denominators, a good numeric root finder can solve it.

My Best,

Jorge

POSTED BY: Jorge Zuniga
Posted 2 years ago

Do you have a constructive, computable proof?

About this question. I think this path provides a constructive proof to transform Fox-H into Meijer G when all $A_j\;$ and $B_k\;$ are rationals

Compute $C = \;$LCM[ All denominators of $A_j\;$,$B_k\;$ ]

Write $A_j\;= n_j / C,\;B_k\;=n_k/C,\;$

Use Legendre multiplication formula for Gamma functions enter image description here

in the Fox-H Mellin-Barnes integrand $c\;$ is any of $a_j,\;1-a_j,\;b_k,\;1-b_k\;$

$\gamma\;$ is any of $n_j,\;n_k,\;$

$ z\;$ is either $+s/C\;$ or $-s/C\;$ being $s\;$ the integration variable

Change the integration variable to a new one $\sigma=s/C\;$

Check that the integration contour separates numerator poles properly.

Voilá. We have got a Meijer G function. All factors A,B are now +1 or -1

My Best

Jorge

POSTED BY: Jorge Zuniga
Posted 2 years ago

Hi Brad,

I have lifted up a constructive proof in the attached document. It uses Meijer G equivalence for FoxH whenever all scaling parameters are rationals.

Yours Truly

Attachments:
POSTED BY: Jorge Zuniga

I'm not sure what else we can do at the moment, especially with public opinions turning against calculus, as in California. However, if you are already putting formulas into latex, then you can contribute to the effort started by Zorn. Here it is again:

https://iffgit.fz-juelich.de/zorn/hypergeom/-/blob/master/Hypergeom.pdf

I think the idea is great to have multiple authors and correspondents working together somehow. Obviously a scientific community can not just be one original poster having a discussion with himself! Good Luck!

POSTED BY: Brad Klee
Posted 2 years ago

I'm not sure what else we can do at the moment...

Easy, check if Wolfram's FoxH[] can work for some simple combination of parameters. Trinomial equations are good to start with. Verify the golden ratio case that initiated this discussion or any other similar case.

Mariusz gave a code that works fine using Meijer's G. It is widely acknowledged that Wolfram´s Meijer G implementation works excellent and it is indeed very robust for both symbolics and numerics.

So it would be natural, to solve such situations jumping from FoxH to Meijer's G whenever it is possible, and this occurs always if all scaling parameters are rationals, being this a very frequent case. As we have said, this works just if denominators are not great and irreducible, but what is great or irreducible?, definition depends on computing resources. On the other side there is a huge quantity of common cases, that are not irreducible and software should solve them, for instance this simple golden ratio quadratic equation.

Brad, in my note FoxH.pdf equations H20, H21 & H22 provide the direct general conversion from FoxH to Meijer G.

what else we can do

Pass it to the Development Team to code it inside FoxH. I am absolutely sure that issues like this golden ratio unevaluated and other similar cases will disappear completely.

Have a nice Time,

Jorge

POSTED BY: Updating Name

"Do you have an opinion whether the Fox Wright or Fox H functions are Differentiably Finite?"

I don't know.

I found in WOLFRAM FUNCTION REPOSITORY a very usefull function FoxHToMeijerG.

See here.

Regards.

POSTED BY: Mariusz Iwaniuk

@Mariusz, thanks for finding that. Author Jan Mangdalan is building a prolific reputation for himself. Even good programming can not circumvent difficulties in the theory itself, for example:

AFoxHToMeijerG[
 FoxH[{{{1/2, 2343234/1111111111111}, {1/2, 
     1/4}}, {}}, {{{(1/2)/5, (1/2)/4}}, {{0, 1}}}, z]]

General::nomem: The current computation was aborted because 
there was insufficient memory available to complete the computation.

Throw::sysexc: Uncaught SystemException returned to top level. 
Can be caught with ..., _SystemException].

That's not the original programmer's fault, so don't blame Jan!

I'm not sure if there are still issues here, but if so tickets can be submitted through support page. I think that Computer Calculus will always be a priority at Woflram Research, unfortunately, if the basing is run out of US, given the situation with a new wave of "math reform", especially in California, it may be a low priority (especially relative to, say, what's going on in France and / or Germany).

POSTED BY: Brad Klee
Posted 2 years ago

Thank you Mariusz.

I appreciate it. This is very useful for me. I will check it against the code I'm programming making use of the formulae I've found.

Thanks a lot again,

Jorge

.

POSTED BY: Jorge Zuniga
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard

Group Abstract Group Abstract