Welcome Guest! To enable all features please Login. New Registrations are disabled.

Notification

Icon
Error

Login


Options
Go to last post Go to first unread
Offline hawe  
#1 Posted : 14 April 2020 20:48:19(UTC)
hawe


Rank: Advanced Member

Groups: Registered
Joined: 30/03/2020(UTC)
Posts: 31
Germany
Location: KU

Was thanked: 3 time(s) in 2 post(s)
Not even the examples of the script will work.

Testfunction

Maxima native
/* [wxMaxima: input start ] */
KN(K0,q,n,R):=K0*q^n+R*q*(q^n-1)/(q-1);
/* [wxMaxima: input end ] */
//* [wxMaxima: input start ] */
solve(KN(K0,1+0.025/12,120,600)=150000,K0), numer;
/* [wxMaxima: input end ] */
[K0=53070.8653044463]

It is possible to
MaximaDefine(KN(K0,q,n,R):=K0*q^n+R*q*(q^n-1)/(q-1)) ?
got a curious respose - maxima def in log was KN():--- should be KN():=---
give the function to <CustomLoadCommands>
but no success..

some attempts e.g. 6.11.1

Greenshot Editor_2020-04-14_19-28-26.jpg

any idea set maxima to work
Portable 6884



Wanna join the discussion?! Login to your SMath Studio Forum forum account. New Registrations are disabled.

Offline hawe  
#2 Posted : 14 April 2020 22:49:23(UTC)
hawe


Rank: Advanced Member

Groups: Registered
Joined: 30/03/2020(UTC)
Posts: 31
Germany
Location: KU

Was thanked: 3 time(s) in 2 post(s)
Originally Posted by: Jean Giraud Go to Quoted Post

You forgot to attach the work sheet !


Excuse me MaximaVersuche.sm (14kb) downloaded 11 time(s).
need to push the upload button, too ;-)

remember I have placed
<CustomLoadCommands>
<Command>KN(K0,q,n,R):=K0*q^n+R*q*(q^n-1)/(q-1);</Command>
</CustomLoadCommands>
because
MaximaDefine(KN:=...)
has not worked - should it do?
Offline hawe  
#3 Posted : 15 April 2020 23:54:25(UTC)
hawe


Rank: Advanced Member

Groups: Registered
Joined: 30/03/2020(UTC)
Posts: 31
Germany
Location: KU

Was thanked: 3 time(s) in 2 post(s)
Unfortunately my first maxima example delivered about 350 digit fraction that was beyond the number limits of SMath - confusing me.

Originally Posted by: Jean Giraud Go to Quoted Post
Why complicate matters ?

What meaning does eval have?

This was not my question, but I think I found some answers.

Get only a reasonable answer from Maxima if I use symbolic evaluation.
But this indicates the next one...
How to process the anwser of Maxima (copy&paste is not realy helpful)
SMath Studio 0.99.6884 - [KreditRechner.VideoMitschnitt.sm]_2020-04-15_22-22-50.jpg




I made a video session to this page to show what my intensions are:



Offline hawe  
#4 Posted : 16 April 2020 12:27:36(UTC)
hawe


Rank: Advanced Member

Groups: Registered
Joined: 30/03/2020(UTC)
Posts: 31
Germany
Location: KU

Was thanked: 3 time(s) in 2 post(s)
Originally Posted by: Jean Giraud Go to Quoted Post


I don't use Maxima plug-in except as delivered with native SS.



I found the explanation in Kraska-script 6.11.1

(Assign(Max(K.Mx))-1)*12=0.0289

Assign turns the equation into an assignment
Offline mkraska  
#5 Posted : 17 April 2020 20:19:04(UTC)
mkraska


Rank: Advanced Member

Groups: Registered
Joined: 15/04/2012(UTC)
Posts: 1,980
Germany

Was thanked: 1120 time(s) in 718 post(s)
Originally Posted by: hawe Go to Quoted Post


I found the explanation in Kraska-script 6.11.1

(Assign(Max(K.Mx))-1)*12=0.0289

Assign turns the equation into an assignment


Yes. This hint is also found in the dynamic help. Assign also works for function results from ODE2()

2020-04-17 19_13_36-SMath Studio 0.99.7251 - [Kurbel.sm_].png
Martin Kraska

Pre-configured portable distribution of SMath Studio: https://smath.com/wiki/SMath_with_Plugins.ashx
thanks 1 user thanked mkraska for this useful post.
on 17/04/2020(UTC)
Offline hawe  
#6 Posted : 17 April 2020 22:38:12(UTC)
hawe


Rank: Advanced Member

Groups: Registered
Joined: 30/03/2020(UTC)
Posts: 31
Germany
Location: KU

Was thanked: 3 time(s) in 2 post(s)
Originally Posted by: mkraska Go to Quoted Post

Yes. This hint is also found in the dynamic help. Assign also works for function results from ODE2()


Ja - gelesen schon - aber nicht verstanden :-)

Und weil mein erster Versuch gleich am Zahlenlimit scheiterte und das log doch ein Ergebnis angezeigt hab ich an ganz anderer Stelle gesucht - mir war auch nicht klar, dass nur die symbolische Auswertung sinnvoll ist. Vielleicht ein fetter Hinweis im Skript? ;-)

Aber wenn Sie schon mal da sind.

Wie ist das mit MaximaDefine?
Im ersten Post ist die Problemstelle noch sichtbar - da häng ich immer noch.
Ich werd nicht ganz schlau daraus - es ist wohl keine Funktionsdef (mit :=) möglich , nur Zuweisungen ( mit : ) in Maxima?
Im Video zum Schluß lass ich Maxima meine Anuitätenformel auf die verschiedenen Variablen umstellen und auf dem Arbeitsblatt (siehe Bild) hab ich MaximaDefine so eingesetzt wie ichs verstanden hab.
Könnten Sie mal einen Blick drauf werfen? Und ggf. was dazu sagen...
Vielen Dank für die Hinweise!

SMath Studio 0.99.6884 - [KreditRechner.VideoMitschnitt.sm]_2020-04-17_21-29-02.jpg

Edited by user 17 April 2020 22:39:44(UTC)  | Reason: How to avoid Smiley replacements?

Offline Jean Giraud  
#7 Posted : 18 April 2020 00:48:17(UTC)
Jean Giraud

Rank: Guest

Groups: Registered
Joined: 04/07/2015(UTC)
Posts: 6,868
Canada

Was thanked: 980 time(s) in 808 post(s)
... from native Smath SS 6179.

SOLVEwisely.PNG
Offline mkraska  
#8 Posted : 18 April 2020 20:14:54(UTC)
mkraska


Rank: Advanced Member

Groups: Registered
Joined: 15/04/2012(UTC)
Posts: 1,980
Germany

Was thanked: 1120 time(s) in 718 post(s)
Originally Posted by: hawe Go to Quoted Post
Originally Posted by: mkraska Go to Quoted Post

Yes. This hint is also found in the dynamic help. Assign also works for function results from ODE2()


Ja - gelesen schon - aber nicht verstanden :-)

Und weil mein erster Versuch gleich am Zahlenlimit scheiterte und das log doch ein Ergebnis angezeigt hab ich an ganz anderer Stelle gesucht - mir war auch nicht klar, dass nur die symbolische Auswertung sinnvoll ist. Vielleicht ein fetter Hinweis im Skript? ;-)

Aber wenn Sie schon mal da sind.

Wie ist das mit MaximaDefine?
Im ersten Post ist die Problemstelle noch sichtbar - da häng ich immer noch.
Ich werd nicht ganz schlau daraus - es ist wohl keine Funktionsdef (mit :=) möglich , nur Zuweisungen ( mit : ) in Maxima?
Im Video zum Schluß lass ich Maxima meine Anuitätenformel auf die verschiedenen Variablen umstellen und auf dem Arbeitsblatt (siehe Bild) hab ich MaximaDefine so eingesetzt wie ichs verstanden hab.
Könnten Sie mal einen Blick drauf werfen? Und ggf. was dazu sagen...
Vielen Dank für die Hinweise!


I'll respond in english, otherwise we create noise without signal in this forum for many users. In case of problems please use your preferred online translator.

As to mandatory usage of symbolic (or even better: none) optimization for symbolic Maxima results: I did as you said, added a hint. A new handbook version is ready since some months, just waiting for a new stable SMath Studio version to make final adjustments.

As to MaximaDefine: To be honest, I have no clue what you try to do with MaximaDefine. For details see the interactive handbook (in the extension manager), goto Function index> MaximaDefine(). BTW, I just saw that information on Maxima define is missing in the Handbuch, I'll add this.

Do you think that realroots from Maxima is more powerful than solve() or roots() in native SMath? If there is evidence for this, we could provide direct access (much like Solve() is just a wrapper for maxima's solve().

You should be able to get LL directly with Solve(eqn,R). eqn being your equation which you assigned to Kn.

MaximaVersuche.png MaximaVersuche.sm (13kb) downloaded 11 time(s).

Martin Kraska

Pre-configured portable distribution of SMath Studio: https://smath.com/wiki/SMath_with_Plugins.ashx
Offline hawe  
#9 Posted : 28 April 2020 23:18:13(UTC)
hawe


Rank: Advanced Member

Groups: Registered
Joined: 30/03/2020(UTC)
Posts: 31
Germany
Location: KU

Was thanked: 3 time(s) in 2 post(s)
Originally Posted by: mkraska Go to Quoted Post



Meanwhile I prepare a project to cubic splines in a very simple basic matter.
I have generated the coefficients of the polynoms

for(j,range(1,(rows(X)-1)),for(i,range(0,3),el(vars,(j-1)*4+i+1):str2num(concat("a",num2str(j),num2str(i)))))

==>mat(a10,a11,a12,a13,a20,a21,a22,a23,a30,a31,a32,a33,a40,a41,a42,a43,1,16)

I build the lin Equ system and solve it in Maxima, it seems to me Assign doesn't do assignment.


VAR should have the values of aij after Assign?



BTW:
I tried to simplify (ratsimp, expand) the cubic polynoms - Maximalog shows simplified functions, but Optimization nullifies it. After setting to none I get the true term from Maxima back - it took me a while to figure it out.

Edited by user 29 April 2020 11:57:20(UTC)  | Reason: Not specified

Offline mkraska  
#10 Posted : 29 April 2020 00:11:59(UTC)
mkraska


Rank: Advanced Member

Groups: Registered
Joined: 15/04/2012(UTC)
Posts: 1,980
Germany

Was thanked: 1120 time(s) in 718 post(s)
Originally Posted by: hawe Go to Quoted Post
Originally Posted by: mkraska Go to Quoted Post



Meanwhile I prepare a project to cubic splines in a very simple basic matter.
I have generated the coefficients of the polynoms

for(j,range(1,(rows(X)-1)),for(i,range(0,3),el(vars,(j-1)*4+i+1):str2num(concat("a",num2str(j),num2str(i)))))

==>mat(a10,a11,a12,a13,a20,a21,a22,a23,a30,a31,a32,a33,a40,a41,a42,a43,1,16)

I build the lin Equ system and solve it in Maxima, it seems to me Assign doesn't do assignment.
...

VAR should have the values of aij after Assign?

BTW:
I tried to simplify (ratsimp, expand) the cubic polynoms - Maximalog shows simplified functions, but Optimization nullifies it. After setting to none I get the true term from Maxima back - it took me a while to figure it out.



1. No need to wrap Maxima() around Solve(). Solve() is known to SMath Studio via the plugin, just as Assign.
2. You need to actually execute the Assign() call by requesting a result. Otherwise nothing will happen. You could also write Assign(Solve( ))= and you get solutions and assignments in a single cell.
3. It is always a good idea to switch off optimization for symbolic Maxima results.
4. Processing equation-shaped results using at() is absolutely ok.

2020-04-28 22_59_42-SMath Studio 0.99.7251 - [SplinesABC.sm_].png
Martin Kraska

Pre-configured portable distribution of SMath Studio: https://smath.com/wiki/SMath_with_Plugins.ashx
Offline Jean Giraud  
#11 Posted : 29 April 2020 03:04:38(UTC)
Jean Giraud

Rank: Guest

Groups: Registered
Joined: 04/07/2015(UTC)
Posts: 6,868
Canada

Was thanked: 980 time(s) in 808 post(s)
Originally Posted by: hawe Go to Quoted Post
Meanwhile I prepare a project to cubic splines in a very simple basic matter.

Cubic spline per say Smath cinterp(X,Y,x) is universal...
1/1 Mathematica, Matlab, Mathcad, Smath ...
Added to "cinterp(X,Y,x) => lsplne, pspline, fintegrate, dspline.
All, ready to use as exemplified in the attached, native Smath.

Cheers ... Jean

Maths EDU Reconciliation [l_p_c_splines SEGMENTS].sm (60kb) downloaded 12 time(s).
Maths EDU Reconciliation [l_p_c_splines].sm (76kb) downloaded 12 time(s).
thanks 1 user thanked Jean Giraud for this useful post.
on 29/04/2020(UTC)
Offline Jean Giraud  
#12 Posted : 30 April 2020 01:41:37(UTC)
Jean Giraud

Rank: Guest

Groups: Registered
Joined: 04/07/2015(UTC)
Posts: 6,868
Canada

Was thanked: 980 time(s) in 808 post(s)
... refreshed Edu style.

Maths EDU Reconciliation [l_p_c_splines SEGMENTS].sm (65kb) downloaded 17 time(s).
thanks 1 user thanked Jean Giraud for this useful post.
on 30/04/2020(UTC)
Users browsing this topic
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.