1 страниц (7 вхождений)
Using calculation - solve - I don't get it :) - Сообщения
#1 Опубликовано: 21.11.2014 13:47:42
#2 Опубликовано: 21.11.2014 19:23:02
Probably you have an high range in your settings (try Tools -> Calculation -> Roots (range))
I get your result with -1000 .. 1000
Simply use a smaller or better range (f.e. in your example you can set the bottom range to 0)
![2014-11-21 23_24_11-SMath Studio Desktop - [WriterRegion.sm_].png](/ru-RU/file/PsDsnm/2014-11-21-23_24_11-SMath-Studio-Desktop---_WriterRegion_sm___png)
I get your result with -1000 .. 1000
Simply use a smaller or better range (f.e. in your example you can set the bottom range to 0)
If you like my plugins please consider to support the program buying a license; for personal contributions to me: paypal.me/dcprojects
#3 Опубликовано: 22.11.2014 03:07:20
:d Thanx
That solved my problem - I set the roots (range) to -500;500 and the result is now right.
The strange thing is: If I set the range to -1000;1000 and do a solve(sqrt(x)=5;x), the result is right.
Is there any explanation I could tell my users?
Regards
/E
Solve.sm (13 КиБ) скачан 38 раз(а).
That solved my problem - I set the roots (range) to -500;500 and the result is now right.
The strange thing is: If I set the range to -1000;1000 and do a solve(sqrt(x)=5;x), the result is right.
Is there any explanation I could tell my users?
Regards
/E
Solve.sm (13 КиБ) скачан 38 раз(а).
#4 Опубликовано: 22.11.2014 03:36:42
WroteThe strange thing is: If I set the range to -1000;1000 and do a solve(sqrt(x)=5;x), the result is right.
Is there any explanation I could tell my users?
The result only looks right, when showing only the default 4 decimal digits. If you increase precision, you will see the same 25,0000013034682 result.
The solver makes limited number of attempts (by an algorithm) in the specified range; it stops when subsequent attempts give close results (or when it decides that it failed). "Close" is measured relative to the range size. Some ranges may happen to give sequences that result in presize (in terms of machine representation) results; however, generally only some approximation is achieved.
С уважением,
Михаил Каганский
#5 Опубликовано: 22.11.2014 06:08:09
Hi again
It's starting to make sense
The solve function seems to give the correct answer, regardles of number of decimals, range etc.
The [calculate] - [Solve] seems to use a different algoriothm?
Right?
If I set number of decimals to 4, I se the problem with the solve under [Calculate]
If i set the number of decimals to 15, I don't se the problem.
That I don't get
All help and input much appreciated
Best regards
/Erik
SolveI.sm (33 КиБ) скачан 29 раз(а).
It's starting to make sense

The solve function seems to give the correct answer, regardles of number of decimals, range etc.
The [calculate] - [Solve] seems to use a different algoriothm?
Right?
If I set number of decimals to 4, I se the problem with the solve under [Calculate]
If i set the number of decimals to 15, I don't se the problem.
That I don't get

All help and input much appreciated

Best regards
/Erik
SolveI.sm (33 КиБ) скачан 29 раз(а).
#6 Опубликовано: 22.11.2014 08:35:37
I don't recommend the use of the interactive calculation functions because:
1. You (and others) don't see what you have done in order to get the results
2. Source and result are not interlinked, thus you can't easily repeat the calculation with changed input.
I don't see any influence of the decimals setting on the results for the calculation>solve function.
If you want symbolic (exact) solutions, then you can use the function Solve() from the maxima plugin. It is basically a wrapper for the maxima function solve() and comes with the companion function Assign() for further use of the solution in the SMath sheet.
If you want to investigate/teach numerical solution procedures, then the functions from the Nonlinear Solvers plugin are appropriate. They provide an optional log of the iteration history, which can be visualized.
raphson.sm (16 КиБ) скачан 34 раз(а).
1. You (and others) don't see what you have done in order to get the results
2. Source and result are not interlinked, thus you can't easily repeat the calculation with changed input.
I don't see any influence of the decimals setting on the results for the calculation>solve function.
If you want symbolic (exact) solutions, then you can use the function Solve() from the maxima plugin. It is basically a wrapper for the maxima function solve() and comes with the companion function Assign() for further use of the solution in the SMath sheet.
If you want to investigate/teach numerical solution procedures, then the functions from the Nonlinear Solvers plugin are appropriate. They provide an optional log of the iteration history, which can be visualized.
raphson.sm (16 КиБ) скачан 34 раз(а).
Martin Kraska
Pre-configured portable distribution of SMath Studio: https://en.smath.info/wiki/SMath%20with%20Plugins.ashx
1 страниц (7 вхождений)
-
Новые сообщения
-
Нет новых сообщений