Ramakrishnan

Dr. Ramakrishnan Vaidyanathan

259 Reputation

5 Badges

4 years, 360 days

Social Networks and Content at Maplesoft.com

I have retired as Professor-Mechanical in Sri Venkateswara College of Engineering and Technology under Anna University affiliated colleges in Tamil Nadu, India. I have 19 years of Industrial and 20 years of teaching experience. I am learning Maple for the past four and half years hoping to make at least one appreciable maple presentation.

MaplePrimes Activity


These are questions asked by Ramakrishnan

Please find my error in the doc which produces outputlines always. Is there any otherway (other than view -  show contents and uncheck output which hides all other outputs as well in a programm) by commands, which can suppress these output lines.

Also is there any other way of giving continuously varying inputs (and visible in RotaryGauge ) like sin wave form (0 to 8 to 0 in a period) ?

                                                                                         
with(DocumentTools); for i to 12 do SetProperty("RotaryGauge0", value, 6); SetProperty("RotaryGauge1", value, .66*GetProperty("RotaryGauge0", value))*time*[]; 3^100; GetProperty("RotaryGauge0", value); SetProperty("RotaryGauge0", value, 4); SetProperty("RotaryGauge1", value, .7*GetProperty("RotaryGauge0", value))*time[real](); 3^100; SetProperty("RotaryGauge0", value, 2); SetProperty("RotaryGauge1", value, .5*GetProperty("RotaryGauge0", value))*time[real](); 3^100 end do

515377520732011331036461129765621272702107522001

(1)

``


 

Download varying_input.mwvarying_input.mw

?

Can any one correct my code in module for it to work. The procedure is just add 2 and return.My_Module_Mistake.mw
 

restartaction1:-Mproc(2)

Error, `action1` does not evaluate to a module

 

action1:-Mproc(2)

Error, `action1` does not evaluate to a module

 

with(MathematicalFunctions);
action1:=module ()
        export Mproc,y;
                Mproc:= proc (n)
                        y:=n+2;                
                end proc;
end module()


 

Download My_Module_Mistake.mw

 

I am importing an excel worksheet xlsx file in to a datafile. Though the formatting in excel is perfect with 3 decimals, the data table stores many values in 14 decimals. How do I convert? What is the command? Can any one help me.

I enclose the doc and excel file for reference and use. I tried in many ways, but failed to convert.MP1_Data.xlsxDoubt_NumberFormat_in_DataTable.mw
 

NULL

 

``

27.90

(1)

BTE := evalf(2.3)*Import("E:/A_PhD2017/MP1_Data.xlsx", "Brake_Thermal_Efficiency")

``

``


 

Download Doubt_NumberFormat_in_DataTable.mw

 

I want to obtain a report in a particular table format in TextArea component.REPORT (TextArea)area and ComboBox are not visble here.

Can any one help me? TextBox_Format_Output_Request.mw
 

restart

z := "Maple1"; x := "Map"; y := "Maple2"; x1 := 9.080787; y1 := 9.98765; z1 := 8.090909

I have done it using the print format directly with variable values. This is fine for me.

Maple:        Maple:     Map

  9.9876:   9.0808       8.1

 

I have done it differently defining a variable for the print format. This is fine for me and required as standard.

y3 := "%-2.5s:        %2.5s:     %2.5s\n  %-2.5g:   %-2.5g       %-3.2g\n", z, y, x, y1, x1, z1

printf(y3)

Maple:        Maple:     Map
  9.9876:   9.0808       8.1

 

 

Now I want these two lines as per format print  inside textarea0 named REPORT.

``

                                 

 

SetProperty("REPORT", Value, "")``

 

 

``

 

 

``


 

Download TextBox_Format_Output_Request.mw

I attach the doc for clarity of my odoubt. I have made all the required compoennets commands except for the formatting of printf formaat. Thanks for help.

Ramakrishnan V

mathcontainerUses_Doubt.mw
 

restart; d[1] := [2.36, 26.90], [2.75, 30.0], [3.14, 31.9], [3.53, 32.8], [3.93, 33.4], [4.32, 32.8], [4.71, 31.9]

[2.36, 26.90], [2.75, 30.0], [3.14, 31.9], [3.53, 32.8], [3.93, 33.4], [4.32, 32.8], [4.71, 31.9]

(1)

NULL

d[2] := [2.36, 32.40], [2.75, 34.90], [3.14, 36.90], [3.53, 38.00], [3.93, 38.40], [4.32, 37.8], [4.71, 36.5]

[2.36, 32.40], [2.75, 34.90], [3.14, 36.90], [3.53, 38.00], [3.93, 38.40], [4.32, 37.8], [4.71, 36.5]

(2)

d[3] := [2.36, 27.9], [2.75, 28.3], [3.14, 30.0], [3.53, 30.9], [3.93, 31.3], [4.32, 30.8], [4.71, 29.7]

[2.36, 27.9], [2.75, 28.3], [3.14, 30.0], [3.53, 30.9], [3.93, 31.3], [4.32, 30.8], [4.71, 29.7]

(3)

y := a*x^2+b*x+c; for i to 3 do d[i] := [d[i]]; c[i] := CurveFitting[LeastSquares](d[i], x, curve = y) end do

HFloat(8.047886108501745)+HFloat(11.793324911833839)*x-HFloat(1.5172878997894277)*x^2

(4)

 

curve1 := [c[1], c[2]]; k[1] := [1, 2]; curve1p := [d[1], d[2]]; l[1] := "plot 1"

"plot 1"

(5)

curve2 := [c[2], c[3]]; k[2] := [2, 3]; curve2p := [d[2], d[3]]; l[2] := "plot 2"

"plot 2"

(6)

curve3 := [c[1], c[3]]; k[3] := [1, 3]; curve3p := [d[1], d[3]]; l[3] := "plot 3"

"plot 3"

(7)
Table 1

 

xlabel := "Brake Power"; ylabel := "Efficiency"

"Efficiency"

(8)

p1 := plot(curve1, x = 2.0 .. 5.0, labels = [xlabel, ylabel], labeldirections = ["horizontal", "vertical"], color = [black], linestyle = [1, 2], thickness = [3, 1], title = Title, caption = "Fig. 1 cool  Example 1", legend = ["curve1", "curve2"]); p2 := plot(curve1p, style = point, color = [black], symbol = [soliddiamond, box], symbolsize = 10); plots:-display(p1, p2)

 

p1 := plot(curve2, x = 2.0 .. 5.0, labels = [xlabel, ylabel], labeldirections = ["horizontal", "vertical"], color = [black], linestyle = [1, 2], thickness = [3, 1], title = Title, caption = "Fig. 1 cool  Example 1", legend = ["curve1", "curve2"]); p2 := plot(curve2p, style = point, color = [black], symbol = [box, point], symbolsize = 10); plots:-display(p1, p2)

 

p1 := plot(curve3, x = 2.0 .. 5.0, labels = [xlabel, ylabel], labeldirections = ["horizontal", "vertical"], color = [black], linestyle = [1, 2], thickness = [3, 1], title = Title, caption = "Fig. 1 cool  Example 1", legend = ["curve1", "curve2"]); p2 := plot(curve3p, style = point, color = [black], symbol = [soliddiamond, point], symbolsize = 10); plots:-display(p1, p2)

 

 

"for j from 1 to 3 do  print( Report on l[j]); for i in k[j] do x1(i):=solve((ⅆ)/(ⅆ x)c[i]);  y1(i):=eval( c[i], [x = x1(i)]):  print( Maximum brake thermal efficiency of,y1(i) "%"occurs at brake power value of , x1(i)kW);  end do;  end do;"

Maximum*brake*thermal*efficiency*of, HFloat(30.964188366461613)*"%"*occurs*at*brake*power*value*of, 3.886317459*kW

(9)

NULL


 

Download mathcontainerUses_Doubt.mw

Can any one state the uses of mathcontainer?

1. It can store only one algebraic expression at a time?

2. Can it handle list of algebraic expressions?

3. Can it store list data points (x,y) for a list of curves?

4. Can there be any use for click to edit this component?

More than a simple Yes or No a simple example for each yes answer would be very helpful.

I enclose a document with list of coordinates for for three curves, expression for curve fitting, three expressions derived for these plot points (coordinates), a command for optimum y for each of the three curves (maximum y and corresponding x value), 

Thanks for answering.

Ramakrishnan V

2 3 4 5 6 7 8 Page 4 of 9