Serving the Quantitative Finance Community

 
User avatar
Amin
Topic Author
Posts: 2309
Joined: July 14th, 2002, 3:00 am

Re: Breakthrough in the theory of stochastic differential equations and their simulation

May 29th, 2023, 1:32 pm

Friends, I want to try my best to get a research position at some good Chinese university since I also want to be free from mind control forever. Though I am truly against the evil people of Pentagon, I do not make a difference between good people anywhere in the world. I believe that all human beings are equal and should learn to respect each other and live together amicably. 
I am very proud of the fact that whatever little research I did, I shared it with other people without any reservation. My psychology was shaped by good old Indian songs of fifties and sixties about love and respect for other human beings despite hardships that I used to listen in my car while going to my office everyday more than six or seven years ago. Though most people were not good to me, I had a desire to do something good in this world and a lot of this desire was a result of old classic Indian music that I really liked.
Now that I plan to go to China and re-start my research there, I do not want to back down on ideals I tried to follow. After trying to be good for so many years, I do not want to turn negative in any way. I want to make sure that I freely continue to distribute my research in coming years even after I successfully settle in China. I thoroughly respect Chinese people and would love to work and research together with them, I am not going to be in any block against anyone, and my only block is humanity. 
I want to tell American friends who always supported me that I have absolutely no intention of participating in anything anti-American though I would always criticize inhuman animal practices of hardliners in Pentagon due to gross human suffering they cause. But I will never do anything that validates the anti-Muslim narrative or intentions of hardliners in Pentagon. And I will always be thankful to American or European friends who tried to help me since I would never have been able to make it to this point without their support. And I hope that I will never let good people down who supported me.
You think life is a secret, Life is only love of flying, It has seen many ups and downs, But it likes travel more than the destination. Allama Iqbal
 
User avatar
Amin
Topic Author
Posts: 2309
Joined: July 14th, 2002, 3:00 am

Re: Breakthrough in the theory of stochastic differential equations and their simulation

May 30th, 2023, 9:34 pm

Friends, I skimmed through the thread today and made note of the important posts. Here I am describing various research themes that I followed over the years and  post numbers of the most relevant associated posts.

1. Monte Carlo simulation of Stochastic Differential Equations.

In order to simulate an SDE with variable drift terms and variable volatility term, we apply Ito formula on variable drift and variable volatility terms and find  an equivalent expression for each of the variable terms comprising a stochastic integral with constant integrand first term evaluated at initial value and several variable integrand terms under iterated stochastic integrals. We again apply Ito formula on variable integrand terms under the stochastic integral sign  to convert them into constant integrand terms evaluated at initial values and further variable integrand terms under higher order iterated integrals. After N repeated application of the above procedure, we obtain an  Nth order discretization of the SDE  comprising a large number of constant integrand terms evaluated at initial values and we also get some N+1 order terms with variable integrands under the iterated integrals. We can easily evaluate the all the constant integrand terms up to order N under iterated stochastic integral signs and neglect the rest N+1 order variable integrand  terms. All the constant integrand stochastic integrals can be analytically solved using hermite polynomials. This process can be repeatedly carried out to achieve high degree of accuracy in monte carlo simulations of the SDEs. Since number of terms involved in higher order expansions increases very fast and cannot be easily done with hand, I distributed an algorithm coded in matlab that calculated all the stochastic integrals and their coefficients from constant integrand terms involved and these coefficients are later used in higher order simulations of  Stochastic differential equations.

In post 37 below, I described how to apply Ito change of variable formula on drift and volatility terms of the SDE and then substitute them in the original integral representation of the SDE. I also explained how to repeatedly apply the Ito Change of variable formula on variable integrand terms for higher order simulation of the SDEs. This post 37 was written on Monday, May 02, 2016 1:43 pm. I think due to forum adjustments, proper formatting of this post is lost but you can still properly read the equations in which Ito change of variable formula is repeatedly applied.
https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=30#p782234

I later stopped working on SDEs and applied the same idea on solution of ODEs. I started working on SDEs again after quite some time and then wrote another post describing how to expand the integral solution of an SDE to higher order by repeatedly applying Ito Change of variable formula. This post 564 is similar to post 37. Post 564 was written on Thu Nov 23, 2017 10:48 am.
https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=555#p816432

When I wrote the above post, I had only successfully expanded the SDE into constant integrand iterated stochastic integrals but I still had not given the proper analytic formulas for the solution of iterated stochastic integrals.
I was only able to solve for various iterated stochastic integrals whose integrands were constant values evaluated at initial starting time. I wrote this post 690 written on Thu May 10, 2018 10:38 pm where I gave analytic expressions for solution of stochastic integrals
https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=675#p827224

One day later I, latexed the formulas given in post 690 and wrote them again. This was done in post 693 written on Fri May 11, 2018 6:08 pm
https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=690#p827246

Here in post 736, I presented a program based on above research that would evolve density of an SDE without pseudo random numbers using a non-branching tree for underlying normal driving density. This program would automatically do repeated Taylor expansions of SDEs with two drift terms and one volatility term and would also automatically solve for all stochastic integrals involved. This program had exact behaviour for one evolution/simulation  step of the non-branching tree but its multi-step behaviour with deterministic non-branching tree was flawed . As it turns out when we simulate with pseudo-random numbers, if the SDE does not have explicit dependence on time, we always simulate the SDE at the start of interval as if we are starting from time zero. So while multi-step simulation algorithm was not good for analytic non-branching density tree, its one-step version was perfect, precise and ideal for Monte Carlo simulations with pseudo-random numbers. However, it was only a few weeks later, when I started using the one step simulation scheme in monte carlo simulations. Again the algorithm and its explanation were given in post 736 written on Mon Jul 02, 2018 10:56 am here.
https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=735#p830547

It was the algorithm in above post that a lot of friends copied from my thread and distributed around. It would discretize for any arbitrary SDE with two drift terms and one volatility term without explicit time dependence in the SDE.
I later used the algorithm given in post # 736 for monte carlo simulations for the first time in a matlab program distributed in post # 773, written on Sun Nov 04, 2018 6:34 pm given here: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=765#p837313
In the above post, I simulated both bessel process version of the SDE and original coordinates version of the SDE with monte carlo simulations employing pseudo random numbers.
Here in post 891, I presented the same monte carlo simulation algorithm but all the binomial loops have been removed and all the various integrand terms are directly written as a summation. It is the same monte carlo algorithm as old but all the terms in expansion are written directly without any looping. Here is the link to post  891  written on Sat Mar 14, 2020 5:54 pm : https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=885#p855539
Here is posts 892 and 893, I have earlier collected all my posts written about monte carlo simulations and associated matlab programs.
Post 892:  https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=885#p855649
Post 893: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=885#p855653

Here in post 1172 and 1173, I presented ideas about expansion of high dimensional monte carlo simulations like we have for interest rate derivatives and equity baskets.
Post 1172: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1170#p866762
Post 1173: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1170#p866774

Here in post 1213, I have presented a higher order monte carlo program for very general system of correlated system of asset and SV SDEs.
Asset SDE is of the form
[$]\, dX(t)=(a X(t)^{\alpha_1} + b X(t)^{\alpha_2}) dt + \sqrt{(1-\rho^2)} \sigma_1 \, V(t)^{\gamma_V} \, X(t)^{\gamma_X} dZ1(t) + \rho \sigma_1 V(t)^{\gamma_V} X(t)^{\gamma_X} dZ2(t)[$]
while volatility SDE is of the form
[$]dV(t)=(\mu_1 V(t)^{\beta_1} + \mu_2 \, V(t)^{\beta_2}) \, dt + \, \sigma_0 \, V(t)^{\gamma} dZ2(t)[$]
Here is the higher order monte carlo simulation program for above general correlated system of SDEs written on Fri Aug 13, 2021 1:04 pm. Here is the address of post 1213:  https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1200#p867829

2. Initial Value problems of first and higher order ODEs and systems of ODEs.

You can read all about my work here: https://papers.ssrn.com/sol3/papers.cfm?abstract_id=2872598

Interestingly, I used the same basic ideas for solution of ODEs and SDEs. The common original idea involves taking iterated integrals of higher derivatives and then solve for stochastic integrals (in case of SDEs) and deterministic integrals (in case of ODEs). These integrals can easily be solved since their integrand is a constant value evaluated at initial time. 

I will be making a separate post about my research work during last two years.
You think life is a secret, Life is only love of flying, It has seen many ups and downs, But it likes travel more than the destination. Allama Iqbal
 
User avatar
Amin
Topic Author
Posts: 2309
Joined: July 14th, 2002, 3:00 am

Re: Breakthrough in the theory of stochastic differential equations and their simulation

May 31st, 2023, 9:49 am

Friends, in this post I am writing some notes that would be helpful when friends download and understand monte carlo SDE simulation programs in previous post.
I presented solution of stochastic integrals in post 690 and 693 here: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=690#p827246
I have not presented the proof of those formulas but I will give friends an idea how to solve those iterated stochastic integrals. It is very embarrassing to admit but when I started out to solve for those integrals, I very naively thought that in iterated stochastic integrals with repeated dz(t) and dt, these integrals commute. Only later when I simulated the lognormal and other SDEs to higher order that I realized that these integrals do not commute.
Here in this post 689, I told friends that I had made an error and my earlier thoughts that stochastic integrals commute and resulting calculations were wrong.
https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=675#p826905
Then I went to blackboard again and found out that my method to evaluate dz integrals with Ito-isometry like formula with variances was very right but stochastic integrals that ended with dt were wrong.
I wrote this post four days later and gave the correct formulas. Post 690 here: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=675#p827224
For reference, here is the original post # 32 where I claimed that stochastic integrals should commute. The method suggested in that post only works for dz-integrals and not on dt-integrals. Here is the original post: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=30#p782089
Sometime after writing that post, I started working on ODEs and stopped the work on SDEs which I restarted later. I was forcefully detained several times in that duration.
Those dt integrals that could not be directly evaluated had to be first converted to dz integrals as below and then we could use ito isometry like formulas to solve for them and get exact results.
Then just like we approach    the formulas [$]\int_0^{t} z(s) \, ds \, =\,\int_0^{t} \, d[\, s \, z]\, - \int_0^{t} \, s \, dz(s) \, [$] 
I applied that to hermite polynomials as

[$]\, \int_0^{t} H_n(z(s)) \, ds \, =\,\int_0^{t} \, d[\, s \, H_n(z(s))]\, - \int_0^{t} \, s \, dH_n(z(s)) \, [$]
where second integral on RHS can be solved with ito-isometry like formula. So I had to replace dt integrals with [$]dz(t)][$] or [$]dH_n(z(t))[$] integrals which could be solved easily.
Using above recursions given in post 693, you can solve for a very large class of stochastic integrals by representing arbitrary polynomial expressions of z(t) in terms of hermite polynomials and then use above recursions.
Here in post 697, I have given a toy example how you could solve for integral [$]\, \int_0^t \, z(s)^4 \, ds[$]. Following the logic in  that example you can easily solve for a very large number of stochastic integrals. : https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=690#p827488
I recall reading a scholarly paper in which author had calculated above integral [$]\, \int_0^t \, z(s)^4 \, ds[$]  with great difficulty but you can very quickly solve it by representing it in a hermite polynomial form and then applying the stochastic integral solution recursions of post 697.

Another thing I want to mention that iterate integral formula with repeated Ito is completely general and can be applied to any univariate or multivariate SDEs or systems of SDEs. But you have to generalize it according to the problem. For example in stochastic volatility SDEs setting when we have two different variables in a term as can happen that in volatility term of asset there could be a power of asset and also a power of volatility. In such cases, you apply Ito product rule instead of Ito change of variable formula and successive application of Ito product rule would convert the original SDE into large number of terms with constant integrand evaluated at initial time and then all we need is to solve for the appropriate stochastic integrals. It is a bit tedious but straightforward. 
I was not going to write a full-fledged stochastic volatility program and thought most people would do it on their own after looking at my research on strictly one dimensional SDEs. I wrote stochastic volatility program only because I needed a correct reference program which can be used to find the true distribution of the SV SDEs and I wanted to compare results from my experiments with other analytic methods that did not use any pseudo-random numbers.
Again here is the link to general Stochastic volatility SDEs program: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1200#p867829
You think life is a secret, Life is only love of flying, It has seen many ups and downs, But it likes travel more than the destination. Allama Iqbal
 
User avatar
Amin
Topic Author
Posts: 2309
Joined: July 14th, 2002, 3:00 am

Re: Breakthrough in the theory of stochastic differential equations and their simulation

June 1st, 2023, 12:04 pm

Simulation of SDEs Using Transition Probabilities Framework

Friends, going into year 2020, I made a lot of effort to find analytic methods for evolution of stochastic differential equations but I had very limited success. 
I was later able to make some solid success towards evolution of densities of SDEs with transition probabilities in early 2021. I borrowed high order discretization schemes from earlier work on monte carlo simulations and inverted them to find the estimate of transition normal and its associated probabilities between grid cells on first time grid and grid cells on second time grid. I also accounted for width of the originating grid cell using Taylor expansions to make sure that resulting estimate of the transition probabilities is valid fro transition probability from one complete grid cell to other complete grid cell.
Here in post 1129, made on Wed Apr 21, 2021 12:41 pm, I had posted a good program that advances the densities of SDEs by using transition probabilities framework. Here is the link to post: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1125#p865466
For dependencies of this program, you will have to download code from 2-3 posts earlier. For friends who want to understand the context and theory perfectly, please read the relevant posts between  posts 1059 and post 1129. Here is the web address of post 1059: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1050#p864474


Limit Order Book Construction From NASDAQ ITCH Protocol Streaming Data using C++.

After completing the work with transition probabilities densities, I started playing with different topics. I posted a C++ program to construct limit order book from Nasdaq ITCH format data. Here you can download the program. I had written a basic version of this program several years earlier. This C++ program  was distributed in post 1162 here: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1155#p866534


Very High Order Monte Carlo Discretizations of SDEs Employing Hermite Polynomials Up to Eight Order and Twelfth Order For Special Precision of Very Difficult SDEs.

Later I posted code for monte carlo simulation of SDEs with 8th and 12th order of expansion of SDEs. The original monte carlo simulation code I had written was only till fourth order and only employed fourth hermite polynomial as max order polynomial. I wrote new functions that could monte carlo simulate using  8th or 12th orders of expansions of SDEs for each time step. I thought that these very high order expansions would be helpful for friends who need very high accuracy for non-linear like SDEs. This code was distributed here on Tue Jun 15, 2021 2:51 pm, Post 1168 and 1169 : https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1155#p866726


Semi-Analytic Solution of Fokker-Planck Equation associated with the SDE based on Principle of Conservation of Mass

Later I found a simpler way to solve fokker-planck equation. This is a new method based on principle of conservation of probability mass. in this method the grid expands in time so as to conserve the probability mass associated with each grid point while simultaneously following the dynamics of Fokker-Planck equation associated with the SDE. In other words, the grid expands along constant CDF lines. 
We model this method by equating time derivative of the CDF Integral upto the grid point as equal to zero. This gives us an equation in terms of time derivative of the boundary grid point and the integral of fokker-planck equation of the SDE. It turns out that expression under integral sign is a complete integral leaving us a first order partial differential equation that determines the evolution of constant CDF points. Then I do a change of probability density and convert the probability density of the SDE into probability density of standard normal and associated change of probability derivative. Upon simplifications, the whole thing can be solved like a first order ODE for each constant probability point on the grid. 

You can download the program and details from posts around post 1198 here written on Wed Jul 28, 2021 5:49 pm here: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1185#p867692
More detailed explanation here in post 1202 : https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1200#p867718


Solution of Fokker-Planck Probability Mass Conservation Grid Formula For SDEs with a series in Powers of Standard Normal.

This is first time I conceived the idea of Z-Series and it worked very well to represent the random variables associated with SDEs. 
Suppose we have a random variable X and belongs to very large class of distributions that can be represented as a power series in standard normal random variable. We can then represent the random variable X as

[$]X \, = \, a_0 \, + \, a_1 \, Z \, + \, a_2 \, Z^2 \, +\, a_3 \, Z^3 \, +\, a_4 \, Z^4 \, +\, a_5 \, Z^5 \, +\, a_6 \, Z^6 \, + \, \ldots [$]

We also want the reader to know that for every Z-series there is an equivalent Orthogonal Polynomial Series with different coefficients. We know the relationships between coefficients so we can easily convert a Z-series to Hermite Polynomial series and vice versa. Here is a general representation of Hermite polynomial Series
[$]X \, = \, \mu \, + \, c_1 \, H_1(Z) \, + \, c_2 \, H_2(Z) \, +\, \, c_3 \, H_3(Z) \, +\, c_4 \, H_4(Z) \, +\, c_5 \, H_5(Z) \, +\, c_6 \, H_6(Z) \, + \, \ldots [$]
For a given random variable, we know how to convert from coefficients [$]a_n[$] of Z-series to coefficients [$]c_n[$] of hermite polynomial series and vice versa.

Here in post 1272, written on Thu Nov 11, 2021 7:19 pm, I conceived the idea of semi-analytic solution of fokker-plack equation by inserting a series in powers of standard normal random variable with undetermined coefficients whose coefficients would be later found by matching coefficients right and left hand side of equations for each power of Z. Here I described the idea https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1260#p868341
This was the first time, I used Z-series in the context of stochastic differential equations. You can download a program in post 1288. You will need to look at posts 1272-1296 for development on this topic. Especially read post 1291 and later posts : https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1290#p868483



Solution of Analytic Evolution of SDEs in Bessel Coordinates using Z-series and Addition of Cumulants

Later I had the idea of using Z-series representation of SDE random variables independently of Fokker-Planck equation and decided to use addition of cumulants to find the analytic evolution of SDEs without any pseudo random numbers.
Later in January 2022, I proposed to directly represent the initial distribution of the SDE at each time step and distribution of its diffusion at that step both as independent Z-series random variables. Since in bessel coordinates the evolution of SDE is almost independent of its initial value, I could use cumulant addition to advance the Z-series representation of the densities of SDEs. You can read relevant posts    1338,1339, 1343, 1345, 1349,1378, 1629, 1640. Here is post 1640 where a final program is distributed: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1635#p873577
Please note that for mean-reverting and many other types of SDEs there is still some dependence between initial distribution of the SDE and distribution of its generator even in Bessel coordinates but the method worked perfectly well over large enough time steps.



Similarity Between Method of Iterated Integrals used to Solve SDEs and ODEs and the Taylor Series Expansions. Both Methods are Cousins.

You can read this post for basic similarity  between Taylor series and method of iterated integrals used to find solution of ODEs and SDEs. https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1605#p873291



Z-Series/ Hermite Orthogonal Polynomial Series Construction of Densities with continuous derivatives.

Most densities with continuous derivatives and vanishing tails can be represented in terms of Z-Series or alternatively in terms of series in Hermite Orthogonal polynomials. This is true for lognormal density, generalized gamma density and its various variants and chi-squared density and its variants. 
Here is a post to find Z-series representation of lognormal random variables: viewtopic.php?f=4&t=99702&start=1635#p873551



Z-Series/Hermite Orthogonal Polynomial Series Expressions for Random variables whose first four to Eight Moments are given.

This method generates densities of random variables so that first eight moments of the density perfectly match with first eight moments input to the method. Mostly the match of the densities is precisely perfect. In this method, we find coefficients of Z-series or Hermite orthogonal Polynomial series so that moments of resulting density precisely match the input moments. Though Edgeworth and Gram-Charlier like methods have been very useful, this new method is a very significant improvement upon classic methods of construction of densities when moments are given. 
Here I distributed a program that finds Z-series representation of a random variable when first eight moments of the random variable are input to the program. It is in post 1653: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1650#p873803
Please also read post 1662 where I have written a small program that anlytically constructs generalized gamma density. The first eight moments of generalized gamma density are input to our Z-series density construction program. As it turns out, when graphed on the same axes, our newly constructed Z-series density is indistinguishable from analytic graph of generalized gamma density. Post 1662:  https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1650#p873846



Correlations Between Hermite Polynomials of Same Order across two Random Variables And Orthogonal Hermite Polynomial Regressions

Later I did a monte carlo simulation of system of asset and SV SDEs and found the Z-series representation of the asset density from moments of asset calculated in monte carlo. Posts 1685, 1686 and 1688:  https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1680#p874055
This monte carlo program led me to think about calculating correlations between orthogonal hermite polynomials of same degree across two correlated variables. I calculated correlations beteween hermite polynomials of same order between two correlated variables in monte carlo setting in a matlab program in this post 1691 and 1693: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1680#p874075
This led me to thinking that prevalent classic method of calculation of pearson correlation between two random variables was highly suboptimal when the densities of the variables are non-gaussian. It was optimal only for perfectly gaussian random variables. In general, the greater the deviation from gaussianity in two random variables, the more suboptimal the classic calculation of pearson correlation would become. I found in my research that a proper way to calculate correlations between two non-gaussian random variables was to represent the random variables as series in hermite orthogonal polynomials and then find correlations independently between hermite polynomials of the same order across two variables. This discovery means that most of the classic models and numerical methods in stochastics and time series that are based on proper calculation of correlations or covariances between two or more random variables have to be properly altered by replacing one gross estimate of Pearson correlation by multiple estimates of correlations between hermite polynomials of the same order across two variables when the random variables under consideration are non-gaussian.

The observation that pearson correlations have to be calculated independently for each hermite polynomial  led to a new ground breaking concept  of analytic hermite polynomial regression between two or more non-gaussian variables. This orthogonal regression breaks down every non-gaussian random variable into a series in hermite polynomials and then hermite polynomials of every order are regressed independently on each other depending upon their indpendent pearson correlations and then results from various orthogonal hermite polynomial regressions is added to give high dimensional curved surfaces with smooth derivatives that make a fit to the regression data.  As opposed to straight lines making a fit between variables in linear regression, in hermite orthogonal regression,  polynomials are used to find a fit to data and this fit is in the form of high-dimensional analytic, and curved surfaces with smooth derivatives. Please note that Hermite orthogonal regression I am referring to is a very new discovery that I recently made in Feb 2023 and it is different, far better and unrelated to another classic method known by the name of hermite polynomial regression which has been known for decades. This new method of hermite orthogonal regression is a strong competitor and usually better than most AI and machine learning regresssion methods that fit a curve to data.  As opposed to functional regression, our new orthogonal hermite polynomial regression method depends on correlations between hermite polynomials. While classic regression that depends upon correlations between first hermite polynomial our new method is a generalization of classic first hermite polynomial regression to a new method of regression that depends upon correlations between multiple orthogonal hermite polynomials of same order across different variables.
Below I show three graphs of hermite orthogonal regressions that try to explain Apple Stock returns VS Microsoft and Nvidia Stock returns. All three graphs use only nine data observations over non-overlapping periods.

Image
Image
Image

The next three posts 1791, 1792 and 1793 describe calculation of correlations, covariances and regressions between non-gaussian random variables when their Z-series representation is given.
 https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1770#p875136
https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1785#p875153
https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1785#p875155
Particularly the last post analytically explains the concept of regression between two Z-series random variables.
Please also read posts 1731, 1732 and 1734 for hermite polynomial correlations and regressions:
https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1710#p874492
https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1725#p874542
https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1725#p874578

Here I distributed program for doing multivariate hermite regression in post 1722: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1710#p874497

I presented results of one dimensional hermite regression in post 1705 here: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1680#p874075
The hermite regression program is given in post 1706 here: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1695#p874270

I also learnt that in order to do robust hermite orthogonal regressions, we needed to apply positivity condition of the derivatives of the density. Here I have described the positivity condition for derivatives of the density in post 1719: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1710#p874464
After proper application of positivity condition, hermite regressions worked in an excellent fashion. I showed some results here in post 1721: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1710#p874492

Please read posts 1783 and 1784 for calculation of variance of sum of two non-gaussian random variables when their hermite polynomials have correlations
https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1770#p875135
https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1770#p875136

Please disregard post 1785 and 1785, they have some errors.

A Z-series option pricing formula is given in post 1830 here: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1815#p875619
You think life is a secret, Life is only love of flying, It has seen many ups and downs, But it likes travel more than the destination. Allama Iqbal
 
User avatar
Amin
Topic Author
Posts: 2309
Joined: July 14th, 2002, 3:00 am

Re: Breakthrough in the theory of stochastic differential equations and their simulation

June 1st, 2023, 6:09 pm

Friends, I want to prepare some more material and then do a little bit of research for a few days over the weekend and then plan to start contacting people at Chinese universities at the start of next week,
However I am facing some very dire issues. As I told friends a few days earlier that Pakistan Army is drugging food and water in Lahore city on an unprecedented scale. I have been hit with bad food at least twice (in remote and unexpected places in the city) in past few days but I realized it and spitted all the food at the start right away both times. And it still took me several hours hours to get myself in perfect senses. I have also seen suspicious people at too many places (army agents reach the target expected places and start dusting at the stores or cleaning the floor and then try to help you when you want to get some food but mostly you could still tell that this guy does not belong here) . It is one of the thirty largest cities in the world and still very difficult to drug everywhere and that is why I have survived well because I have been very careful. For friends who have resources, I really want to request them to verify on their own and they would know that many areas in the city are being drugged at an unprecedented scale. Since I try to be very careful, and it is a huge city, I still think that I can survive for a few weeks. 
But people at Pentagon are way too desperate to let me continue. They know my original neurotransmitters that they tried to block for past twenty five years are coming back and that is the major reason to try drugging the city so that those important neurotransmitters could be blocked again and I would also lose my calm and my focus. But they have pretty much failed and I am very sure that next step would be that they would use a psychiatrist to detain me in a few days with complete surprise. My mother would simply make a summary statement saying that she had realized that I was not feeling well and therefore needed treatment. 
I was careful to keep taking a monthly antipsychotic injection so that my parents would not have any excuse to detain me but I am seriously worried that people at mind control agencies and their backers want to detain me as soon as possible before it is too late to control my neurotransmitters.
I have been previously detained more than twenty times in past twenty five years mostly on completely flimsy excuses. And then I am given all sort of injections and pills. Most psychiatrist doctors do not even care to let their patients know the name of antipsychotic drugs that are given to their patients during detention and absolutely anything can be given orally or injected. Last time I was detained in 2021 but I was not detained in past two years since I was able to do some better research in past two years and several good people in America supported me by protesting to agencies. About five or six weeks earlier, mind control agencies were getting ready  to detain me but their behavior changed dramatically for the better after I mentioned their plans on the forum. 
I really feel that mind control agencies are again under even more pressure from their backers and are becoming too desperate to detain me again. In the past when they would drug food in various neighborhoods of the city and I would mention on this forum, mostly the food drugging activity would decrease. But I have mentioned it at least twice in past week or ten days but mind control agencies continued to increase the food drugging activity with a complete resolve. I am very sure that they would now resort to detaining me in next few days. 
I really want to request good people in US and other places to please protest against my continuing mind control and also ask American mind control agencies to not detain me on completely flimsy excuses after they have failed to target me by drugging food in large number of neighborhoods in the city. If they detain me in a few days, I would be given all sort of mind control drugs in injections and most of my good neurotransmitters would be completely blocked again. And I would have to restart my research with extreme difficulty again. Most people who have remained on Wilmott for several years would have noticed how my English language would severely deteriorate and I would would write in extremely poor English after I would be released from detention. And my mathematics research would also become extremely slow and small things that need mere days would take me several weeks to complete. It is only that good people protested against such persecution activity during past two years and I have been spared the misery that was repeated every year.
I want to request good American people to please help me again and protest to responsible people in mind control agencies to end my persecution now and not detain me again in next few weeks as they have planned.

For some back ground on my mind control persecution, please see  https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1830#p875779
https://forum.wilmott.com/viewtopic.php?f=15&t=102298
https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1830#p875778
 
You think life is a secret, Life is only love of flying, It has seen many ups and downs, But it likes travel more than the destination. Allama Iqbal
 
User avatar
Amin
Topic Author
Posts: 2309
Joined: July 14th, 2002, 3:00 am

Re: Breakthrough in the theory of stochastic differential equations and their simulation

June 2nd, 2023, 7:33 am

Friends, in my previous post I had mentioned how Pakistan Army is drugging food with mind control chemicals in Lahore on an unprecedented scale. But that is not all and during all of past one month they dramatically increased electromagnetic resonance mind control as well. They have fitted very special hidden devices in my room where I sleep in recent weeks and I rarely have a perfectly good sleep. They also continue to force EM waves into the closed eyes when I am sleeping and I have sheer pain in my eyes whenever I wake up during sleep or in the morning. My eyes are some of the most regular targets of EM waves. When I am asleep,  some mind control chemical settles around eyes that gets highly charged and then stops some of the neurotransmitters from approaching the nerves in my eyes. Sometimes when I am totally mentally down or feeling extreme anxiety due to mind control, I would forcefully stretch the skin around both eyes which in turn disperses some of the charge around the eyes and all of a sudden I would feel perfectly mentally well and my eyesight would become sharper but this good effect would only last for a few minutes and then I would start feeling anxiety again with a bad eyesight. Washing the eyes with a soap also helps but many times this relief is also temporary. 
I had told friends about a deteriorating eye sight earlier but past three or four days were extremely worse and my eyesight has dramatically deteriorated during this period and I am very alarmed now since it has become very difficult to read small words. I told friends that many of the shades of colors that I used to see long ago and then stopped seeing came back to my eyes in past month or two. I believe it is only because colors associated with neurotransmitters could be observed again in my brain only when several of the blocked neurotransmitters became active. However despite that I could see shades of colors that I had not seen in a while, focus in my eyes continues to deteriorate very fast especially in past 3-4 days. 
I really want to request friends to please protest against such inhuman practices at hands of US defense. I wold also like to say that there are tens of thousands of intelligent people under mind control and many times far worse happens to them but they have nobody to turn towards and have to accept these inhuman treatments and humiliations as their fate. Most of them become unable to convey themselves in proper language and can only speak in poor broken English after they get retarded and then cruel people behind mind control simply make fun of them saying that they are mental patients. I was extremely lucky that I had some neurotransmitters they did not know and I continued to use those alternative neurotransmitters when many of my known neurotransmitters were blocked and therefore I survived to tell the tails of persecution and torture in a relatively lucid way. But most mind control targets are not so lucky and they have to live a life of absolute misery. Please protest to American defense and American president to end mind control forever. 
You think life is a secret, Life is only love of flying, It has seen many ups and downs, But it likes travel more than the destination. Allama Iqbal
 
User avatar
Amin
Topic Author
Posts: 2309
Joined: July 14th, 2002, 3:00 am

Re: Breakthrough in the theory of stochastic differential equations and their simulation

June 3rd, 2023, 3:42 am

As most of the friends who followed me over the years would have noticed that I mostly write in poor broken English. But it was always not like that and I used to write in far better language. Though my English was never extremely good, it was still reasonably good. But each time, they detained me they blocked more and more neurotransmitters related to English writing skills and my writing skills continued to deteriorate. And the same thing happened to my speaking and mathematical skills. Here is my blog that was written in 2014 when I could write well.  https://ahsanamin2999.wordpress.com/  
In the above blog, I wrote mostly about Pakistan.

I was detained for two months in 2014 and I wrote above blogs prior to that detention. When I left detention after two months, I wrote only in very poor and broken English language. I have never been able to write well again as I was able to write in above blogs. 
When you see mind control targets, who have been retarded, speak or write in poor and incoherent language, please be patient and  try to know what they are attempting to say. Pleas try to  put yourself in their shoes and try to be kind. Please do not make good-natured people objects of ridicule as some people would like you to do. Mind control is the worst thing in the world that is used to retard intelligent people and to impose a complete life of misery and torture on them.  
You think life is a secret, Life is only love of flying, It has seen many ups and downs, But it likes travel more than the destination. Allama Iqbal
 
User avatar
Amin
Topic Author
Posts: 2309
Joined: July 14th, 2002, 3:00 am

Re: Breakthrough in the theory of stochastic differential equations and their simulation

June 5th, 2023, 5:36 pm

Friends, I have been able to survive the recent wave of drugging food in Lahore city with mind control chemicals. But water and beverages are increasingly being systematically drugged both while lying in shelves and at the manufacturing source. It's already harsh summers and it would be very difficult to live without good water. I drink 5 to 6 1.5 L water bottles everyday. I drink more water possibly because I am very overweight. A really good thing is that mind control agencies and Pakistan army have not yet drugged ground water in most of the city and  ground water is mostly good. So I can survive easily until they start drugging underground water reservoirs in the city even if all of the manufactured bottled water becomes drugged.
Most of the pasteurized milk and tea whiteners in the city also has mind control chemicals. I take tea with milk and top most milk brands were being drugged at manufacturing source for several months. Some cheaper and less known milk brands were holding up and their milk was better and therefore I switched to them but they also became drugged in recent week. 
I have also decided to delay the plans of going to China for the moment. I want to try some sustainable path in which I can make some money while also working independently on my research. I used to approach some of my linkedin connections for consulting work opportunity but mostly CIA would also approach them and then nobody would want to give me any project at all. Slowly I stopped contacting people since I realized that it was of no use. I want to think more about possibilities and then see if somehow I could make money while continuing my research.
I have also resumed my research and want to stay busy with it in coming weeks and months.
Though I am not making a big deal about it, mind control agencies continue to drug the city and I am seriously worried that they would resort to detaining me if they could not block my neurotransmitters by drugging food in the city.
You think life is a secret, Life is only love of flying, It has seen many ups and downs, But it likes travel more than the destination. Allama Iqbal
 
User avatar
Amin
Topic Author
Posts: 2309
Joined: July 14th, 2002, 3:00 am

Re: Breakthrough in the theory of stochastic differential equations and their simulation

June 7th, 2023, 8:01 am

Friends, in this post, I want to outline a very interesting property of Z-series and resulting Hermite Orthogonal regressions.
I suppose that friends have read all posts on hermite orthogonal regressions and have become very familiar with that. 
Some preliminaries first: As we recall from our work on SDEs and later research that when we transform the density of a random variable into density of its some function, the pints on original density are mapped on transformed density so that they share the same underlying Z or in other words they share the same CDF. Trying to explain in detail, let us suppose we have Z-series representation of a random variable given as

[$]\, X(Z) \, = \, a_0 \, + \, a_1 \, Z \, + \,a_2 \, Z^2 \, + \,a_3 \, Z^3 \, + \,a_4 \, Z^4 \, + \ldots [$]

While doing Z-series research, we spent quite some time how to find densities of functions of Z-Series random variables using Taylor Series around median, I would request friends to become familiar with that. Suppose we have a new random variable Y that is a function of random variable X above, the Z-series of Y could be given as

[$]\, Y(Z) \, =\, f(X(Z)) \, = \, b_0 \, + \, b_1 \, Z \, + \,b_2 \, Z^2 \, + \,b_3 \, Z^3 \, + \,b_4 \, Z^4 \, + \ldots [$]

Suppose we are given N data values of X shown as [$]X_1,\,  X_2, \, X_3, \, \ldots \, ,X_N[$] and we apply the function on these data values of X to get corresponding values of Y given as [$]Y_1,\,  Y_2, \, Y_3, \, \ldots \, ,Y_N[$]
As we learnt several times in the previous posts, that we can invert the Z-series of any random variable to find the corresponding value of underlying Z.
Suppose we apply this Z-series inversion to both the data values of X and Y (and we keep in mind that Y=f(X(Z))  ) 
If the inverted Z-values of random variable X data are given as [$]Z_1,\,  Z_2, \, Z_3, \, \ldots \, ,Z_N[$], and the inverted Z-series values of random variable Y would be exactly the same and would be given again as [$]Z_1,\,  Z_2, \, Z_3, \, \ldots \, ,Z_N[$]
Since underlying Z-values corresponding to data observations of a random variable depend only on their associated CDF, the underlying Z-values of any random variable and functions of the random variable would be exactly the same.
However, these functions that preserve the CDF have to follow the positivity condition that we discussed in earlier posts that  [$]\frac{dX}{dZ} > 0[$] all along X-axis. Our results hold for only those functions that satisfy the positivity condition.

One very interesting ramification of the above observation is that when we do hermite orthogonal regressions, it will not matter if we use a random variable [$]X[$] or [$]X^2[$] as regressors, since our hermite orthogonal regressions depend on values of underlying Z's and underlying Z's are precisely the same for admissible functions of the original random variable. In fact adding [$]X[$] and [$]X^2[$] together in the regressions would give defective rank matrices with poor regressions. So we can add any admissible function of original random variable, that follows the positivity condition, in our regressions to get the same regressions result as we get from the original random variable.

But friends would have to consider in their experiments that common Z's for random variables and their functions would hold only when we do precise calculations. If series for [$]X[$] is truncated at [$]Z^4[$], for good results we have to truncate the series of X^2 at  [$]Z^8[$]. If we truncate both series at [$]Z^4[$], resulting series might not give precisely the same Z's when inverted but I would still expect them to be highly collinear and close to rank defective in a regressors matrix. While making a comparison similar problems would have to be considered. Similarly when finding parameters of density of function (as we will need these parameters to invert the Z-series of the function), we would have to ensure that we take enough terms in Taylor series to keep precision in our calculations.
You think life is a secret, Life is only love of flying, It has seen many ups and downs, But it likes travel more than the destination. Allama Iqbal
 
User avatar
Amin
Topic Author
Posts: 2309
Joined: July 14th, 2002, 3:00 am

Re: Breakthrough in the theory of stochastic differential equations and their simulation

June 13th, 2023, 9:23 pm

Friends, my persecution continues unabated. Since mind control agents failed to drug my food as I was very careful about buying food, they have resorted to other animal tactics in order to continue my mind control. Some of these things are very disturbing and painful. They have planted several microwave devices on all possible positions I can sleep in my room. When I go to bed, they use my both hands or both feet as electrodes and I have very painful sensations in my both hands or both feet as I sleep. They simultaneously target both hands or both feet with EM waves and microwaves and I remain restless all night. Sometimes,when they really increase the electric potential, my hands have very high degree of pain and restlessness and I try to hide my hands beneath the pillow to find some temporary relief. It is already high summers and I cannot use my AC due to gases, therefore it is not possible to take any thick comforter over my body as I do in winters and my both hands and feet are mostly directly exposed to microwaves and EM waves. This has been going on for past several weeks and intensity of this torture has increased substantially over past few days.

Another problem that I face everyday is that they release very heavy gas in almost all the rooms and places in our house. This tactic was used by them very rarely and usually in drawing room where I usually do not work. They had been careful to not overly use this tactic everywhere in our house. But for past few weeks, they have been using this heavy gas in every room and every place in our house. This heavy gas facilitates rapid and fast conduction of charges in the atmosphere. The heavy gas usually sticks to bottom of pants and then charges released from devices fitted all over the house, travel up inside the pants from bottom of the pants towards the testicles and then settle on testicles and private parts to control testosterone. They want to control testosterone so that mind control victim has  no drive left to do anything meaningful. When inside home, I pull up bottom of my tapered cotton pants (as they  to make it difficult for charges to freely travel upwards towards the testicles. It helps slightly but everyday I have to wash a thick surface of black chemical that has settled on my testicles.
They also keep pulling my neurotransmitters without any regard for my health. I have been having heart-ache for past one day. This has happened many times before over past several years and repeatedly happens when they take some specific neurotransmitter out of my body. 

Indeed these malicious jewish billionaire(and his cohort of malicious jews; How can sons of prophets become complete animals towards weak) and his paid mercenaries in American  Army are truly making American great again. If the definition of great is to become complete animal devoid of any humanity towards weak and innocent people. Isn't this true that  might is perfectly right. 
Sorry for being ironic but it seems that there is no decency and humanity in American army scum and their backers.
Is there any humanity alive?
Are my entreaties for Freedom and my requests for mercy as if I am hitting my head against stones to make myself even larger object of ridicule on hands of cruel jews.
You think life is a secret, Life is only love of flying, It has seen many ups and downs, But it likes travel more than the destination. Allama Iqbal
 
User avatar
Amin
Topic Author
Posts: 2309
Joined: July 14th, 2002, 3:00 am

Re: Breakthrough in the theory of stochastic differential equations and their simulation

June 15th, 2023, 10:01 pm

As I have told friends previously, I was making a decent income before I went to UK on HSMP visa in summer/fall of 2010. Since I had enough money, it made it very difficult for mind control agencies to easily control me and they were very upset with the money I had. I would stay at good Hotels for my better safety. Since they were drugging various neighbourhoods of London city, I started travelling around to avoid staying at any fixed place. Though I would mostly take a train to travel to north England or Scotland, I would sometime not hesitate to take a Taxi from York to Manchester or Birmingham to London. CIA and mind control agencies even went to the extent to make my bank (literally) steal my money and my bank stole my one thousand pounds since mind control agencies/CIA wanted to bleed my money. I have written about it on several places on this forum. A hotel charged me 1500 pounds after I had left the city (and the hotel after returning the keys) without telling me complaining I had broken their door and I came to know only a month later when I saw my credit card statements. When I called the hotel, they told that there were cracks on the wooden door but they gave me no reason why they never told me about it prior to charging money from my credit card.
When I returned from UK to Pakistan, CIA made sure that nobody did business with my company and they threatened people in Europe and other places to not do any business with my small company. They never wanted repeat of UK if I again go elsewhere in the world. In past thirteen years, I have made merely four thousand dollars (or they were probably 3500 dollars, I have forgotten the exact value). 
Though most people would stay nice even after they would refuse to do business with my company, some people were not exactly polite. A few years ago, I totally gave up contacting people for consulting work or any other business for my one person company.
My inability to make money has also been a strong reason that prolonged my torture, agony and mind control. I have some extremely good stock trading algorithms and I opened an account with IB but I could not fund that account because I could not send foreign currency Bank wire to any foreign business. Pakistan has very little foreign reserves and they have anti-business laws that prohibit sending foreign currency abroad through a bank wire to any foreign business.
Recently I noticed that I can open a bank account with Alpaca and fund it with Rapyd without involving a Pakistani bank. Just this evening, I went ahead and opened an Alpaca individual stock trading account. I still have to fund it but I will keep playing with it for a few days for paper trading and then fund the account. Alpaca is also a very good stock broker for US stocks and I hope they would prove to be better than IB and others.
I really hope that I will be able to make enough money to forget the hardships I had to face over past thirteen years without any money. Once I have enough money, I will start a proper business related to financial investments, and applications of probability theory, statistics and machine learning in all diverse areas of science and engineering. I also want to continue my personal research in the direction of Z-series machine learning.
However, I am afraid that racists in mind control agencies and CIA would try their best to thwart me by possibly approaching the broker to create problems with me. Obviously they have no legal basis against me other than complete lies and machinations but this is what they have so successfully use over past twenty five years against me.
I will keep friends updated with progress on my trading in next few days.
You think life is a secret, Life is only love of flying, It has seen many ups and downs, But it likes travel more than the destination. Allama Iqbal
 
User avatar
Amin
Topic Author
Posts: 2309
Joined: July 14th, 2002, 3:00 am

Re: Breakthrough in the theory of stochastic differential equations and their simulation

June 16th, 2023, 9:11 pm

I am really so tired of complaining but mind control torture continues unabated. They do not stop using gases in my room at all and continue to release very sickening gas in my room. I keep the window and door of my room mostly open but it does not help at all. It is also very painful at night when I try to sleep and there is constant sickening gas in the room. 
When I complained about heavy gas, they decreased its use somewhat but increased another type of gas in room that makes me sick when I breathe in it.
They also continued to use charges on my body through my hands and feet as electrodes but did slightly decrease the intensity of torture. They have openly used the charges conduction torture method on my hands and feet as electrodes in both of the past two days after I mentioned here but might have decreased the intensity of severe torture to 70% of its previous value. 
I have been talking about use of sickening gases for many many long years but they never stop using those gases. Best that has happened in the past is that they would temporarily stop using gases for a week or so but then start using it again once they would know that pressure from good people had decreased and I would no longer be writing about it. And many times I would feel bad complaining about the same thing again and again on the forums. Though at other times I know that keep on complaining though awkward but is probably better to keep my life somewhat free of such torture. 
You think life is a secret, Life is only love of flying, It has seen many ups and downs, But it likes travel more than the destination. Allama Iqbal
 
User avatar
Amin
Topic Author
Posts: 2309
Joined: July 14th, 2002, 3:00 am

Re: Breakthrough in the theory of stochastic differential equations and their simulation

June 17th, 2023, 9:40 pm

Friends, it is just absolutely hot (weather) and very difficult to do anything. I was reading on weather forecast that in next few days the temperature would go to 44 Celsius (112 Fahrenheit) and feels like would be 56 Celsius (133 Fahrenheit). So it is very difficult to work without Air-conditioning which has huge gases in my room. I was thinking of my work on monte carlo and SDEs and then I had several new ideas to solve the SDEs in original coordinates with Z-series in a monte carlo like explicit manner. In this post I want to share these ideas with friends. I would give complete details but  a full-fledged matlab program can take next few days.

Suppose we have a general SDE in original (as opposed to Bessel coordinates that we worked with mostly in context of Z-series) coordinates. The SDE is given as

[$] \, dX(t) \, = \, \mu(X(t)) \, dt \,+\, \sigma(X(t)) \, dZ(t) [$]            Equation(1)

We know that a second order expansion of the above SDE is given as (using the method we have previously learnt on this forum)

[$] \, X_{t_1} \, = \, X(t_0) \, + \, \mu(X(t_0)) \Delta t \, + \, \sigma(X(t_0)) Z \sqrt{\Delta t} \\ + \, \frac{\partial \mu(X(t_0))}{\partial X} \, \mu(X(t_0)) \, {\Delta t}^2 \, + \, \frac{\partial \mu(X(t_0))}{\partial X} \, \sigma(X(t_0)) \, (1 \, - \, \frac{1}{\sqrt{3}} ) \, Z \, {\Delta t}^{1.5} \\ +\, .5  \, \frac{\partial^2 \mu(X(t_0))}{\partial X^2} \, {\sigma(X(t_0))}^2 \, {\Delta t}^2 \, \\ + \, \frac{\partial \sigma(X(t_0))}{\partial X} \, \mu(X(t_0)) \,  (\frac{1}{\sqrt{3}} ) \, Z \, {\Delta t}^{1.5} \, + \, \frac{\partial \mu(X(t_0))}{\partial X} \, \sigma(X(t_0)) \, (Z^2\, - \, 1) \, \frac{\Delta t}{2} \\ +\, .5  \, \frac{\partial^2 \sigma(X(t_0))}{\partial X^2} \, {\sigma(X(t_0))}^2 \, \,  (\frac{1}{\sqrt{3}} ) \, Z \, {\Delta t}^{1.5} \,[$]         Equation(2)

We suppose without any loss of generality that starting distribution is given in the form of a Z-series random variable as
[$]X(t_0)\, = \, f(Z_0)[$] where f(Z_0) is a Z-series representation of [$]X(t_0)[$]. When we are starting from a delta source, this Z-series distribution would be a constant value.

We know that we can represent the functions of any Z-series random variable by a Taylor series. For the type of power exponents we use in drift and volatility functions,  which are typically equal to or smaller than one, this Taylor series representation of functions is quite very faithful when seven terms are used in Z-series. We have repeatedly used Taylor series in the past to calculate the functions of Z-series random variables with good results.
Please read this post for introduction: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1290#p868484

In order for friends to be familiar with this Taylor expansion of functions of Z-series, I would solve a toy problem. Suppose random variable X is represented by a fourth order Z-series (we want to find taylor expansion of its suitable functions). Z-series of X is given as
[$]X(Z) \, =\, a_0 \, + \, a_1 \, Z \, + \, a_2 \, Z^2 \, + \, a_3 \, Z^3 \, + \, a_4 \, Z^4 \, [$]

You can verify from various methods (also from the above link and direct series expansion) that a Z-series of a suitable function f(X(Z)) (when expanded around median, Z=0) is given as

[$]f(X(Z)) \, =\, \, f(a_0) \,   +\, a_1 f^{'}(a_0) \, Z+\, (a_2 \, f^{'}(a_0)+1/2 {a_1}^2 \, f^{''}(a_0)) \, Z^2 \\ +(a_3 \, f^{'}(a_0)+a_1 \, a_2 \, f^{''}(a_0) \, +1/6 \, {a_1}^3 \, f^{3}(a_0) \, ) \, Z^3 \, \\+ \, (a_4 \, f^{'}(a_0)+1/2 \, ({a_2}^2 \, +\, 2 \, a_1 \, a_3) \, f^{''}(a_0) \, + \, 1/2 \, {a_1}^2 \, a_2 \, f^{3}(a0)+1/24 \, {a_1}^4 \, f^{4}(a_0)) \, Z^4 \, + \, O[Z]^5 [$]       Equation(3)

I have expanded the Taylor series of above function to only low order for friends to understand it but in general we will have to write an automated program to expand it to seventh or higher order to keep the expansion faithful to true result. Usually we will almost always expand functions of Z-series using Taylor around the median Z=0.

Now going back to Equation 2 where we expanded the SDE in original coordinates to second order. We suppose that original distribution of the SDE is given by the random variable [$]X(t_0)[$] can be represented by a Z-series to suitable order as

[$]\, X(t_0) \, = \, c_0 \, + \, c_1 \, Z_0 \, + \, c_2 \, {Z_0}^2 \, + \, c_3 \, {Z_0}^3 + \, \ldots \\ =\, g_0(Z_0)[$]  Equation(4)

We know that we can expand the functions of initial random variable also as Z-series using Taylor formula around median and therefore we can represent as

[$]\, \mu(X(t_0)) \, = \, g_1(Z_0) [$]
[$]\, \sigma(X(t_0)) \, = \, g_2(Z_0)[$]
[$]\, \frac{\partial \mu(X(t_0))}{\partial X} \, \mu(X(t_0)) \, = \, g_3(Z_0)[$]
[$]\, \frac{\partial \mu(X(t_0))}{\partial X} \, \sigma(X(t_0)) \, = \, g_4(Z_0)[$]
[$]\, \frac{\partial^2 \mu(X(t_0))}{\partial X^2} \, {\sigma(X(t_0))}^2 \, = \, g_5(Z_0)[$]
[$] \, \frac{\partial \sigma(X(t_0))}{\partial X} \, \mu(X(t_0)) \,= \, g_6(Z_0)[$] 
[$] \, \frac{\partial \mu(X(t_0))}{\partial X} \, \sigma(X(t_0)) \,=\, g_7(Z_0)[$]
[$]\, \frac{\partial^2 \sigma(X(t_0))}{\partial X^2} \, {\sigma(X(t_0))}^2 \,=\, g_8(Z_0)[$]    Equations(5)

Basically all g's above are different Z-series that represent function of original random variable [$]X(t_0)[$] that represents the initial starting distribution of SDE at every evolution step.

We insert above function Z-series expansions in Equation(2)  to find the expression as

[$] \, X_{t_1}(Z,Z_0) \, = \, g_0(Z_0) \, + \, g_1(Z_0) \Delta t \, + \, g_2(Z_0) Z \sqrt{\Delta t}  + \, g_3(Z_0) \, {\Delta t}^2 \, + \, g_4(Z_0) \, (1 \, - \, \frac{1}{\sqrt{3}} ) \, Z \, {\Delta t}^{1.5} \\ +\, .5  \, g_5(Z_0) \, {\Delta t}^2 \,  + \, g_6(Z_0) \,  (\frac{1}{\sqrt{3}} ) \, Z \, {\Delta t}^{1.5} \, + \, g_7(Z_0) \, (Z^2\, - \, 1) \, \frac{\Delta t}{2}  +\, .5  \, g_8(Z_0) \,  (\frac{1}{\sqrt{3}} ) \, Z \, {\Delta t}^{1.5} \,[$]         Equation(2)

It was actually naiive of me earlier to use cumulant addition. We do not need cumulant addition. We can take moments of the entire expression above by expanding the whole expression to its powers by simple algebra and then substituting expected values of powers of  Z and [$]Z_0[$] knowing that both Z's are independent. We might have to write a good and clever algorithm (for very fast speed) that does it for series expressions embedded as in above equation but it should not be very difficult. Once we have first eight moments calculated from above equation, we can turn them into a Z-series with a single stochastic variable [$]Z_1[$] which is different from both [$]Z_0[$] and [$] Z[$]. So we have an evolution algorithm for SDEs in original variables.

The above method also makes use of SDEs very transparent in the sense that we can acquire all information about conditional variances and higher conditional moments and we can match them to empirical phenomenon much more systematically. 

I am thinking of another method that can possibly make use of derivatives of the SDE expression in Z and [$]Z_0[$] to match the Z-series as opposed to using moments to match the Z-series but some ideas are still hazy. If it works out, it would be a lot better algorithm since we would be spared the effort to match the moments for a single final Z-series(which might not possibly work universally all the time and might create some issues from time to time with the present algorithm we have.) If it works out with the derivatives algorithm, I will post the details of derivatives algorithm in next few days here on this forum.
You think life is a secret, Life is only love of flying, It has seen many ups and downs, But it likes travel more than the destination. Allama Iqbal
 
User avatar
Amin
Topic Author
Posts: 2309
Joined: July 14th, 2002, 3:00 am

Re: Breakthrough in the theory of stochastic differential equations and their simulation

June 17th, 2023, 10:24 pm

Friends, It is 3:16 am at night and I have been working in the living room of our house since nobody else is awake and I can work here without any disturbance. But when I go into my room to take anything, it is totally suffocating due to gas (I think origin of the gas is AC in my room that continues to release gas even though I never turn it on) and it is very difficult to stay in the room and this is despite that both the window and door of the room are fully open to allow the air to ventilate. I continued to beg the mind control guy yesterday and before to not use this particular gas but they still continued its use and my sleep remained disturbed but at this particular moment there is huge gas in my room and it is very difficult to stay inside for even brief period of time. I literally do not want to sleep there anymore but I have no other choice. These gases are very big torture and mind control agents are not willing to decrease them to let me normally sleep or work inside my room. I continue to ask for help but cruel people in American army and pentagon have absolutely no humanity for me.
I tried to find some plastic tape to seal the openings of the AC but unfortunately I could not find any tape at this time in our house and it is impossible to go out and buy any tape now.
You think life is a secret, Life is only love of flying, It has seen many ups and downs, But it likes travel more than the destination. Allama Iqbal
 
User avatar
Amin
Topic Author
Posts: 2309
Joined: July 14th, 2002, 3:00 am

Re: Breakthrough in the theory of stochastic differential equations and their simulation

June 18th, 2023, 4:30 am

Friends, there were some small typos in my previous post. I have also explained some final equations better in this post. It is a better copy of previous post 1858. A coefficient of .5 was  missing in Equation 2 in [$]{\Delta t}^2[$] terms. Please do look at this  post especially new equations 7 and 8 that were not in previous original post. This is the right post with some errors removed. Please disregard post 1858.

Suppose we have a general SDE in original (as opposed to Bessel coordinates that we worked with mostly in context of Z-series) coordinates. The SDE is given as

[$] \, dX(t) \, = \, \mu(X(t)) \, dt \,+\, \sigma(X(t)) \, dZ(t) [$]            Equation(1)

We know that a second order expansion of the above SDE is given as (using the method we have previously learnt on this forum)

[$] \, X_{t_1} \, = \, X(t_0) \, + \, \mu(X(t_0)) \Delta t \, + \, \sigma(X(t_0)) Z \sqrt{\Delta t} \\ + \, \frac{\partial \mu(X(t_0))}{\partial X} \, \mu(X(t_0)) \, \frac{{\Delta t}^2}{2} \, + \, \frac{\partial \mu(X(t_0))}{\partial X} \, \sigma(X(t_0)) \, (1 \, - \, \frac{1}{\sqrt{3}} ) \, Z \, {\Delta t}^{1.5} \\ +\, .5  \, \frac{\partial^2 \mu(X(t_0))}{\partial X^2} \, {\sigma(X(t_0))}^2 \, \frac{{\Delta t}^2}{2} \, \\ + \, \frac{\partial \sigma(X(t_0))}{\partial X} \, \mu(X(t_0)) \,  (\frac{1}{\sqrt{3}} ) \, Z \, {\Delta t}^{1.5} \, + \, \frac{\partial \mu(X(t_0))}{\partial X} \, \sigma(X(t_0)) \, (Z^2\, - \, 1) \, \frac{\Delta t}{2} \\ +\, .5  \, \frac{\partial^2 \sigma(X(t_0))}{\partial X^2} \, {\sigma(X(t_0))}^2 \, \,  (\frac{1}{\sqrt{3}} ) \, Z \, {\Delta t}^{1.5} \,[$]         Equation(2)

We suppose without any loss of generality that starting distribution is given in the form of a Z-series random variable as
[$]X(t_0)\, = \, f(Z_0)[$] where f(Z_0) is a Z-series representation of [$]X(t_0)[$]. When we are starting from a delta source, this Z-series distribution would be a constant value.

We know that we can represent the functions of any Z-series random variable by a Taylor series. For the type of power exponents we use in drift and volatility functions,  which are typically equal to or smaller than one, this Taylor series representation of functions is quite very faithful when seven terms are used in Z-series. We have repeatedly used Taylor series in the past to calculate the functions of Z-series random variables with good results.
Please read this post for introduction: https://forum.wilmott.com/viewtopic.php?f=4&t=99702&start=1290#p868484

In order for friends to be familiar with this Taylor expansion of functions of Z-series, I would solve a toy problem. Suppose random variable X is represented by a fourth order Z-series (we want to find taylor expansion of its suitable functions). Z-series of X is given as
[$]X(Z) \, =\, a_0 \, + \, a_1 \, Z \, + \, a_2 \, Z^2 \, + \, a_3 \, Z^3 \, + \, a_4 \, Z^4 \, [$]

You can verify from various methods (also from the above link and direct series expansion) that a Z-series of a suitable function f(X(Z)) (when expanded around median, Z=0) is given as

[$]f(X(Z)) \, =\, \, f(a_0) \,   +\, a_1 f^{'}(a_0) \, Z+\, (a_2 \, f^{'}(a_0)+1/2 {a_1}^2 \, f^{''}(a_0)) \, Z^2 \\ +(a_3 \, f^{'}(a_0)+a_1 \, a_2 \, f^{''}(a_0) \, +1/6 \, {a_1}^3 \, f^{3}(a_0) \, ) \, Z^3 \, \\+ \, (a_4 \, f^{'}(a_0)+1/2 \, ({a_2}^2 \, +\, 2 \, a_1 \, a_3) \, f^{''}(a_0) \, + \, 1/2 \, {a_1}^2 \, a_2 \, f^{3}(a0)+1/24 \, {a_1}^4 \, f^{4}(a_0)) \, Z^4 \, + \, O[Z]^5 [$]       Equation(3)

I have expanded the Taylor series of above function to only low order for friends to understand it but in general we will have to write an automated program to expand it to seventh or higher order to keep the expansion faithful to true result. Usually we will almost always expand functions of Z-series using Taylor around the median Z=0.

Now going back to Equation 2 where we expanded the SDE in original coordinates to second order. We suppose that original distribution of the SDE is given by the random variable [$]X(t_0)[$] can be represented by a Z-series to suitable order as

[$]\, X(t_0) \, = \, c_0 \, + \, c_1 \, Z_0 \, + \, c_2 \, {Z_0}^2 \, + \, c_3 \, {Z_0}^3 + \, \ldots \\ =\, g_0(Z_0)[$]  Equation(4)

We know that we can expand the functions of initial random variable also as Z-series using Taylor formula around median and therefore we can represent as

[$]\, \mu(X(t_0)) \, = \, g_1(Z_0) [$]
[$]\, \sigma(X(t_0)) \, = \, g_2(Z_0)[$]
[$]\, \frac{\partial \mu(X(t_0))}{\partial X} \, \mu(X(t_0)) \, = \, g_3(Z_0)[$]
[$]\, \frac{\partial \mu(X(t_0))}{\partial X} \, \sigma(X(t_0)) \, = \, g_4(Z_0)[$]
[$]\, \frac{\partial^2 \mu(X(t_0))}{\partial X^2} \, {\sigma(X(t_0))}^2 \, = \, g_5(Z_0)[$]
[$] \, \frac{\partial \sigma(X(t_0))}{\partial X} \, \mu(X(t_0)) \,= \, g_6(Z_0)[$] 
[$] \, \frac{\partial \mu(X(t_0))}{\partial X} \, \sigma(X(t_0)) \,=\, g_7(Z_0)[$]
[$]\, \frac{\partial^2 \sigma(X(t_0))}{\partial X^2} \, {\sigma(X(t_0))}^2 \,=\, g_8(Z_0)[$]    Equations(5)

Basically all g's above are different Z-series that represent function of original random variable [$]X(t_0)[$] that represents the initial starting distribution of SDE at every evolution step.

We insert above function Z-series expansions in Equation(2)  to find the expression as

[$] \, X_{t_1}(Z,Z_0) \, = \, g_0(Z_0) \, + \, g_1(Z_0) \Delta t \, + \, g_2(Z_0) Z \sqrt{\Delta t}  + \, g_3(Z_0) \, \frac{{\Delta t}^2}{2} \, + \, g_4(Z_0) \, (1 \, - \, \frac{1}{\sqrt{3}} ) \, Z \, {\Delta t}^{1.5} \\ +\, .5  \, g_5(Z_0) \, \frac{{\Delta t}^2}{2} \,  + \, g_6(Z_0) \,  (\frac{1}{\sqrt{3}} ) \, Z \, {\Delta t}^{1.5} \, + \, g_7(Z_0) \, (Z^2\, - \, 1) \, \frac{\Delta t}{2}  +\, .5  \, g_8(Z_0) \,  (\frac{1}{\sqrt{3}} ) \, Z \, {\Delta t}^{1.5} \,[$]         Equation(6)

We can simplify the above equation with some algebra in a simpler form as

[$] \, X_{t_1}(Z,Z_0) \, = \, h_0(Z_0) \, + \, h_1(Z_0) Z \,  + \, h_2(Z_0) \, (Z^2\, - \, 1) \, \,[$]         Equation(7)

In above equation, we have re-arranged and absorbed constant values in coefficients of new re-scaled (after simple algebra) Z-series given as [$]h_0(Z_0)[$], [$]h_1(Z_0)[$], and [$]h_2(Z_0)[$]. 

Depending upon what is convenient for analytics, we can also re-write a different re-arranged version of above equation as

[$] \, X_{t_1}(Z,Z_0) \, = \, \tilde{h_0}(Z_0) \, + \, \tilde{h_1}(Z_0) Z \,  + \, \tilde{h_2}(Z_0) \, Z^2 \, \,[$]         Equation(8)

where [$] \tilde{h_0}(Z_0) \,[$],   [$] \tilde{h_1}(Z_0) \,[$] and  [$] \tilde{h_2}(Z_0) \,[$] are new different but re-arranged versions of previous Z-series given as [$]h_0(Z_0)[$], [$]h_1(Z_0)[$], and [$]h_2(Z_0)[$]. 

It was actually naiive of me earlier to use cumulant addition for solution of SDEs in Bessel coordinates. We do not necessarily need cumulant addition of previous random variable form of initial distribution the SDE at the start of time step and the SDE itself. We can take moments of the entire expression [$] \, X_{t_1}(Z,Z_0) \, [$]  above by expanding the whole expression to its powers by simple algebra and then substituting expected values of powers of  Z and [$]Z_0[$] knowing that both Z's are independent in order to calculate value of each moment of [$] \, X_{t_1}(Z,Z_0) \, [$]. We might have to write a good and clever algorithm (for very fast speed) that does it for series expressions embedded as in above equation but it should not be very difficult. Once we have first eight moments of [$] \, X_{t_1}(Z,Z_0) \, [$] calculated from above equation, we can turn them into a Z-series with a single stochastic variable [$]Z_1[$] which is different (but not independent of) from both [$]Z_0[$] and [$] Z[$]. So we have an evolution algorithm for SDEs in original variables in the form of equations 6, 7 and 8 after calculation of its moments and finding an appropriate Z-series for it that matches the calculated moments.

The above method also makes use of SDEs very transparent in the sense that we can acquire all information about conditional variances and higher conditional moments and we can match them to empirical phenomenon much more systematically. 

I am thinking of another method that can possibly make use of derivatives of the SDE expression in Z and [$]Z_0[$] to match the Z-series as opposed to using moments to match the Z-series but some ideas are still hazy. If it works out, it would be a lot better algorithm since we would be spared the effort to match the moments for a single final Z-series(which might not possibly work universally all the time and might create some issues from time to time with the present algorithm we have.) If it works out with the derivatives algorithm, I will post the details of derivatives algorithm in next few days here on this forum.

We can also solve for stochastic volatility models in this way but we would need a two dimensional Z-series representation for general stochastic volatility model. We can represent the distribution of asset as one dimensional Z-series in SV models after matching moments but loss of necessary dimensionality would mean that we would not be able to write a proper conditional evolution of the SV SDE conditional on both volatility and and the asset itself. Therefore we would need a two dimensional Z-series for proper evolution of asset in SV system of SDEs. I have calculated most of the details and would present the solution of general SV system of SDEs in a few days.
You think life is a secret, Life is only love of flying, It has seen many ups and downs, But it likes travel more than the destination. Allama Iqbal