Difference between revisions of "Scilab/C4/User-Defined-Input-and-Output/English-timed"

From Script | Spoken-Tutorial
Jump to: navigation, search
(Created page with '{| Border=1 || Time || Narration |- | 00.01 |Welcome to the spoken tutorial onFile handling using Scilab. |- | 00.06. | In this tutorial, we will learn |- |00.08 |'''Inpu…')
 
 
(10 intermediate revisions by 4 users not shown)
Line 1: Line 1:
 
{| Border=1
 
{| Border=1
  
|| Time
+
||''' Time'''
  
|| Narration
+
||''' Narration'''
  
 
|-
 
|-
| 00.01
+
| 00:01
|Welcome to the spoken tutorial onFile handling using Scilab.  
+
|Welcome to the spoken tutorial on '''File handling''' using '''Scilab'''.  
  
 
|-
 
|-
| 00.06.
+
| 00:06
| In this tutorial, we will learn  
+
| In this tutorial, we will learn:
  
 
|-
 
|-
|00.08
+
|00:08
|'''Input''' Function
+
| '''Input Function '''
  
 
|-
 
|-
|00.10
+
|00:10
|'''Formatting the Output'''
+
| '''Formatting the Output'''
  
 
|-
 
|-
| 00.12
+
| 00:12
|'''save '''function
+
| '''save function '''
  
 
|-
 
|-
|00.14
+
|00:14
|'''load''' function
+
| '''load function '''.
 
+
  
 
|-
 
|-
| 00.16
+
| 00:16
|For Demonstration i am using Ubuntu Linux12.04 operating system with Scilab version 5.3.3 installed  
+
|For demonstration I am using '''Ubuntu Linux 12.04''' operating system with '''Scilab version 5.3.3''' installed.
  
 
|-
 
|-
| 00.26
+
| 00:26
| You should have Basic knowledge of '''Scilab.'''  
+
| You should have basic knowledge of '''Scilab.'''  
  
 
|-
 
|-
|00.29
+
|00:29
| If not, for relevant spoken tutorials on Scilab  please visit '''spoken hyphen tutorial dot org'''  
+
| If not, for relevant spoken tutorials on Scilab  please visit '''spoken hyphen tutorial dot org'''.
  
 
|-
 
|-
|00.37
+
|00:37
 
|The '''input()''' function is used to take the input from the user.  
 
|The '''input()''' function is used to take the input from the user.  
  
 
|-
 
|-
|00.42
+
|00:42
 
| It provides a prompt in the text string for user input.  
 
| It provides a prompt in the text string for user input.  
  
 
|-
 
|-
  
| 00.47
+
| 00:47
  
 
| It waits for input from the keyboard.  
 
| It waits for input from the keyboard.  
  
 
|-
 
|-
| 00.51
+
| 00:51
 
| If nothing but a carriage return is entered at the prompt, '''input()''' function returns an empty matrix.  
 
| If nothing but a carriage return is entered at the prompt, '''input()''' function returns an empty matrix.  
 
  
 
|-
 
|-
| 00.59
+
| 00:59
| The '''input''' function can be written in two ways .
+
| The '''input''' function can be written in two ways:
  
 
|-
 
|-
|01.03
+
|01:03
| First ,x= input into brackets message to display   
+
| First, x= input into brackets "message to display"  
  
 
|-
 
|-
|01.09
+
|01:09
|Second,x= input into brackets ("message to display","strings").
+
|second, x= input into brackets ("message to display", "strings").
  
 
|-
 
|-
|01.17
+
|01:17
| In the second example, the second argument is '''“string”.'''
+
| In the second example, the second argument is “string”.  
 
+
  
 
|-
 
|-
|01.22
+
|01:22
|So the output is a character string, which is the expression entered using the keyboard.  
+
|So the output is a character string which is the expression entered using the keyboard.  
 
+
  
 
|-
 
|-
  
|01.29
+
|01:29
  
|Switch to the '''Scilab Console''' window and type,  
+
|Switch to the '''Scilab console''' window and type,  
  
 
|-
 
|-
  
|01.33
+
|01:33
 
+
|'''x is equal to input''' open bracket inside double quotes '''Enter your age''' close the double quotes close the bracket and press enter.
+
  
 +
|'''x is equal to input''' open bracket inside double quotes '''Enter your age''' close the double quotes close the bracket and press '''Enter'''.
  
 
|-
 
|-
  
| 01.49
+
| 01:49
  
|Type 25 and press enter
+
|Type 25 and press Enter.
  
 
|-
 
|-
  
| 01.53
+
| 01:53
|| Now type -->'''y is equal to input ''' into bracket into double quotes '''Enter your age''' close the double quotes comma again inside double quotes write '''string''' close the bracket and press enter
+
|| Now type -->'''y is equal to input ''' into bracket into double quotes '''Enter your age''' close the double quotes comma again inside double quotes write '''string''' close the bracket and press Enter.
  
 
|-
 
|-
  
| 02.14
+
| 02:14
|| type 25 and press enter
+
|| type 25 and press Enter.
  
 
|-
 
|-
  
|02.18
+
|02:18
  
 
|| We see that in both the cases the input we entered through  keyboard, was a number 25.  
 
|| We see that in both the cases the input we entered through  keyboard, was a number 25.  
 
  
 
|-
 
|-
  
|02.25
+
|02:25
  
 
| Now, let us check the type of variable that x and y are.  
 
| Now, let us check the type of variable that x and y are.  
Line 127: Line 121:
 
|-
 
|-
  
|02.30
+
|02:30
  
 
| Let us clear the console using '''clc''' command.  
 
| Let us clear the console using '''clc''' command.  
Line 133: Line 127:
 
|-
 
|-
  
|02.34
+
|02:34
  
 
|We are doing this to validate the use and importance of the argument “string”, given in the second example.  
 
|We are doing this to validate the use and importance of the argument “string”, given in the second example.  
Line 139: Line 133:
 
|-
 
|-
  
|02.42
+
|02:42
  
 
|| To check the type of variable, let us type  
 
|| To check the type of variable, let us type  
Line 145: Line 139:
 
|-
 
|-
  
|02.45
+
|02:45
 
+
| -->'''typeof into brackets x'''and press enter
+
  
 +
| -->'''typeof''' into brackets '''x''' and press Enter.
  
 
|-
 
|-
|02.51
+
|02:51
|similarly; '''typeof(y)''' and press enter
+
|Similarly, '''typeof(y)''' and press Enter.
 
+
  
 
|-
 
|-
| 02.57
+
| 02:57
||You can see it yourself, that the first answer stored in x is of type '''constant''' and  
+
||You can see it yourself that the first answer stored in x is of type '''constant''' and  
 
+
 
+
 
+
  
 
|-
 
|-
 +
| 03:04
 +
||second answer stored in y, with the argument '''“string”''' included in the command, is of '''type string.'''
  
| 03.04
 
||second answer stored in y, with the argument '''“string”''' included in the command, is of '''type string.'''
 
 
|-
 
|-
  
|03.12
+
|03:12
  
 
|| Let us now see how to format the output that is displayed on the console.  
 
|| Let us now see how to format the output that is displayed on the console.  
Line 174: Line 163:
 
|-
 
|-
  
|03.17
+
|03:17
  
 
| This can be done using the '''mprintf()''' function.  
 
| This can be done using the '''mprintf()''' function.  
Line 180: Line 169:
 
|-
 
|-
  
|03.22
+
|03:22
  
 
| '''mprintf()''' function converts, formats and writes data on to the '''Scilab console.'''  
 
| '''mprintf()''' function converts, formats and writes data on to the '''Scilab console.'''  
Line 186: Line 175:
 
|-
 
|-
  
| 03.28
+
| 03:28
  
|| It is an interface for C-coded version of '''printf''' function.  
+
|| It is an interface for C-coded version of '''printf()''' function.  
  
 
|-
 
|-
| 03.34
+
| 03:34
| Let us see an example for this.Switch to the console  
+
| Let us see an example for this. Switch to the console.
  
 
|-
 
|-
|03.38
+
|03:38
| Type-->'''mprintf into bracket into quotes type iteration percent i comma result is colon slash n alpha equal to percentf comma 33 comma 0.535 '''close the bracket,
+
| Type-->'''mprintf''' into bracket into quotes type '''At iteration percent i comma Result is colon slash n alpha is equal to percentf comma 33 comma 0.535''' close the bracket.
  
 
|-
 
|-
|04.12
+
|04:12
| Here 33 will be displayed in place of '''percent i '''and point 535 will be displayed in place of''' percent f''' as a flow, press enter
+
| Here 33 will be displayed in place of '''percent i''' (%i) and point 535 (0.535) will be displayed in place of '''percent f''' (%f) as a flow. Press Enter.
  
 
|-
 
|-
| 04.26
+
| 04:26
| This will give the output as  '''At iteration 33, Result is alpha is equal to 0.535000. '''  
+
| This will give the output as  '''At iteration 33, Result is alpha is equal to 0.535000.'''  
  
 
|-
 
|-
| 04.39
+
| 04:39
 
|Clear the console. Now let us see another example.
 
|Clear the console. Now let us see another example.
 
 
  
 
|-
 
|-
| 04.44
+
| 04:44
| In '''print f''' open bracket into quotes '''value of x is equal to percentage d is taken as a constant comma while value of y is equal to percent s is taken as a string '''close the quotes comma '''x '''comma '''y '''close the bracket  
+
| '''mprintf open bracket''' into quotes '''Value of x is equal to percentage d is taken as a CONSTANT comma while value of y is equal to percent s is taken as a STRING '''close the quotes '''comma x comma y''' close the bracket.
  
 
|-
 
|-
| 05.19
+
| 05:19
|In the above example percentage d is used to insert a constant data stored in variable x and  
+
|In the above example percentage d (%d) is used to insert a constant data stored in variable x and  
  
 
|-
 
|-
|05.28
+
|05:28
| '''percentage s''' is used to insert a '''string''' data stored in variable y. press enter you see the output  
+
| '''percentage s''' (%s) is used to insert a '''string''' data stored in variable y. press Enter, you see the output.
 
|-
 
|-
| 05.38
+
| 05:38
| Now, let us discuss the use of save and load command.  
+
| Now, let us discuss the use of '''save''' and '''load''' commands.  
  
 
|-
 
|-
  
| 05.43
+
| 05:43
 
+
|To quit '''Scilab midway''' through a calculation and to
+
 
+
  
 +
|To quit '''Scilab''' midway through a calculation and to
  
 
|-
 
|-
  
| 05.47
+
| 05:47
|| continue to a later stage type '''save thissession'''
+
|| continue at a later stage, type '''save thissession'''.
 
+
 
+
  
 
|-
 
|-
  
|05.52
+
|05:52
  
 
||This will save the current values of all variables to a file called '''thissession.'''  
 
||This will save the current values of all variables to a file called '''thissession.'''  
 
 
  
 
|-
 
|-
  
|05.58
+
|05:58
  
 
||This file cannot be edited.  
 
||This file cannot be edited.  
Line 258: Line 239:
 
|-
 
|-
  
| 06.01
+
| 06:01
  
 
|It is in '''binary''' format.  
 
|It is in '''binary''' format.  
 
  
 
|-
 
|-
  
| 06.04
+
| 06:04
  
 
| When you next start Scilab, type '''load thissession'''
 
| When you next start Scilab, type '''load thissession'''
  
 
|-
 
|-
|06.08
+
|06:08
 
| and the computation can be resumed where you left off.  
 
| and the computation can be resumed where you left off.  
 
 
  
 
|-
 
|-
  
| 06.13
+
| 06:13
 
+
| The purpose of '''save''' and '''load''' function are
+
 
+
  
 +
| The purpose of '''save''' and '''load''' functions are
  
 
|-
 
|-
  
|06.16
+
|06:16
 
+
||The '''save()''' command saves all the '''scilab''' current variables in a binary file.
+
  
 +
||The '''save()''' command saves all the '''Scilab''' current variables in a binary file.
  
 
|-
 
|-
  
|06.22
+
|06:22
  
 
| If the variable is a graphic handle, the '''save''' function saves all the corresponding graphics_entities definition.  
 
| If the variable is a graphic handle, the '''save''' function saves all the corresponding graphics_entities definition.  
 
 
  
 
|-
 
|-
  
| 06.31
+
| 06:31
 
+
| The file can be given either by its paths or by its descriptor previously given.
+
 
+
  
 +
| The file can be given either by its path or by its descriptor previously given.
  
 
|-
 
|-
  
| 06.37
+
| 06:37
  
 
|'''save(filename)''' saves all the current variables in a file defined by filename.  
 
|'''save(filename)''' saves all the current variables in a file defined by filename.  
 
  
 
|-
 
|-
  
| 06.45
+
| 06:45
 
+
| '''save into bracket fd''' saves all the current variables in the file defined by the descriptor fd.
+
 
+
  
 +
| '''save into bracket fd''' saves all the current variables in the file defined by the descriptor '''fd'''.
  
 
|-
 
|-
  
| 06.53
+
| 06:53
 
+
| '''save(filename,x,y) or save(fd,x,y)''' saves only named variables x and y.
+
 
+
  
 +
| '''save(filename,x,y)''' or '''save(fd,x,y)''' saves only named variables '''x''' and '''y'''.
  
 
|-
 
|-
  
| 07.02
+
| 07:02
 
+
||Let us see an example to illustrate the save and load commands usage.
+
 
+
  
 +
||Let us see an example to illustrate the '''save''' and '''load''' commands usage.
  
 
|-
 
|-
  
| 07.07
+
| 07:07
 
+
||Switch back to the console . Let us define two matrices say a and b
+
  
 +
||Switch back to the console. Let us define two matrices, say a and b.
  
 
|-
 
|-
  
| 07.14
+
| 07:14
  
||-->'''a = eye of (2,2)''' and press enter
+
||-->'''a = eye''' of '''(2,2)''' and press Enter.
  
 
|-
 
|-
  
| 07.22
+
| 07:22
 
+
|Type;'''b=ones(a)''' and press enter
+
  
 +
|Type '''b=ones(a)''' and press Enter.
  
 
|-
 
|-
  
| 07.28
+
| 07:28
 
+
|Clear the console using clc command. Now type
+
  
 +
|Clear the console using '''clc''' command. Now type
  
 
|-
 
|-
  
|07.34
+
|07:34
 
+
|-->''' save space matrix dash a dash b'''
+
 
+
  
 +
|'''save''' space '''matrix''' dash '''a''' dash '''b'''
  
 
|-
 
|-
  
|07.42
+
|07:42
 
+
| or it can also be written as
+
 
+
  
 +
| or it can also be written as:
  
 
|-
 
|-
  
| 07.46
+
| 07:46
 
+
| '''save  into brackets into quotes '''matrix dash a dash b dot dat'''  close the quotes comma  a comma  b close the braket  '''and press enter
+
 
+
  
 +
| '''save into brackets into quotes matrix dash a dash b dot dat''' close the quotes '''comma a comma b''' close the bracket  and press Enter.
  
 
|-
 
|-
  
|08.03
+
|08:03
 
+
|| This saves the values of variables in a binary file '''matrix dash a dash b dot dat''' in the present working directory.
+
 
+
  
 +
|| This saves the values of variables in a binary file 'matrix dash a dash b dot dat' (matrix-a-b.dat) in the present working directory.
  
 
|-
 
|-
  
| 08.12
+
| 08:12
  
 
| You can browse the present working directory to check the existence of this binary file.   
 
| You can browse the present working directory to check the existence of this binary file.   
 
|-
 
|-
  
| 08.17
+
| 08:17
  
 
|You can see it here. I will close the file browser.  
 
|You can see it here. I will close the file browser.  
Line 409: Line 362:
 
|-
 
|-
  
| 08.22
+
| 08:22
  
 
| Now let us load the file back in to the variables.  
 
| Now let us load the file back in to the variables.  
 
 
  
 
|-
 
|-
  
| 08.26
+
| 08:26
  
| Before this, let us clear the variables '''a and b '''
+
| Before this, let us clear the variables '''a and b '''.
  
 
|-
 
|-
  
| 08.29
+
| 08:29
  
| Type  '''clear a space b ''' press enter
+
| Type  '''clear a''' space '''b''', press Enter.
  
 
|-
 
|-
  
| 08.34
+
| 08:34
  
 
| Let us cross check if these variables are really cleared.  
 
| Let us cross check if these variables are really cleared.  
 
  
 
|-
 
|-
  
| 08.39
+
| 08:39
  
| ->'''a  '''  
+
| ->'''a  ''' , '''b'''
  
 
|-
 
|-
  
| 08.40
+
| 08:41
  
|'''b'''
+
| Now let us load back the values from the binary files in these variables a and b using the '''load command'''.
  
 
|-
 
|-
  
| 08.41
+
| 08:49
  
| Now let us load back the values from the binary files in these variables a and b using the load command.  
+
|Type: '''load into bracket into quote matrix dash a dash b dot dat''' close the quotes '''comma into quotes a comma into quotes b''' close the bracket and press Enter.  
  
 
|-
 
|-
  
| 08.49
+
| 09:08
 
+
|Type ''' Load '''into bracket into quote '''matrix dash a dash b dot dat''' close the quotes comma into quotes '''a comma''' into quotes '''b''' close the bracket and press enter
+
 
+
|-
+
 
+
| 09.08
+
  
 
| Let us check the values in variables a and b. Clear the console.  
 
| Let us check the values in variables a and b. Clear the console.  
Line 466: Line 410:
 
|-
 
|-
  
| 09.14
+
| 09:14
 
+
| Type >a And-->b
+
 
+
  
 +
| Type -->a and-->b
  
 
|-
 
|-
  
| 09.18
+
| 09:18
  
 
| You can see the values are loaded back in the variables.  
 
| You can see the values are loaded back in the variables.  
Line 480: Line 422:
 
|-
 
|-
  
| 09.23
+
| 09:23
  
| In this tutorial we learnt -  
+
| In this tutorial we learnt - Input function using '''input''' command
  
 
|-
 
|-
  
| 09.24
+
| 09:28
 
+
| Input Function using '''input''' command
+
  
 +
| Formatting the output using''' mprintf''' command
  
 
|-
 
|-
  
| 09.28
+
| 09:31
  
| Formatting the Output using''' mprintf''' command
+
| '''save''' function
  
 
|-
 
|-
  
| 09.31
+
| 09:33
  
| '''Save Function '''
+
| '''load''' function
  
 
|-
 
|-
  
| 09.33
+
|09:35
 
+
| '''Load Function'''
+
  
 +
| Watch the video available at the link shown below.
 
|-
 
|-
  
|09.35
+
| 09:38
 
+
| Watch the video available at the link shown below
+
|-
+
 
+
| 09.38
+
 
+
| It summarises the Spoken Tutorial project
+
 
+
  
 +
| It summarizes the Spoken Tutorial project.
  
 
|-
 
|-
  
|09.41
+
|09:41
  
||If you do not have good bandwidth, you can download and watch it  
+
||If you do not have good bandwidth, you can download and watch it.
  
 
|-
 
|-
  
|09.46
+
|09:46
  
||The spoken tutorial Team
+
||The spoken tutorial Team:
  
 
|-
 
|-
  
|09.48
+
|09:48
 
+
||Conducts workshops using spoken tutorials
+
  
 +
||Conducts workshops using spoken tutorials.
  
 
|-
 
|-
  
|09.51
+
|09:51
 
+
||Gives certificates to those who pass an online test
+
  
 +
||Gives certificates to those who pass an online test.
  
 
|-
 
|-
  
|09.54
+
|09:54
 
+
||For more details, please write to conatct@spoken-tutorial.org
+
  
 +
||For more details, please write to conatct@spoken-tutorial.org.
  
 
|-
 
|-
  
|10.01
+
|10:01
 
+
|Spoken Tutorial Project is a part of the Talk to a Teacher project
+
 
+
  
 +
|Spoken Tutorial Project is a part of the Talk to a Teacher project.
  
 
|-
 
|-
  
| 10.05
+
| 10:05
  
 
| It is supported by the National Mission on Eduction through ICT, MHRD, Government of India.  
 
| It is supported by the National Mission on Eduction through ICT, MHRD, Government of India.  
 
|-
 
|-
  
| 10.12
+
| 10:12
  
|More information on this mission is available at  http://spoken-tutorial.org/NMEICT-Intro
+
|More information on this mission is available at  http://spoken-tutorial.org/NMEICT-Intro.
  
 
|-
 
|-
  
| 10.23
+
| 10:23
  
|This is Anuradha Amrutkar from IIT Bombay signing off.
+
|This is Anuradha Amrutkar from IIT Bombay, signing off.
  
 
|-
 
|-
  
|10.26
+
|10:26
  
 
| Thank you for joining.
 
| Thank you for joining.

Latest revision as of 11:43, 10 March 2017

Time Narration
00:01 Welcome to the spoken tutorial on File handling using Scilab.
00:06 In this tutorial, we will learn:
00:08 Input Function
00:10 Formatting the Output
00:12 save function
00:14 load function .
00:16 For demonstration I am using Ubuntu Linux 12.04 operating system with Scilab version 5.3.3 installed.
00:26 You should have basic knowledge of Scilab.
00:29 If not, for relevant spoken tutorials on Scilab please visit spoken hyphen tutorial dot org.
00:37 The input() function is used to take the input from the user.
00:42 It provides a prompt in the text string for user input.
00:47 It waits for input from the keyboard.
00:51 If nothing but a carriage return is entered at the prompt, input() function returns an empty matrix.
00:59 The input function can be written in two ways:
01:03 First, x= input into brackets "message to display"
01:09 second, x= input into brackets ("message to display", "strings").
01:17 In the second example, the second argument is “string”.
01:22 So the output is a character string which is the expression entered using the keyboard.
01:29 Switch to the Scilab console window and type,
01:33 x is equal to input open bracket inside double quotes Enter your age close the double quotes close the bracket and press Enter.
01:49 Type 25 and press Enter.
01:53 Now type -->y is equal to input into bracket into double quotes Enter your age close the double quotes comma again inside double quotes write string close the bracket and press Enter.
02:14 type 25 and press Enter.
02:18 We see that in both the cases the input we entered through keyboard, was a number 25.
02:25 Now, let us check the type of variable that x and y are.
02:30 Let us clear the console using clc command.
02:34 We are doing this to validate the use and importance of the argument “string”, given in the second example.
02:42 To check the type of variable, let us type
02:45 -->typeof into brackets x and press Enter.
02:51 Similarly, typeof(y) and press Enter.
02:57 You can see it yourself that the first answer stored in x is of type constant and
03:04 second answer stored in y, with the argument “string” included in the command, is of type string.
03:12 Let us now see how to format the output that is displayed on the console.
03:17 This can be done using the mprintf() function.
03:22 mprintf() function converts, formats and writes data on to the Scilab console.
03:28 It is an interface for C-coded version of printf() function.
03:34 Let us see an example for this. Switch to the console.
03:38 Type-->mprintf into bracket into quotes type At iteration percent i comma Result is colon slash n alpha is equal to percentf comma 33 comma 0.535 close the bracket.
04:12 Here 33 will be displayed in place of percent i (%i) and point 535 (0.535) will be displayed in place of percent f (%f) as a flow. Press Enter.
04:26 This will give the output as At iteration 33, Result is alpha is equal to 0.535000.
04:39 Clear the console. Now let us see another example.
04:44 mprintf open bracket into quotes Value of x is equal to percentage d is taken as a CONSTANT comma while value of y is equal to percent s is taken as a STRING close the quotes comma x comma y close the bracket.
05:19 In the above example percentage d (%d) is used to insert a constant data stored in variable x and
05:28 percentage s (%s) is used to insert a string data stored in variable y. press Enter, you see the output.
05:38 Now, let us discuss the use of save and load commands.
05:43 To quit Scilab midway through a calculation and to
05:47 continue at a later stage, type save thissession.
05:52 This will save the current values of all variables to a file called thissession.
05:58 This file cannot be edited.
06:01 It is in binary format.
06:04 When you next start Scilab, type load thissession
06:08 and the computation can be resumed where you left off.
06:13 The purpose of save and load functions are
06:16 The save() command saves all the Scilab current variables in a binary file.
06:22 If the variable is a graphic handle, the save function saves all the corresponding graphics_entities definition.
06:31 The file can be given either by its path or by its descriptor previously given.
06:37 save(filename) saves all the current variables in a file defined by filename.
06:45 save into bracket fd saves all the current variables in the file defined by the descriptor fd.
06:53 save(filename,x,y) or save(fd,x,y) saves only named variables x and y.
07:02 Let us see an example to illustrate the save and load commands usage.
07:07 Switch back to the console. Let us define two matrices, say a and b.
07:14 -->a = eye of (2,2) and press Enter.
07:22 Type b=ones(a) and press Enter.
07:28 Clear the console using clc command. Now type
07:34 save space matrix dash a dash b
07:42 or it can also be written as:
07:46 save into brackets into quotes matrix dash a dash b dot dat close the quotes comma a comma b close the bracket and press Enter.
08:03 This saves the values of variables in a binary file 'matrix dash a dash b dot dat' (matrix-a-b.dat) in the present working directory.
08:12 You can browse the present working directory to check the existence of this binary file.
08:17 You can see it here. I will close the file browser.
08:22 Now let us load the file back in to the variables.
08:26 Before this, let us clear the variables a and b .
08:29 Type clear a space b, press Enter.
08:34 Let us cross check if these variables are really cleared.
08:39 ->a , b
08:41 Now let us load back the values from the binary files in these variables a and b using the load command.
08:49 Type: load into bracket into quote matrix dash a dash b dot dat close the quotes comma into quotes a comma into quotes b close the bracket and press Enter.
09:08 Let us check the values in variables a and b. Clear the console.
09:14 Type -->a and-->b
09:18 You can see the values are loaded back in the variables.
09:23 In this tutorial we learnt - Input function using input command
09:28 Formatting the output using mprintf command
09:31 save function
09:33 load function
09:35 Watch the video available at the link shown below.
09:38 It summarizes the Spoken Tutorial project.
09:41 If you do not have good bandwidth, you can download and watch it.
09:46 The spoken tutorial Team:
09:48 Conducts workshops using spoken tutorials.
09:51 Gives certificates to those who pass an online test.
09:54 For more details, please write to conatct@spoken-tutorial.org.
10:01 Spoken Tutorial Project is a part of the Talk to a Teacher project.
10:05 It is supported by the National Mission on Eduction through ICT, MHRD, Government of India.
10:12 More information on this mission is available at http://spoken-tutorial.org/NMEICT-Intro.
10:23 This is Anuradha Amrutkar from IIT Bombay, signing off.
10:26 Thank you for joining.

Contributors and Content Editors

Gaurav, PoojaMoolya, Pratik kamble, Sandhya.np14