160 Reputation

6 Badges

10 years, 136 days

MaplePrimes Activity

These are questions asked by Annonymouse

I have a system of ODEs with parameters, p[i], and variables, x[i].

f := [

associated with the innitial conditions:
[x[1](0) = p[2], x[2](0) = p[3]].

I have sets of parameters that i am interested in

[p[1] = 1, p[2] = 2, p[3] = 3]
[p[1] = 2, p[2] = 2, p[3] = 7]
[p[1] = 3, p[2] = 2, p[3] = 11]
[p[1] = 4, p[2] = 2, p[3] = 15]
[p[1] = 5, p[2] = 2, p[3] = 19]
[p[1] = 6, p[2] = 2, p[3] = 23]
and so on.

The solutions for these equations appear to be anisotropic scalings of each other.


/xh[1]\ =/1 0\ /x[1]\      
\xh[2]/   \0 q/ \x[2]/

where x is the variable for one parameter vector and xh is the variable for another; and q is a nuimber I am interesting in working out (and think may be p[1]).

how do you work out q?

[this is in fact a complicated way of asking when I numerically integrate an ODE on maple how do i get access to the sequence of numbers in the result]


I have an ODE with 3 parameters
diff(B[1](t), t) = piecewise(t < 1000, kaC*(R-B[1](t))-k[d1]*B[1](t), 1000 < t, -k[d1]*B[1](t))

I'd like to make a graph that shows how its solution vary as Kac and Kd vary. This could have an axis of the form:

            | /k[d]
  B(t)  |/_ __

which could contain a surface composed of the solutions as k[d] varies. Then a series of surfaces could be put together on the same axis to show what happens as kaC varies.

Some typical values are:

kaC = 6*10^(-2),
k[d1] = 7*10^(-3),
R = 1

I'd like to graph everything  in two orders of magnitude of these values for KaC and k[d1].

Currently I think the key obstacle is making a surface of solutions to the ODE; as once I can do that I think making a sequence of them on the same axis should be quite simple with Display




I'm trying to better understand the Black and Scholes model; which is a scalar function on (positive reals)^5.
a maplesoft worksheet defines it as


I am trying to understand the parameter vectors (r ,T,K,S[0],sigma) that give the same values of BS_Price - and particularly whether these form curves, closed curves, surfaces or similar.

Right now, I am not sure how to procede.

I've just put together  a procedure that evaluates BS at points in R^5 - and i think i can move forward by using the curry or rcurry functions to get a 5d tensor of the values of BS, that i can start to look for patterns within.

BS_Price := proc (InterestRate, StockPrice, StrikePrice, Duration, Volatility) evalf(subs([r = InterestRate, S[0] = StockPrice, K = StrikePrice, T = Duration, sigma = Volatility], exp(-r*T)*(-(1/2)*erf((1/4)*sqrt(2)*(sigma^2*T-2*r*T+2*ln(K)-2*ln(S[0]))/(sigma*sqrt(T)))+1/2))) end proc

could anyone give me advice on doing this?

I have a hard to understand quotient of multivariate polynomials- my intuition is that the denominator nearly divides the numerator - and it could be rewritten as:

remainder+(much simpler numerator)/denominator

as far as I can see the functions quo and rem aren't designed for this - but I'm certain that people in the maple community must have overcome this kind of problem before

I have an object in 6d I'd like to visualise. The region of 6d space I am interested in is described by these equations:

{f[10] = -(.2000000000*(5.*f[21]*f[20]*f[22]-5.*f[20]*f[22]^2+20.*f[20]*f[21]-20.*f[20]*f[22]+135.*f[20]+46.*f[21]))/(f[21]*(f[21]-1.*f[22])),
f[11] = -1.*f[22]-4.,
f[12] = -(1.*(f[22]^2+4.*f[22]-27.))/f[21],
f[20] = f[20],
f[21] = f[21],
f[22] = f[22]}

clearly the first three variables are dependant, and the latter three are independant. I'd like to graph the first three as the latter three vary between bounds and then colour the points on the output based on where they came from in the input, so i can get some intuition about what these equations mean.

1 2 3 4 5 6 7 Last Page 3 of 15