dharr

Dr. David Harrington

9207 Reputation

22 Badges

21 years, 304 days
University of Victoria
Professor or university staff
Victoria, British Columbia, Canada

Social Networks and Content at Maplesoft.com

Maple Application Center
I am a retired professor of chemistry at the University of Victoria, BC, Canada. My research areas are electrochemistry and surface science. I have been a user of Maple since about 1990.

MaplePrimes Activity


These are replies submitted by dharr

See https://en.wikipedia.org/wiki/It%C3%B4%27s_lemma#Motivation

where the term with sigma is not involved in the expectation. But then I'm not sure why sigma would remain in the phase factor. 

@salim-barzani Notice that there is a u on the rhs side of the pde, so I expect to be able to cancel the exp parts, and this does work out.

You forgot to differentiate zeta(t) in the pde. And the paper had missing parentheses - if the exp bit is supposed to be the phase factor, then it must be exp(I*(X+Y)) not exp(I*X+Y).

But you still have to set sigma to zero, so I think this has to be part of the way to deal with stochastic pdes. Sigma still appears in the phase factor, so the solution has randomness still.

F-ode-Fpaper.mw

@salim-barzani I was doing this here. But there is still not enough information and the two papers are doing different things.

restart

pde := diff(Omega(x, t), t)-tau*(diff(B(t), t))

diff(Omega(x, t), t)-tau*(diff(B(t), t))

eq := Omega(x, t) = M(x, t)*exp(tau*B(t)-(1/2)*tau^2*t)

Omega(x, t) = M(x, t)*exp(tau*B(t)-(1/2)*tau^2*t)

The exp terms do not disappear unless the last term has tau=0 or diff(B(t),t)=0 or we make tau*B(t)=tau^2*t/2

ode := collect(eval(pde, eq), exp)

(diff(M(x, t), t)+M(x, t)*(tau*(diff(B(t), t))-(1/2)*tau^2))*exp(tau*B(t)-(1/2)*tau^2*t)-tau*(diff(B(t), t))

eval(ode, B(t) = (1/2)*tau*t)

diff(M(x, t), t)-(1/2)*tau^2

If we did this before the pde, we just get a constant term of -tau^2/2 in the pde - This is why you got cancellation of B(t) in pdetest.mw.

eval(pde, B(t) = (1/2)*tau*t)

diff(Omega(x, t), t)-(1/2)*tau^2

But if we do the following, which is what Claude implies (step 5 has -epsilon*M*V to get the cancellation (M should be diff(B(t),t))

pde2 := diff(Omega(x, t), t)-tau*Omega(x, t)*(diff(B(t), t))

diff(Omega(x, t), t)-tau*Omega(x, t)*(diff(B(t), t))

Then the exp terms can cancel

eval(pde2, eq); simplify(%/exp(tau*B(t)-(1/2)*tau^2*t))

(diff(M(x, t), t))*exp(tau*B(t)-(1/2)*tau^2*t)+M(x, t)*(tau*(diff(B(t), t))-(1/2)*tau^2)*exp(tau*B(t)-(1/2)*tau^2*t)-tau*M(x, t)*exp(tau*B(t)-(1/2)*tau^2*t)*(diff(B(t), t))

-(1/2)*M(x, t)*tau^2+diff(M(x, t), t)

But if this was correct, then we wouldn't need to set exp(tau*B(t))=exp(tau^2*t/2), which is one step in the first paper.
On the other hand for the second paper they do set up Eq 1.1 so this cancellation (for some terms) will occur. So the two papers are very different.

Conclusion is that there is insufficient information to know what to do. I suspect there is some hidden assumption in the way the Wiener process works. For example in the second paper, Eq 3.4 has a large epsilon (expectation?) - where did that come from. They do not even mention what it is.

NULL

NULL

Download idea.mw

@salim-barzani I agree about the tau=0. The real problem is earlier, where in both cases the exp() did not cancel. I'll work through the first paper again based on the claude.ai explanation. Some comments on the attached.

pde1.mw

pdetest.mw

@salim-barzani 

In the first paper, eq 4.1 is confusing as I said, but even more so since 4.15 is different yet also gets substituted into 4.2 and afterwards eq 4.20 still has the exp part from eq 4.1. So I can't figure this out.

@salim-barzani Please provide a link to this paper.

Which is the first equation which is wrong. If it is just something with t, note that your T1, which I think is supposed to be Eq. 4.1, has epsilon^2*t/2 but Eq. 4.1 has epsilon^2*t^2/2. You also have function U(w*x-beta*t) there instead of just w*x-beta*t?

This looks correct to me; there is only one u, related to the content. If you look at ?sqrfree it says "u is the content(a,x) times a unit.".

@C_R Yes, it seems like a long way from eval(1/(3+2*sqrt(2))) to the usage above. I guess features keep getting added and the help doesn't keep up. I'm not even sure how I know this usage (more precisely "how I guessed this"); probably from some discussion on this forum.

@salim-barzani I have edited it to say that it was the [4,3,1] case. Here is how I understand what you asked for.

In your question you want to know how to solve all neural net cases. You gave

(1) a paper describing the method and solving Eq 1 for some specific neural networks [4,3,1] and [4,2,2,1] with specific functions.

(2) a worksheet t1.mw for Eq 1 the [4,3,1] case with the same activation functions as in the paper, which leads to an error.

(3) a worksheet t2-true-one.mw for Eq. 1 for the [4,2,2,1] case with the same functions as in the paper.

and the comment "t1 have problem about  first case of layer and t2 dont have problem".

I explained the error in t1.mw, which for some reason you did differently from t2-true-one. So you can now complete that case. In both these cases you used a different methodology before you started the neural net part, so you arrived at different solutions from in the paper.

In response you explained you have a generator for the neural network equation that can be supplied the the type of neural network and any desired functions.

I wanted to understand whether the paper method is somehow different from your method in the sense of what "term" means in "setting the coefficients of each term to zero". So I managed to replicate the paper solution for set 1 of the [4,3,1] case. So at this point you know how to solve Eq. 1 using neural networks, getting two types of solutions (your method in t2-true-one.mw and the paper method using Hirota transformations).

So now you are giving more papers and worksheets, which I am not going to read. I think you want to somehow find all cases. But the paper says "activation function which can be interpreted arbitrarily" (any function) and you already have a generator for the different types of neural network so as far as I can see you have everything you need.

If you are asking for some huge procedure that does everything, then the problem would need to be very carefully specified. Aside from the fact that there is a lot of work doing argument checking etc., I have been reluctant to make such procedures in the past for two reasons: (1) you jump between different types of equations, methodologies, numbers of parameters etc and so the problem description is insufficiently precise, and (2) I want to provide lines of code that are simple enough that you can understand them and modify them yourself (my background as an educator I guess).

You should not use =0 if you are going to use numer(normal(...)) or collect etc. That was the main error. I didn't attempt to follow the logic, but coeff doesn't work on a set.

t1.mw

@sand15 I was aware of the ambiguity in natural numbers. In New Zealand we learnt that it started with 1.
Note that with 3 sign changes, the number of positive solutions is 3 or 1 (multiples of two less than the number of sign changes is also possible).

But the cubic is probably the way to go; large integer solutions may come from finding integer/rational points on elliptic curves.

@sand15 I assume by natural numbers are meant {1,2,3,...}, i.e., not including zero.

@Alfred_F @vv So the case I chose is not a Holditch curve, in the notation of the Monterde and Rochera paper. But empirically it still seems to have area/ab = Pi. 

@acer Yes, missed that and I misread cos(x),sin(x*y)  as cos(x)*sin(x*y) and was focused on the issue with the parameter part of the dsolve procedure. It would be easier if the OP uploaded a worksheet.

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