elango8

151 Reputation

4 Badges

15 years, 130 days

MaplePrimes Activity


These are answers submitted by elango8

I tried the same algorithm that was discussed here to vary one of the parameters other than "w" as i previously posted.It works fine but when i compare the common points between the two the solutions does not match i dont know why,all the inputs are the same.

I hace attached bot the files , and have marked the values in red that i am changing .It would be helpful to know if i have anything written wrong in the code.

Steam_1500_below_cri.mw  - original

Varying_s.mw  - modified

The modified file has a comon point at w=5 and s=-180.476 similar to original file...but the solution is totally different

But negative values are not a viable solution for these variables in a physical sense...is there any other way i could search for the roots that are only positive.....

I replced that K3 by k3 ,but i am still getting the same error as above

Yeah it worked, i was trying the same with " := " which assigns the value , and didnt try " = "...thanks for pointing it

If i do this , i still get the output as a set of expressions without any labels...But this helps if i want to call them else where by using the A[i] label....

What i want is that , when the loop is executed and the results are printed i want them to be like the following :

a[1] = ......

a[2] = ......

and so on

 

 

I am not able to understand this concept but i guess i might have confused you with my wordings in the problem.....i simply want a label ,in the sense...A= ,B=,C=...for the list of expressions being generated in the loop..i do not want to refer to them in any other place

Thanks for your answers,im sorry i confused some of you with my code above...i should have mentioned that variable w = 633.8802 in equ1.

I solved it now with your help.

I am quite new to this and since i dont have much programming background,is there any gud reference books you guys might suggest which could help in coding for iterations and numerical analysis for a beginner.

I read the paper again and found that T(x) has the theoretical maximum of 8 at x=0....but i interpreted this worng and was trying to solve the ode for a 'c' value that wud give me T(x) =8 at the centre.....i solved the ode and was able to find the analytical solutions and they all seem to be less than the theoretical max and they all had their peak at x=0.

Thank you everyone for giving ur inputs and the procedure to find the value of 'c' that makes the slope = 0 at the centre line was really a time saver for me,since the results were so sensitive to the 'c' value.

when i plot the curve it does not satisfy the BC 1 for large values of x on either side of the y axis....i mean since the erf(X) goes to 1 for large values of +- x ...the bc reduces to t(large x value) = 1......no matter wat the c value is. I am not able to figure out why this is so
The only constraint is that for 'c' = 1 thers a trivial solution and the maximum value t(x=0) = 8 is the maximum value,this is fixed....so i am looking or a 'c' value that gives result very close to 8..and the eqn is very sensitive to 'c' value...so it might blow out for small increments( in the class we had a problem which gave very diff answers with changes in 'c' value in the 4th digit ie, 7.9998 gave a diff value than 7.9999 from the first bc...as u cud see the value goes to 1 as we choose any 'c' and value of x smaller than -2....since the erf(values less than or equal to -2) makes it 1. im still working on it
Then i guess the value of 'c' that i assumed in the bc is not appropriate...i took 'c' as 7.5,so may be if i take a different value thers a solution further to the right. So my main goal is to find a value of 'c' that wud give me a peak value of t@(x=0) = 8......since thats the result i want and i have to keep trying with different 'c' values till i get that...the problem indicated that the solution is very sensitive to the value of 'c' in the boundary conditions. Is it possible for me to run this dsolve for various values of 'c' and check the value of t(0) each run..so that it cud stop if its really close to 8 or else continue with next value of c

The solution at c=1 is trivial so i dont want that one....i know that the maximum value at the peak shud be 8....so i have to choose my C such that i get a maximum value close to 8 at x=0.

I did try with the following initial conditions

t(x) = c + (c-1)*erf(x)

 t ' (x) = (c-1)*(2/sqrt(pi))*e^-x2

For C = 7.5 and x = -2

but im not able to solve the ode itself for a single value of c , let alone changing it n finding the correct oneView 10874_ode.mw on MapleNet or Download 10874_ode.mw
View file details

the maple worksheet has been added to show the equations

It works when i made the changes you suggested...Thank you

I used , wvals := [0.2, 0.4, .6, .8, 1, 1.2, 1.4, 1.6, 1.8, 2]; > S := {seq({w = wvals[i]}, i = 1 .. 10)}; sys :={my 7 eqns,with variable w underlined for easy access}: sols := {seq(`union`(fsolve(subs(i, sys)), i), i = S)}; I used this instead of the above sequence that i mentioned and was able to calculate the unknown values at different w. My goal is to find a suitable w where all the unknowns are POSITIVE values. so i can use the range option in fsolve to look for roots only in that range.I know how to do it for a single polynomial equation but how should i include it in this looping ex: if im using fsolve for a single value of w then i can use fsolve({my 7 eqns with w=specified value}, {a1 = 0.. 100, a2 = 0..100,a3=0..100,a4=0..100,a5=0..100,a6=0..100,a7=0..100}) but how should i incorporate this interval in my code so that it finds the roots in this interval while calculating for every w
1 2 Page 1 of 2