blob: 9948ba2c112e6f8d78a36271a8d0740aad2e79b4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
|
//Ex:4.1
clc;
clear;
close;
V_m=20;//in volts
f=50;//in Hz
t1=2.5*10^-3;
t2=15*10^-3;
V1=V_m*sin(2*%pi*f*t1);
V2=V_m*sin(2*%pi*f*t2);
printf("Voltage at 2.5ms = %f V",V1);
printf("\n Voltage at 15ms = %f V",V2);
|