## 68 Reputation

15 years, 145 days

## Thanks...

Well, I did know about save command but I was just trying to find out if there is anything more efficient, meaning "gathering all the data in one maplesheet under one file/folder" kind of thing as in Matlab. Thank you, though. Gurs

## parametric...

Thank you , Scott. However, to be able to use optimization commands, you need to define some constraints! I do not need to find numerical values.I need to find an equation that will give the minimum of this integral (Euler-Lagrange equation if I am not wrong). For instance, if you have a polynomial function that you want to minimize with respect to one of the variable, you just differentiate the function wrt that variable and equate it to zero. You cannot do the same for the integral functions. Thanks anyway. Gurs

## ......

I forgot to define the parameters in the integral: z is the independent variable and P(z) is the dependent variable, a, b, c, d, e, f, g, h, L are constants.

## hi again...

Hi again, Isn't there anybody that can help me with this? Allan? To make it more specific: integrate((a*z+b)*P(z)^2+(c*z+d)*P(z)^4+(e*z+f)*P(z)^6+(g*z+h)*diff(P(z),z)^2, z=0..L) How do you find the minimization equation? Thanks Gurs

## !!!...

I am quite confused about it right now. I kind of understand what you are saying and when I tried one of the bcs as P(8e-8)=0.0635 which is the right hand side value of the matlab solution and the other one as D(P)(8e-8)=0, I also got the oscillatory plot! I have to look at the eq again.I was pretty sure it was right, I guess it is not! Allan, you helped enormously. Thank you so very much! I will be back!:) Gurs

## yes...

Yes, Allan, the "exact" problem is as you put in your previous reply. I double checked. I apologize again for my mistake... Thank you very much... G.

## a little mistake......

When I first typed the eq, I made a mistake! P^6 has to be P^5. Sorry! But it still does not change the result in maple! G.

## I just wanted to update the...

I just wanted to update the blog. I am still working on the same problem and if anybody can help me with it, it will be great! Thanks, G.

## Allan, thanks but I cannot...

Allan, thanks but I cannot follow what you did in your computation. Why did you solve A with respect to z?

## I am sorry again... The...

I am sorry again... The correct expression of A is: A=abs(3.0164e14*z-2.8071e7)*(-0.82500e-2*z+3e-9)^2

...

## ?...

You mean a value for P at z=8e-8? No, I do not have a value for that, unfortunately... That would make it a lot easier... And sorry about the typo...

## and the boundary conditions...

I forgot to write the BCs: D(P)(0)=0, D(P)(8e-8)=0; Thanks, G.

## The actual DE...

As I mentioned before the DE is: Eq := A*(diff(P(z), z, z))-alpha_z*P(z)-beta_z*P(z)^3-gamma_z*P(z)^6 = 0 with A:=abs(3.0164*10^14*z-2.8071*10^7)*(-0.82500e-2*z+3.*10^(9()^2; alpha_z:=3.0164*10^14*z-2.8071*10^7; beta_z:=9.9000*10^15*z-5.400*10^8; gamma_z:=6.6e9 (taken as constant for now) Trying to find P(z)... And yes, P(z)=0 at all z's is probably one of the solutions of the DE but that is not one I am looking for as you mentioned. Any help is very much appreciated! G.
 1 2 Page 1 of 2
﻿