PD Lab Record
PD Lab Record
AIM
The purpose of Microsoft Word documents is to create,
edit, and format text-based documents for various
purposes. Microsoft Word is a widely used word
processing software that provides a range of features
and tools to facilitate the creation and manipulation of
documents.
Home tab
The Home tab is the default tab in the Microsoft Word. It
has five subdivided groups of related commands;
Clipboard, Font, Paragraph, Styles and Editing. The
home tab helps you change document settings like font
size, adding bullets, adjusting styles and many other
common features and allows you to return to the home
section of the document.
Insert tab
Insert Tab is the second tab in the Ribbon and as the
name suggests, it is used to insert or add extra features
in your document. It is most commonly used to add
tables, pictures, clip art, shapes, page number, etc. The
Insert tab has seven different groups of related
commands that are Pages, Tables, Illustrations, Links,
Header & Footer, Text and Symbols.
Design tab
The Design tab allows the user to adjust the organization
and visual structure, of the document. The first option to
change in the upper left-hand corner of the tab is a
Design Theme. Clicking on the Themes icon will launch a
drop-down box with a large variety of templates for
document themes.
Layout tab
It allows you to control the look and feel of your
document, i.e., you can easily change the page size,
margins, line spacing, indentation, documentation
orientation, etc. The Page Layout tab has five different
groups of related commands that are Themes, Page
Setup, Page Background, Paragraph and Arrange.
References tab
It allows you to enter document sources, citations,
bibliography commands, etc. It also offers commands for
you to create a table of contents, an index, table of
contents and table of authorities. The References tab has
six different groups of related commands that are Table
of Contents, Footnotes, Citations & Bibliography,
Captions, Index and Table of Authorities.
Mailings tab
It is the fifth tab in this ribbon and probably the least-
often used tab of all the tabs available in this Ribbon. It
allows you merge emails, write and insert different
fields, preview results and convert a file into the PDF
format. The Mailings tab now has five groups of related
commands; Create, Start Mail Merge, Write & Insert
Fields, Preview Results and the Finish command.
Review tab
It offers you some important commands to modify your
document. It also helps you proofread your content, add
or remove comments, track new changes, etc. The
Review tab has a total of six groups of related
commands; Proofing, Comments, Tracking, Changes,
Compare and Protect.
View tab
The View tab is located next to the Review tab and
allows you to switch between Single Page and Two Page
views. It also enables you to control various layout tools
such as boundaries, guides and rulers. Its primary
purpose is to offers you several different ways to view
your document. This tab has five groups of related
commands which are Document Views, Show/Hide,
Zoom, Window and Macros.
Help tab
The Help tab provides access to this help file (Online
Help), which can also be accessed at any time by
pressing the F1 key. In addition, this menu also contains
a number of links to specific important information and
how-to topics in the help and some useful links to the EC
Software website.
"Expand Ribbon"
"Collapse Ribbon"
To stop scrolling:
"Line Up"
"Line Down"
"Page Up"
"Page Down"
To close a document:
To Save As:
To print a document:
Uses of MS Word
Given below are the different fields in which MS
Word is used and simplifies the work of an
individual:
OUTCOME:
In conclusion, MS Word provides several benefits for
academic writing and research projects. It is user-
friendly, provides formatting options, collaboration and
sharing tools, citation and referencing features,
templates, spell and grammar check, auto-save, and ease
of access.
MS EXCEL
AIM
Microsoft Excel enables users to format, organize and
calculate data in a spreadsheet. By organizing data using
software like Excel, data analysts and other users can
make information easier to view as data is added or
changed.
What is MS Excel?
MS Excel is a Microsoft Office application developed by
Microsoft. The Excel Spreadsheet Software supports
multiple operating systems such as Windows, Mac OS,
Android, Ios, and iPad OS. It is used to perform
calculations and computations using various functions
and formulas present in Excel. Users can store and
analyze the data whenever they needed.
Ribbon tabs
The standard Excel ribbon contains the following tabs,
from left to right:
File – allows you to jump into the backstage view that
contains the essential file-related commands and Excel
options. This tab was introduced in Excel 2010 as the
replacement for the Office button in Excel 2007 and the
File menu in earlier versions.
Home – contains the most frequently used commands
such as copying and pasting, sorting and filtering,
formatting, etc.
OUTCOME:
Excel is a powerful tool for data management, allowing
you to perform advanced calculations, create graphical
representations of data, and manage real-time
collaboration with others. Mastering Excel can enhance
your efficiency at work, make data organization easier,
and serve as a powerful collaboration tool.
MS POWER POINT
AIM
It is a powerful tool used to create presentations. It
provides everything you need to create a professional
presentation. PowerPoint contains graphic tools and
word processing tools and is easy to use. PowerPoint are
created from a series of slides.
WHAT IS POWERPOINT?
Microsoft PowerPoint is a presentation design
software that is part of Microsoft 365. This software
allows you to design presentations by combining text,
images, graphics, video, and animation on slides in a
simple and intuitive way.
WHAT ARE THE COMPONENTS OF POWERPOINT
WORKSPACE?
PowerPoint Main Window
The first aspect to learn is PowerPoint Main Window. To
facilitate the explanation, we've organized its main
elements with numbers from 1 to 10:
Based on that, the main components of PowerPoint
window are the following:
1. Quick Access Toolbar: allows you to customize
commands to have them at hand. You only have to select
it and go to "More commands."
2. Title Bar: shows you the name of your file. These
options will vary depending on the use you give to the
commands.
3. File Tab: you will see the Home Menu (PowerPoint
backstage) by selecting it. There, you can create a new
presentation, save it, print it, export it, and many other
options.
4. The Ribbon: it's where Power point tabs and tools
are. These tools can also be called "commands" or
“features.”
5. More Button or Down Arrow: these arrows allow
you to view more tools or layout options in PowerPoint.
6. Slides Pane: shows your slides in thumbnail size. By
right-clicking, you can access additional options for
customizing each slide. Perfect for PowerPoint
beginners!
7. Slide: PowerPoint's blank canvas and the frame to be
seen when presenting the file.
8. Placeholders: they are dotted boxes that will store
your content.
9. Status Bar: allows you to view the slide number,
grammatical errors, speaker notes, and the comments on
your file.
10. Zoom: allows you to enlarge or minimize your
PowerPoint workspace. The range goes from 10 to 400%.
POWERPOINT TABS
The PowerPoint tabs are the control desk of your
presentation. Since PowerPoint's features are too many,
they're organized in tabs.
You can come and go between tabs as you need. Once
you click on a tab, it will open its ribbon, and there,
you'll be able to see all the tools related to that
particular category.
Home Tab
Insert Tab
Design Tab
Transitions Tab
Animations Tab
Slide Show Tab
Review Tab
View Tab
Recording Tab
Help Tab
1. Home Tab
The Home tab is the most common tab of PowerPoint.
This is the tab you'll probably use the most if you're
designing a presentation deck from scratch.
4. Transitions Tab
Using transitions in PowerPoint is a dynamic way to
move from one slide to the next during a presentation.
7. Review Tab
With this tab, you can check the slide's spelling,
translate the text in real-time, and add comments
to your slides.
8. View Tab
This View tab allows you to change the view of your
PowerPoint slides and make handouts from them,
among other things.
POWERPOINT FEATURE
Insert SmartArt
The SmartArt feature lets you create and customize
designer-quality diagrams. You can even convert bulleted
lists into a diagram using the SmartArt diagram tools.
1. Click the Insert tab.
2. Click the SmartArt button on the ribbon.
You can also click the SmartArt icon in a content
placeholder.
3. Select a category.
4. Select a graphic.
A preview and a description appear on the right.
5. Click OK.
Relations
Illustrate connections.
hip
Insert a chart
Use a chart when you want your audience to easily
understand a large quantity of data and the relationships
between parts of the data. A chart is often much better
at presenting information visually than hard-to-read
numbers in a table.
Chart Types
Insert an equation
Certain equations are pre-defined because they are used
frequently in algebra and trigonometry, such as
the Pythagorean Theorem and the Quadratic
Formula. The Equation Editor offers to use pre-defined
equations instead of re-creating them.
To insert the equation into the slide, do the following:
1. Do one of the following:
Select the placeholder or position the cursor in the
text to insert the equation at the specified place.
Unselect objects on a slide to create a new object for
an equation. Thus, PowerPoint inserts a new text
box in the middle of the slide.
2. On the Insert tab, in the Symbols group, click
the Equation button, and choose one of the equations
from the gallery:
MATLAB PROGRAMS
ENTER COMMAND
TASK 1:
Multiply the numbers 4 and 2 with the command 4*2
4*2
Output: 8
TASK 2:
Assign the result of 4*2 to a variable named m as shown, m=4*2
m=4*2
Output: m=8
TASK 3:
Enter the command m=m+1 to see what happens
m=m+1
Output: m=9
TASK 4:
Create a variable named y that has the value of m/2
y=m/2
Output: y = 4.5
TASK 5:
Enter k=8-2; including the semicolon at the end
K=8-2;
Output: k=6
TASK 6:
Edit the command m=4*2 to be m=3*k
m=3*k
Output: m=18
TASK 7:
In task 4, you calculated the value of y using the value of m. Recalculated
value of y using modified m in task 6?
y
Output: 9
NAME VARIABLES
TASK 1:
Create a variable named A with the value -2
A= -2
Output: A= -2
TASK 2:
Use A and a to calculate (a+A)/2. Store the result in a variable named
meanAa
meanAa = (a+A)/2
Output: meanAa=3
TASK 2:
Empty the workspace using the clear command
Clear
TASK 3:
Load the variables from the file datafile.net
Load datafile
TASK 4:
Display the contents of the variable data
3.0000 0.5300 4.0753 NaN
Data
18.0000 1.7800 6.6678 2.1328
= 19.0000 0.8600 1.5177 3.6852
20.0000 1.6000 3.6375 8.5389
21.0000 3.0000 4.7243 10.1570
23.0000 6.1100 9.0698 2.8379
38.0000 2.5400 5.3002 4.4508
TASK 5:
Clear the command window using the clc command
clc
USE BUILT-IN FUNCTIONS AND CONSTANTS
TASK 1:
Create a variable named x with the value of x/2
x = pi/2
Output: x=1.5708
TASK 2:
Calculate the sin of x by using the sin function. Assign the result to a
variable named y
y = sin(x)
Output: y = 1
TASK 3:
Calculate the square root of -9 by using the sqrt function. Assign the result
to a variable named z
Z = sqrt(-9)
Output: Z = 0.0000+3.0000i
RUN SCRIPTS
TASK 1:
Modify the command for task 1 so that r has value of 0.5
r = 0.5
Output: r = 0.5000
Calculate area:
x = pi*r^2
Output: x = 0.7854
TASK 2:
Create an array named y with two elements: 7 and 9
y = [7 9]
Output: y = 7 9
TASK 3:
Create an array named z with two elements, 7 and 9 in a single
column by changing the space between them to a semicolon (;)
z = [7;9]
Output: z =
7
9
TASK 4:
Create a new vector named a that contains the values 3, 10 and 5 In
that order.
a = [3 10 5]
Output: a =
3 10 5
46
TAS
TASK 5:
Create a column vector named b that contains the values 8, 2 and -4
in that order.
b = [5 6 7; 8 9 10]
Output: b =
8
2
-4
TASK 6:
Create a matrix named c with these values.
5 6 7
8 9 10
c = [5 6 7; 8 9 10]
Output: c =
5 6 7
8 9 10
TASK 7:
Create a row vector named d that contains sqrt(10) as the first
element and pi^2 as the second element.
d = [sqrt(10) pi^2]
Output: d =
3.1623 9.8696
47
CREATE EVENLY SPACED VARIABLES
TASK 1:
Create a row vector named x that contains the values 1, 2 and 3 in
that order.
x = [1 2 3]
Output: x =
1 2 3
TASK 2:
Create a row vector named y with integer values from 1 to 10, using
the : operator
y = [1:10]
Output: y =
1 2 3 4 5 6 7 8 9 10
TASK 3:
Create a new vector named z that starts at 1, ends at 5, with each
element separated by 0.5
z = [1:0.5:5]
Output: z =
1.0 1.5 2.0 2.5 3.0 3.5 4.0 4.5 5.0
TASK 4:
Create a row vector named a that starts at 3 and ends at 13, with
each element spaced by 2.
48
a = [3:2:13]
Output: a =
3 5 7 9 11 13
TASK 5:
Create a row vector named b that starts at 1 and ends at 10, and
contains 5 elements
b = linspace(1,10,5)
Output: b =
1.0000 3.2500 5.5000 7.7500 10.0000
TASK 6:
Transpose b from a new vector to a column vector using the
transpose operator
b = b’
Output: b =
1.0000
3.2500
5.5000
7.7500
10.0000
TASK 7:
In a single command create a column vector named c that starts at 5
and ends at 9, and has elements that are spaced by
c = (5:2:9)’
output: c =
49
5
7
9
TASK 2:
Create a column vector that contains 5 rows and 1 column by the
rand function. Assign the result to a variable named y
y = rand(5,1)
Output: y =
0.7577
0.7431
0.3922
50
0.6554
0.1762
TASK 3:
Create a matrix of all zeros that has 6 row and 3 columns by using
the zeros function. Assign the result to a variable named z
z = zeros(6,3)
Output: z =
0 0 0
0 0 0
0 0 0
0 0 0
0 0 0
0 0 0
51
Create a variable x that contains the values in the 6th row and 3rd
column of the variable data
x = data(6,3)
Output: x = 9.0968
TASK 2: Extract the value in the last row and 3rd column of the
variable data by using the end keyword. Assign this value to a
variable named y.
y = data(end,3)
Output: y = 5.3002
TASK 3:
Create a variable z that contains the value in the second to last (end-
1) row and 3rd column of the data
z = data(end-1,3)
Output: z = 9.0698
52
TASK 1:
Create a column vector named density that contains all the elements
of the 2nd column of the matrix named data
Density = data(:,2)
Output: density =
0.5300
1.7800
0.8600
1.6000
3.0000
6.1100
2.5400
TASK 2:
Create a variable volumes that contains the last two columns of
data.
volumes = data(:,3:4)
Output: volumes =
4.0753 NaN
6.6678 2.1328
1.1517 3.6852
3.6375 8.5389
4.7243 10.1570
9.0698 2.8729
5.3002 4.4508
53
TASK 3:
Create a variable named p containing the 6th element of the vector
density
p = density(6)
Output: p = 6.1100
TASK 4:
Create a vector named q containing the 2nd through 5th element of
density
q = density(2:5)
Output: q =
1.7800
0.8600
1.6000
3.0000
TASK 2:
Change the first element of v2 from NaN to 0.5
v2(1) = 0.5
Output: v2 =
0.5000
2.1328
3.6852
8.5389
10.1570
2.8729
4.4508
55
TASK 3:
Change the element in the first row and last column of data to 0.5
data(1,end) = 0.5
Output: data =
3.0000 0.5300 4.0753 0.5000
18.0000 1.7800 6.6678 2.1328
19.0000 0.8600 1.1517 3.6852
20.0000 1.6000 3.6375 8.5389
21.0000 3.0000 4.7243 10.1570
23.0000 6.1100 9.0698 2.8729
38.0000 2.5400 5.3002 4.4508
TASK 1:
56
Add 1 to each element of v1 and store the result in a variable named
r
r = 1 + v1
Output: r =
5.0753
7.6678
2.5177
4.6375
5.7243
10.0698
6.3002
TASK 2:
Create a vector vs that is the sum of the vectors v1 and v2
vs = v1 + v2
Output: vs =
4.5753
8.8006
5.2029
12.1764
14.8813
11.9437
9.7510
TASK 3:
Create a variable va that contains the vector vs divided by 2
va = vs/2
Output: va=
2.2877
4.4003
57
2.6014
6.0882
7.4406
5.9718
4.8755
TASK 4:
Create a variable vm that contains the maximum of va
vm = max(va)
Output: vm = 7.4406
TASK 5:
Using the round function, create a variable named vr that contains
the rounded elements of va
vr = round(va)
Output: vr =
2
4
3
6
7
6
5
TASK 6:
Create a variable named mass that contains the element wise
product of density and va
mass = density.*va
58
Output: mass =
1.2125
7.8325
2.2372
9.7411
22.3220
36.4880
12.3838
TASK 2:
Create the variables dr and dc that respectively contains the number
of rows and columns of variable data
[dr , dc] = size(data)
Output:
dr = 7
dc = 4
TASK 3:
Create the variables vMax and ivMax containing the maximum
value of the v2 vector and the corresponding index value,
respectively
59
[vMax, ivMax] = max(v2)
Output:
vMax = 10.1570
ivMax = 5
DOCUMENTATION
TASK 1:
Create a matrix named x that:
Contains random integers in the range from 1 to 20
Has 5 rows
Has 7 columns
x = randi(20,5,7)
Output: x =
17 2 4 3 14 16 15
19 6 20 9 1 15 1
3 11 20 19 17 8 6
19 20 10 16 19 14 1
13 20 17 20 14 4 2
PLOT VECTORS
TASK 1:
Create a plot with sample on the x-axis and mass1 on the y-axis
plot(sample,mass1)
Output:
60
TASK 2:
Plot mass2(y-axis) against sample(x-axis). Use red(r) and (*)
markers and no line in your plot
plot(sample,mass2,”r*”)
Output:
TASK 3:
Enter the hold on command.
Then plot mass1 against sample with black (k) and square (s)
markers
61
hold on
plot(sample,mass1,”ks”)
Output:
TASK 4:
Enter the hold off command
hold off
Output:
TASK 5:
62
Plot the vector v1
Plot(v1)
Output:
TASK 6:
Plot v1 with a line width of 3
plot(v1,”Linewidth”,3)
Output:
63
TASK 7:
Plot v1 against sample with red and circle markers and a solid line.
Use a line width of 4
plot(sample,v1,”ro-“,”Linewidth”,4)
Output:
ANNOTATE PLOTS
TASK 1:
Add the title “Sample Mass” to the plot
title(“Sample Mass”)
Output:
64
:
TASK 2:
Add the label “Mass (g)” by using the ylabel function
ylabel(“Mass (g)”)
Output:
TASK 3:
Create a legend with the labels “Exp A” and “Exp B”
65
legend(“Exp A”,”Exp B)
Output:
66
TASK 1:
Assign the contents of elements.Density to a column vector d
d = elements.Density
Output: d =
0.5300
1.7800
0.8600
1.6000
3
6.1100
2.5400
TASK 2:
Multiply each element of elements.Density with elements.volume1.
Assign the result to elements. Mass
elements.Mass = elements.Density.*elements.Volume1
Output:
67
6. “vanadium” 6.1100 9.0698 2.8739 55.4146
7. “strontium” 2.5400 5.3002 4.4508 13.4626
TASK 3:
Sort the table from the smallest to the largest mass
Elements = sortrows(elements,”Mass”)
Output:
LOGICAL INDEXING
TASK 1:
Test if pi is less than 4 by using the relational operator <. Assign the
output to a variable named x.
x = pi < 4
Output: x = logical 1
68
TASK 2:
Test the vector v1 for elements that are less than 4. Assign the output
to a variable named y
y = v1 < 4
Output: y =
0
0
1
1
0
0
0
TASK 3:
Create a variable z that contains all the elements of v1 that are less
than 4
z = v1(v1 < 4)
Output: z =
1.5177
3.6375
TASK 4:
Create a variable a that contains the elements of sample
corresponding to where v1 is less than 4
a = sample(v1 < 4)
Output: a =
19
20
69
TASK 5:
Modify v1 so that any value less than 4 is replaced with the value 0
v1(v1 < 4)
Output: v1 =
4.0753
6.6678
0
0
4.7243
9.0698
5.3002
DECISION BRANCHING
TASK 1:
Modify the script so that the plotting code on lines 5-8 exactly only if
doPlot is 1
If doPlot == 1
plot(density)
title(“Sample Densities”)
xticklabels(element)
ylabel(“Density (g/cm^3)”)
end
Output:
70
TASK 2:
Modify the script so that when the if condition is not satisfied, this
line of code executes
Disp(“ The density of “ +
element…..
+ “ is ” + density)
If doPlot == 1
plot(density)
title(“Sample Densities”)
xticklabels(element)
ylabel(“Density (g/cm^3)”)
else
disp(“ The density of “ + element……
+ “ is ” + density)
End
71
Output:
FOR LOOPS
TASK 1:
Wrap the code on lines 4-5 of the live script in a for loop so that the
code executes 10 times.
Name the loop counter idx. For the first execution of loop, idx
should have a value of 1, and it should increase by 1 in each
consecutive iteration
hold on
for idx = 1:10
plot(idx, density(idx),”*”)
drawnow
end
hold off
72
Output:
STELLAR MOTION
DATA
nObs = 357
lambdaStart = 630.020
lambdaDelta = .1400
TASK 1:
Create a variable named lambdaEnd that contains the value of last
wavelength I the reorded spectrum. You can calculate lambdaEnd
with the expression
λstart+(nObs−1)λdelta.
lambaEnd = lambdaStart + (nObs – 1) * lambdaDelta
lambda = (lambdaStart : lambdaDelta : lambdaEnd)
Output: lambdaEnd = 679.0200
lambda =
73
630.020 630.160 630.300 630.440
630.580…….
TASK 2:
Extract the sixth column of spectra to a vector named s
s = spectra(: , 6)
Output: s = 10^-12 *
0.1625
0.1630
0.1615
0.1586
0.1574
0.1589
0.1611
0.1607
0.1593
0.1582
TASK 3:
Plot the spectra as a function of wavelength. Use point markers and
a solid line to connect the points
plot(lambda,s,”.-“)
xlabel(“Wavelength”)
ylabel(“Intensity”)
Output:
74
TASK 4:
Create two variables, sHa and idx, that contain the minimum value
of s and the index of that minimum value
[sHa, idx] = min(s)
lambdaHa = lambda(idx)
Output: sHa = 9.8010e-14
idx = 191
lambdaHa = 656.6200
TASK 5:
Add a point to the existing axes by plotting x=lambdaHa, y=sHa as a
red square (“rs”) with a marker size of 8
hold on
plot(lambda,sHa,”rs”,”MarkerSize”,8)
75
Output:
TASK 6:
Calculate the red shift factor and the speed at which the star is
moving away from the earth. Assign the red shift factor to a variable
named z and the speed to a variable named speed
z = lambdaHa/656.28 – 1
Speed = z*299792.458
Output: z = 5.1807e-04
Speed = 155.3139
77
Output: speed =
-36.5445
-100.4973
-36.5445
27.4083
27.4083
155.3139
-228.4029
TASK 2:
Create a for loop with a loop index named v. The loop index should
progress through all columns of spectra
for v = 1:7
s = spectra(:,V);
end
Output:
10^-12* 10^-12* 10^-13* 10^-13* 10^-12* 10^-12* 10^-
13*
0.3088 0.1340 0.5981 0.8919 0.1088 0.1625
0.3918
0.3136 0.1338 0.6074 0.9152 0.1084 0.1630
0.3821
0.3105 0.1357 0.6176 0.9311 0.1104 0.1615
0.3712
0.3076 0.1354 0.6252 0.9355 0.1124 0.1586
0.3776
78
0.3088 0.1343 0.6271 0.9321 0.1122 0.1574
0.3910
0.3105 0.1335 0.6221 0.9286 0.1136 0.1589
0.3955
0.3122 0.1325 0.6249 0.9240 0.1138 0.1611
0.4023
: : : : : :
:
TASK 3:
Add an if statement to the for loop body. If speed is less than or equal to
0. Create a plot of s against lambda using a dashed line. Add the
command hold on between the two end keywords.
for v = 1:7
S = spectra(:,v);
If speed(v) <= 0
Plot(lambda,s,”--”)
end
hold on
end
Output:
79
TASK 4:
Add an else statement. If speed is greater than 0, create a plot of s
against lambda using a line width of 3. After the for loop enter the
hold off command.
for v = 1:7
s = spectra(:,v);
if speed(v) <= 0
plot(lambda,s,”--”)
else
plot(lambda,s,”LineWidth”,3)
end
hold on
end
hold off
Output:
80
TASK 5:
Add a legend to the plot by using the array starnames
Legend(starnames)
Output:
TASK 6:
81
Create a variable movaway that contains the elements in starnames
corresponding to where speed is greater than 0
Movaway = starnames(speed > 0)
Output: movaway =
“HD 5211”
“HD 56030”
“HD 94028”
Result :
Thus all the Codings of MATLAB Onramp was executed and the
output was obtained successfully.
82