blob_id
stringlengths
40
40
directory_id
stringlengths
40
40
path
stringlengths
4
214
content_id
stringlengths
40
40
detected_licenses
listlengths
0
50
license_type
stringclasses
2 values
repo_name
stringlengths
6
115
snapshot_id
stringlengths
40
40
revision_id
stringlengths
40
40
branch_name
stringclasses
21 values
visit_date
timestamp[us]
revision_date
timestamp[us]
committer_date
timestamp[us]
github_id
int64
141k
586M
star_events_count
int64
0
30.4k
fork_events_count
int64
0
9.67k
gha_license_id
stringclasses
8 values
gha_event_created_at
timestamp[us]
gha_created_at
timestamp[us]
gha_language
stringclasses
50 values
src_encoding
stringclasses
23 values
language
stringclasses
1 value
is_vendor
bool
1 class
is_generated
bool
1 class
length_bytes
int64
5
10.4M
extension
stringclasses
29 values
filename
stringlengths
2
96
content
stringlengths
5
10.4M
3b5b6c35e1fc2d40440f9a3118d464cc9b78dfd9
449d555969bfd7befe906877abab098c6e63a0e8
/2792/CH8/EX8.10/Ex8_10.sce
3466cbb4df58dfea7cf8caa413f4595639b9ab85
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
1,546
sce
Ex8_10.sce
clc VB = 100 disp("VB = "+string(VB)+"V") //initializing value of sorce-drain voltage FSi=3*10^5 disp("FSi = "+string(FSi)+"V/cm") //initializing value of breakdown field of Si FGaAs=4*10^5 disp("FGaAs = "+string(FGaAs)+"V/cm") //initializing value of breakdown field of GaAs FSiC=3*10^6 disp("FSiC = "+string(FSiC)+"V/cm") //initializing value of breakdown field of SiC Vsi = 10^7 disp("Vsi = "+string(Vsi)+"cm/s") //initializing value of saturation velocity of Si VGaAs = 10^7 disp("VGaAs = "+string(VGaAs)+"cm/s") //initializing value of saturation velocity of GaAs VSiC = 2*10^7 disp("VSiC = "+string(VSiC)+"cm/s") //initializing value of saturation velocity of SiC LBSi = VB/FSi disp("The minimum channel length at which Si material will breakdown is ,LBSi = VB/FSi = "+string(LBSi)+"cm")//calculation LBGaAs = VB/FGaAs disp("The minimum channel length at which GaAs material will breakdown is ,LBGaAs = VB/FGaAs = "+string(LBGaAs)+"cm")//calculation LBSiC = VB/FSiC disp("The minimum channel length at which SiC material will breakdown is ,LBSiC = VB/FSiC = "+string(LBSiC)+"cm")//calculation fT1 = Vsi/(2*%pi*LBSi) disp("The corresponding cutoff frequency of silicon is ,fT(Si) = Vsi/(2*%pi*LBSi)= "+string(fT1)+"Hz")//calculation fT2 = VGaAs/(2*%pi*LBGaAs) disp("The corresponding frequency of GaAs is ,fT(GaAs) = VGaAs/(2*%pi*LBGaAs)= "+string(fT2)+"Hz")//calculation fT3 = VSiC/(2*%pi*LBSiC) disp("The corresponding cutoff frequency of SiC is ,fT(SiC) = VsiC/(2*%pi*LBSiC)= "+string(fT3)+"Hz")//calculation
71db594274c87a36e4c441c78313f27915f25b6c
449d555969bfd7befe906877abab098c6e63a0e8
/965/CH9/EX9.14/14.sci
487b4324e35c12029e8aab4d1d11f4f1f7255dd1
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
482
sci
14.sci
clc; clear all; disp("heat transfer rate") d=0.06;//m diameter L=1.2;//m ts=50;// degree C tsat=100;//degree C rhol=975;//kg/m^3 mu=375*10^(-6);// Ns/m^2 k=0.67;// W/m.C rhov=0.596;// kg/m^3 hfg=2257*10^3;// J/kg g=9.81;//m/s h=1.13*(rhol*(rhol-rhov)*k^3*g*hfg/(mu*L*(tsat-ts)))^0.25; Q=h*(%pi*d*L)*(tsat-ts); disp("kW",Q/1000,"The rate of heat transfer =") m=Q/hfg;//kg/s disp("kg/h",m*3600,"rate of condensation of steam =") Re=4*m/(%pi*d*mu); disp(Re,"Re =")
a49d83f51054903ed4a3059c089c47132e85930b
449d555969bfd7befe906877abab098c6e63a0e8
/1802/CH5/EX5.5/Exa5_5.sce
bd80d23e03573b19c9553ab573d30e60297c40e5
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
1,114
sce
Exa5_5.sce
//Exa 5.5 clc; clear; close; //Given Data : format('v',9); Vs_line=33*10^3;//in volt cos_fir=0.8;//unitless P_KVA=6000;//in KVA P_KW=P_KVA*cos_fir;//in KW cos_fir=0.8;//unitless impedence=2+%i*6;//in ohm R=real(impedence);//in ohm X=imag(impedence);//in ohm Vs_phase=Vs_line/sqrt(3);//in volt disp("Sending end Voltage, Vs(in Volt) = VR+I*R*cos_fir+I*X*sin_fir "); disp("It gives polynomial p = [1 -Vs_phase P_KVA*10^3*R*cos_fir/sqrt(3)+P_KVA*10^3*X*sin_fir/sqrt(3)].") sin_fir=sqrt(1-cos_fir^2); p=[1 -Vs_phase P_KVA*10^3*R*cos_fir/sqrt(3)+P_KVA*10^3*X*sin_fir/sqrt(3)]; VR=roots(p); VR=VR(1);//(root calculated using -ve sign is discarded in shreedharacharya method) VR_line=VR*sqrt(3);//in volt disp(VR_line/1000,"Line voltage at receiving end(in KV) :"); Regulation=((Vs_line-VR_line)/VR_line)*100;//unitless disp(Regulation,"% Regulation : "); I=P_KVA*10^3/(sqrt(3)*VR_line) //I=P*10^3/(sqrt(3)*VR_line);//in Ampere TotalLoss=3*I^2*R;//in watt Pout=P_KVA*cos_fir;//in KW Pin=Pout+TotalLoss/1000;//in KW ETA=Pout/Pin;//unitless disp(ETA*100,"Transmission Efficiency(in %) :");
3aafdcffc7c114fd92137330efc251f38086e7ab
1bc06fa90b5425d41347c90d0c73bb82eb4cbbfe
/filtres/gaussien5x5.sci
0c6279a51ef705d6409a9d339a3b3c45b786423b
[]
no_license
madox35/Filtre-Canny
a0a527ad6be5a1dc5984b2533008f95b1c9663ee
3a54da9b0ce917c995ea5fbd48e0ed5c3f36748d
refs/heads/master
2020-03-08T08:57:27.702111
2018-04-21T19:39:39
2018-04-21T19:39:39
null
0
0
null
null
null
null
UTF-8
Scilab
false
false
245
sci
gaussien5x5.sci
function [filtre, coef, nom] = creerFiltreGaussien5x5() filtre = [1,4,6,4,1; 4,16,24,16,4; 6,24,36,24,6; 4,16,24,16,4; 1,4,6,4,1]; coef = 256; nom = 'Gaussien 5x5'; endfunction
9c5b6141c8f753d7fa3edcafb7b8246adaa11d55
5c808b0f55fefd29b91c7cb73f2f3a08093c5033
/Code/Scilab Code/stabilityCheck.sce
59ffe10eee8ad1df64657e646cae48cdff3238c6
[]
no_license
JOfTheAncientGermanSpear/Filter-Bank-Guitar-Note-Chord-Detection
a01e2ce521561dfea555a588d6bb1e0f1deca18e
cb0d54c74275a990dcb984c4ec349e6ca4e72a1a
refs/heads/master
2021-01-20T12:00:42.472605
2013-06-14T03:04:33
2013-06-14T03:04:33
null
0
0
null
null
null
null
UTF-8
Scilab
false
false
379
sce
stabilityCheck.sce
function [stable] = stabilitycheck(A); N = length(A)-1; // Order of A(z) stable = 1; // stable unless shown otherwise A = A(:); // make sure it's a column vector for i=N:-1:1 rci=A(i+1); if abs(rci) >= 1 disp('in'); stable=0; return; end A = (A(1:i) - rci * A(i+1:-1:2))/(1-rci^2); disp(sprintf('A[%d]=',i)); disp(A(1:i)') end
5609d64f594768e2f1f845c8be636e6d66e1dbfc
449d555969bfd7befe906877abab098c6e63a0e8
/1478/CH2/EX2.18.44/2_18_44.sce
3fe17cfca28307ccafeec50890c05756652a2069
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
1,252
sce
2_18_44.sce
//water and its treatment// //example 2.18.44// clc Purity_Lime=.85 Purity_soda=.95 W1=49.95;//amount of CaCl2 in ppm// W2=42;//amount of MgSO4 in ppm// W3=12.6;//amount of NaHCO3 in ppm// W4=10;//amount of SiO2 in ppm// W5=500;//amount of NaCl in ppm// W6=51.1;//amount of Mg(HCO3)2 in ppm// W7=3;//amount of CO2 in ppm// W8=3;//amount of Fe2+ in ppm// W9=15;//amount of AlCl3 in ppm// M1=100/111;//multiplication factor of CaCl2// M2=100/120;//multiplication factor of MgSO4// M6=100/146;//multiplication factor of Mg(HCO3)2// M7=100/44.3//multiplication factor of CO2// M8=100/55;//multiplication factor of Fe2+// M9=100/133.5//multiplication factor of AlCl3// P1=W1*M1;//in terms of CaCO3//S P2=W2*M2;//in terms of CaCO3//L+S P6=W6*M6;//in terms of CaCO3//L P7=W7*M7;//in terms of CaCO3//L P8=W8*M8;//in terms of CaCO3//L+S P9=W9*M9;//in terms of CaCO3//L+S printf ("We do not take NaHCO3, NaCl and Mg(HCO3)2 since they do not react with lime/soda"); V=1000000;//volume of water in litres// L=0.74*(P2+P6*2+P7+P8+P9)*V/Purity_Lime;//lime required in mg// L=L/10^6; printf("\nLime required is %.1fkg",L); S=1.06*(P1+P2+P8+P9)*V/Purity_soda;//soda required in mg// S=S/10^6; printf("\nSoda required is %.1fkg",S)
02dcfdc1c792a34996f6404c84208d77ebcc383e
a1799f36d8ed18033aa4409476b2ad8e3d550c77
/Proyecto 2 - Calor y Temperatura/ProyectoNumerico2 - e.sce
c4d345bdcfa86525973f5ca98725e7ea9f4a3e1c
[]
no_license
matiashrnndz/scilab-examples
65fa6636f5568455d261ce83ef4af17dae0e5dc7
50886b1d4720cf3a10e50b3cebe1c8ffbc906c8a
refs/heads/master
2023-02-10T01:39:08.369590
2021-01-01T23:53:56
2021-01-01T23:53:56
null
0
0
null
null
null
null
UTF-8
Scilab
false
false
1,928
sce
ProyectoNumerico2 - e.sce
clear // Def: Temperatura ambiente, Unidad: Grados Kelvin Tamb=283 // Def: Paso de integración Delta t para el método de Euler, Unidad: s dt=0.1 // Def: Tiempo inicial para el método de Euler, Unidad: s t0=0 // Def: Tiempo final para el método de Euler, Unidad: s tf=3600 // Def: Conductividad términa, Unidad: W/m*K k=0.6 // Def: Lado de la sala cúbica, Unidad: m l=4 // Def: Ancho de pared, Unidad: m d=0.25 // Def: Masa del aire, Unidad: Kg m=76.8 // Def: Calor específico del aire, Unidad: J/Kg*K Ca=1012 // Def: Voltage inicial, Unidad: V V0=100 // Def: Resistencia, Unidad: Ohm R=1 // Def: Unidad: rad/s w=0.02 // Def: Unidad: 1/s a=0.0035 // Def: Gamma de la fórmula de Calor gma=(k*5*(l^2))/(d*m*Ca) // Def: Temperatura en t inf (analítico), Unidad: Kelvin TinfA=326.4027 function [t,T] = ObtenerTemperaturaPorEuler(); // Condiciones iniciales t(1)=t0 T(1)=Tamb TinfEncontrado = %F TinfE=0 tinfE=0 U=0 i=1 while (t(i)<=tf) && ~TinfEncontrado u=(1/(m*Ca))*((((V0^2)*((1-(%e^((-a)*t(i)))*cos(w*t(i)))^2))/R)+(Tamb*((k*5*(l^2))/d))) T(i+1)=T(i)+(u-gma*T(i))*dt Tdif=(abs(TinfA-T(i)))/(abs(TinfA-T(1))) U=U+((((V0^2)*((1-(%e^((-a)*t(i)))*cos(w*t(i)))^2))/R)*dt) disp(U) if(Tdif <= (1/100)) then TinfEncontrado = %T; TinfE=T(i) tinfE=t(i) disp("Tiempo a esperar para que la temperatura llegue a estado de régimen estacionario (en forma numérica):") disp(tinfE) disp("Temperatura en régimen estacionario (en forma numérica):") disp(TinfE) disp("Gasto de energía eléctrica necesario para llegar al régimen de estado estacionario(en forma numérica):") disp(U) end t(i+1)=t(i)+dt i=i+1 end endfunction // Obtenemos los puntos por Metodo de Euler [t,T] = ObtenerTemperaturaPorEuler()
eabe4d2570d7f75c1bdc248edfa106bd006fa06f
449d555969bfd7befe906877abab098c6e63a0e8
/1511/CH2/EX2.16/ex2_16.sce
954ea412492d96f87250665cc079b41c9bfcb371
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
300
sce
ex2_16.sce
// Example 2.16 page no-71 clear clc A = 9.64 * 10^14 EG = 0.25 //eV n1 = 6.25*10^26///cm^3 na=3*10^14 nd=2*10^14 n=-(10^14)+(sqrt(10^28+4*6.25*10^26)) n=n/2 printf("\nn=%.1f*10^12 electrons/cm^3\np=%.2f*10^14 holes/cm^3\nAs p> n, this is p-type semiconductor.",n/10^12,(n+10^14)/10^14)
5d3a118a3d5e94707aada93a4bdee10a5cd80719
449d555969bfd7befe906877abab098c6e63a0e8
/3808/CH4/EX4.11/Ex4_11.sce
c50d792bea7e82daf75017fceb5381cfef5c9ed2
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
263
sce
Ex4_11.sce
//Chapter 04:Number Theory and Cryptography clc; clear all; n=input("Enter the number:") c=0 for i =2:n-1 if modulo(n,i)==0 then c=c+1 end end if c==0 then mprintf("%d is a prime number",n) else mprintf("%d is not a prime number",n) end
5a464eb0a0f328cfac4aeefcbd932e49dcf2bbc7
449d555969bfd7befe906877abab098c6e63a0e8
/1226/CH7/EX7.5/EX7_5.sce
7a92fa227f381a6583e5b0e7d54d1d67c7ce3341
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
934
sce
EX7_5.sce
clc;funcprot(0)//EXAMPLE 7.5 //Initializing the variables n=6;................//No of cylinders vsi=730*(10^(-6));..........//Piston displacement per cylinder in m^3 BP=80;.............//Power produced per cylinder in kW N=3100;...........//Engine rpm C=44*(10^6);...........//Calorific value of petrol in J/kg Pc=28;........//Petrol consumed per hour in kg afr = 13/1;.......//air fuel ratio pi=0.88*(10^5);..............//Intake pressure in pa T=300;............//Intake temperature in Kelvin R = 287;.........//gas constant in J/kg.K //calculations ma = (Pc*afr)/60;...........//air comsumed rhoa = pi/(R*T);.......//Density of air etaV=ma/(rhoa*vsi*n*(N/2)); disp(etaV*100,"The volumetric efficiency is (%):") mf = Pc/3600;...............//Fuel consumed per sec etaBT = (BP*1000)/(mf*C); disp (etaBT*100,"The brake thermal efficiency is (%):") T=(BP*60*1000)/(2*(%pi)*N); disp (T,"The brake torque (Nm):")
dcb4be909bc786b093cfd5178717a74bbc79710e
449d555969bfd7befe906877abab098c6e63a0e8
/1319/CH2/EX2.24/2_24.sce
aaeac56b0ec36dbb1ab84e1e2ad32ae7ffebd36c
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
625
sce
2_24.sce
// Determine the current through 10 ohm resistor using thevenins circuit clc; clear; //Source Voltages V1=10; V2=2; // Resistances of upper limb R1=15; R2=25; //Resistances of lower limb R3=30; R4=20; //For a thevenin circuit i1=(V1-V2)/(R1+R2); // Current in upper limb i2=V1/(R3+R4); // Current in lower limb Vac=(i1*R2)+2; Vbc=(i2*R4); Vab=Vac-Vbc; // Thevenin Voltage Vth=Vab; Zl=10; // Load resistance Reff1=(R1*R2/(R2+R1)); Reff2=(R3*R4/(R3+R4)); Zth=Reff1+Reff2; I=Vth/(Zl+Zth); // Curent through AB printf('The current through the 10 ohm resistor = %g mA\n',I*1000)
5d473abe6d20c5a7a7394b31aaaf5b6a33c2617f
449d555969bfd7befe906877abab098c6e63a0e8
/3733/CH35/EX35.3/Ex35_3.sce
ab2d88b13b08e737c0500499da77e75ff5686936
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
708
sce
Ex35_3.sce
// Example 35_3 clc;funcprot(0); //Given data // C_1=840000+840 kW+0.116 kWh // C_2=500000+440 kW+0.2985 kWh A_1=840; A_2=440; B_1=0.116; B_2=0.2985; MD=64000;// kW t=8760;// hours // Calculation L=(A_1-A_2)/(B_2-B_1);// Time in hours P_p=(MD/t)*L;// kW P_b=MD-P_p;// kW E_b=((1/2)*(L+t)*(P_b));// The kWh generated by base load plant E_p=((1/2)*L*P_p);// The kWh generated by peak load plant E_t=E_b+E_p;// // Total energy generated in kWh C_1=840000+(A_1*P_b)+(B_1*E_b);// rupees C_2=500000+(A_2*P_p)+(B_2*E_p);// rupees C=C_1+C_2;// Total cost in rupees Gc=C/E_t;// Generating cost in rupees printf('\nGenerating cost=Rs.%0.2f/kWh',Gc); // The answer vary due to round off error
0b2baf19910cbe3d291dceb5e35947e9c0a7ec79
449d555969bfd7befe906877abab098c6e63a0e8
/1445/CH8/EX8.34/ch8_ex_34.sce
4695c56c76c57d5bd71f16bd987fce37aa5d94ad
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
876
sce
ch8_ex_34.sce
//CHAPTER 8- DIRECT CURRENT MACHINES //Example 34 disp("CHAPTER 8"); disp("EXAMPLE 34"); //VARIABLE INITIALIZATION r_a=0.06; //armature resistance in Ohms r_se=0.04; //series resistance in Ohms r_sh=25; //shunt resistance in Ohms v_t=110; //in Volts I_l=100; //in Amperes //SOLUTION //solution (a) I_sh=v_t/r_sh; I_a=I_sh+I_l; E_g=v_t+I_a*(r_a+r_se); disp("(a) When the machine is connected as long shunt compound generator-"); disp(sprintf("The armature current is %f A and the total emf is %f V",I_a,E_g)); //solution (b) I_sh=(v_t/r_sh)+(I_l*r_se/r_sh); I_a=I_sh+I_l; E_g=v_t+(I_a*r_a)+(I_l*r_se); disp("(b) When the machine is connected as short shunt compound generator-"); disp(sprintf("The armature current is %f A and the total emf is %f V",I_a,E_g)); //END
675515ca9997542ce3811b1768401a3b999745f4
449d555969bfd7befe906877abab098c6e63a0e8
/761/CH24/EX24.7/24_7.sce
5063d820d83a154229cc6ed58c55a2952db598de
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
680
sce
24_7.sce
clc; // page no 899 // prob no 24.7 // refer table from the problem page no 899 P_coupling1 =-3; P_coupling2 = -6; P_coupling3 =-40;// in dB //Part a) The proportion of input power emerging at port 2 P2_Pin=10^(P_coupling1/10); disp('%',P2_Pin*100,'a) The proportion of input power emerging at port 2'); P3_Pin=10^(P_coupling2/10); disp('%',P3_Pin*100,' The proportion of input power emerging at port 3'); // Part b) In the reverse direction,the signal is 40dB down for all combinations, so directivity = 40; disp('dB',directivity,'Directivity is'); Pin_total = P2_Pin + P3_Pin; // excess loss in dB loss=-10*log10(Pin_total); disp('dB',loss,'the excess loss is');
b80b1c67ec11ab989cce54a76d3dec14d1c02176
8781912fe931b72e88f06cb03f2a6e1e617f37fe
/scilab/qscatter/qdipsigteasa3.sce
19f64dfd6a65874387a4a652f477c4ed5843e970
[]
no_license
mikeg2105/matlab-old
fe216267968984e9fb0a0bdc4b9ab5a7dd6e306e
eac168097f9060b4787ee17e3a97f2099f8182c1
refs/heads/master
2021-05-01T07:58:19.274277
2018-02-11T22:09:18
2018-02-11T22:09:18
121,167,118
1
0
null
null
null
null
UTF-8
Scilab
false
false
2,975
sce
qdipsigteasa3.sce
//qscatter exec('v.sce'); exec('f.sce'); exec('u.sce'); exec('tdl.sce'); exec('sigma.sce'); exec('numerov.sce'); jobname='wjob'; env=getenv('SGE_TASK_ID'); //env='1'; sgetid=sscanf(env,'%d'); nproc=8; outfile='job'+env+'.out'; matfile='results'+env+'.mat' //partial wave analysis of scattering //varying angle for a medium separation deltah=0.01; nsteps=200; global m global hb //m=938*10^9; m=1.672*10^(-27); //hb=6.59*10^(-13); hb=1.054*10^(-34); lupper=10 e=1.6*10^(-19); delta=0.1*(10^(-10)); delta=0.5; m=1; hb=1; e=1; //2m/hb^2=6.12meV^-1(sigma)^-2 lupper=10; sumdelta=0; nr=100; ne=250; sumouter=zeros(ne); totsum=0; //sigma=0; u1=zeros(nr,lupper+1); u2=zeros(nr,lupper+1); u3=zeros(nr,lupper+1); //outer loop integration over r epsilon=5.9;//meV H-Kr interaction sigma=3.57;//Angstrom nsites=2; dipangle=%pi*25/180; dipangle=2*%pi*sgetid/nproc; dipsep=0.5; sitesig=sigma*ones(nsites,1); siteepsi=epsilon*ones(nsites,1); for nec=1:ne e=nec*0.0005; k=sqrt(2*m*e)/hb; totsum=0; //sigma=0; u1=zeros(nr,lupper+1,2); u2=zeros(nr,lupper+1,2); u3=zeros(nr,lupper+1,2); for j=1:nr, u1=0; //inner loop summation over l rad=3.1+j*delta; sumdelta=0; for ik=1:2 for il=0:lupper, if j == 1 then u1(j,il+1,ik)=.1; u2(j,il+1,ik)=delta^(il+1); else u2(j,il+1,ik)=u3(j-1,il+1,ik); u1(j,il+1,ik)=u2(j-1,il+1,ik); end; if ik==1 then r=sqrt(rad^2+dipsep^2+2*rad*dipsep*cos(dipangle)); epsilon=siteepsi(ik,1);//meV H-Kr interaction sigma=sitesig(ik,1);//Angstrom else r=sqrt(rad^2+dipsep^2-2*rad*dipsep*cos(dipangle)); epsilon=siteepsi(ik,1);//meV H-Kr interaction sigma=sitesig(ik,1);//Angstrom end u3(j,il+1,ik)=numerov(u1(j,il+1,ik),u2(j,il+1,ik),il,r,delta,e,sigma,epsilon); //res=tdl(u1(j,i+1),u2(j,i+1),j*delta,(j+1)*delta,i,k); //cosecdelta2=((1/(res^2))+1); //sumdelta=sumdelta+(2*i+1)*(1/cosecdelta2); end //end summation over l, il end //end summation over spherical potentials //sumouter(j)=((4*%pi)/(k^2))*sumdelta; //totsum=totsum+sumouter(j); end //end summation over j ... radial distance for i=0:lupper repart=0; impart=0; for ik=1:nsites res=tdl(u2(nr-2,i+1,ik),u2(nr-1,i+1,ik),(nr-1)*delta,(nr)*delta,i,k); deltal=atan(res); repart=repart+(cos(deltal)*sin(deltal)); impart=impart+sin(deltal); end sumdelta=sumdelta+(2*i+1)*(repart^2+impart^2); end sumouter(nec)=((4*%pi)/((nsites*k)^2))*sumdelta; end //plot(sumouter); //Write data to output fd=mopen(outfile,'w'); for nec=1:ne mfprintf(fd, '%f %f\n',nec*0.0005, sumouter(nec)); end mfprintf(fd, '\n'); savematfile(matfile,'sumouter'); mclose(fd); exit;
5bb0de204c2fb725091ce69fa94dfa78df9aacbf
592b1b7dfaefd62d755737ac7b6e81f44f7786ba
/7b Program to solve differential equation using modified Euler’s method..sce
abef38a0d1eb0045a3d41604a310fdc1ff42b31e
[]
no_license
muitnet/Numerical-and-Statistical-Methods-sem2-fybscit-mumbai-university
841143b72d52229c68bcd0666ed10c844c02f507
2d1c638b881f3e418a982baa02632effd03ae5fe
refs/heads/master
2021-01-19T07:23:05.463429
2017-04-07T11:54:24
2017-04-07T11:54:24
87,540,712
6
5
null
null
null
null
UTF-8
Scilab
false
false
270
sce
7b Program to solve differential equation using modified Euler’s method..sce
function [y10]=eularmod(x0, y0, h, n, f) x1=x0+h; y10=y0+h*f(x0,y0) while(n>1) x0=x0+h; x1=y10; y10=y0+(h/2)*(f(x0,y0)+f(x1,y10)); if(abs(y10-x1)<0.001) y10 abort; end n=n-1; y10 end endfunction deff('[y]=f(a,b)','y=log(a+b)'); eularmod(1,2,0.2,10,f)
c5c94e570f5e617b8f2bad14d2e12c5db9798fc4
449d555969bfd7befe906877abab098c6e63a0e8
/3828/CH16/EX16.1/Ex16_1.sce
da6229b397329ba12f5d5098a6f54dc9a8b696ba
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
350
sce
Ex16_1.sce
//Chapter 16 : MAGNETIC MATERIALS clear; //Variable declaration H=10**6 //Magnetic Field Strength in ampere/m x=0.5*10**-5 //Magnetic susceptibility mu_0=4*%pi*10**-7 //Calculatiions M=x*H B=mu_0*(M+H) //Result mprintf("Intensity of Magnetization=%d ampere/m",M) mprintf("\nFlux density in the material=%f weber/m^2",B)
791000f27b80e1e601fe6ab61329288183ea7577
e8dbcf469ba8a31d6926ba791ebc5dcccd50282b
/css/Scripts/Funciones/get_fumador.tst
360729ccb1c11f95f6865940bbe9c255388e0bb9
[]
no_license
bryanjimenezchacon/bryanjimenezchacon.github.io
5f2a0f1dbfbc584a65dece48f98b1c13d755512f
7062d1860934808265c05491007c83f69da1112a
refs/heads/master
2021-01-23T17:20:11.542585
2015-10-10T05:52:52
2015-10-10T05:52:52
41,244,377
2
0
null
2015-08-26T15:46:04
2015-08-23T09:52:06
JavaScript
UTF-8
Scilab
false
false
167
tst
get_fumador.tst
PL/SQL Developer Test script 3.0 4 begin -- Call the function :result := get_bebedor(pbebedor_id => :pbebedor_id); end; 2 result 1 FRECUENTE 5 pbebedor_id 1 1 4 0
7b740cdb9e88a277386ab11ac583f428cf9810a2
01ecab2f6eeeff384acae2c4861aa9ad1b3f6861
/sci2blif/rasp_design_added_blocks/dac.sce
80f76b04b299ecc998ad8410ab5459c0332d7d00
[]
no_license
jhasler/rasp30
9a7c2431d56c879a18b50c2d43e487d413ceccb0
3612de44eaa10babd7298d2e0a7cddf4a4b761f6
refs/heads/master
2023-05-25T08:21:31.003675
2023-05-11T16:19:59
2023-05-11T16:19:59
62,917,238
3
3
null
null
null
null
UTF-8
Scilab
false
false
198
sce
dac.sce
style.fontSize=14; style.displayedLabel="<table> <tr><td align=center>DC<br>Voltage</td></tr></table>"; pal1_2 = xcosPalAddBlock(pal1_2,"dac",[],style); pal6 = xcosPalAddBlock(pal6,"dac",[],style);
1a38cccdfd5137aa42ddda2eee5a68b56ee3e67b
449d555969bfd7befe906877abab098c6e63a0e8
/3293/CH8/EX8.28/Ex8_28.sce
f9d076267600f862815c447c4e23c3adac62d788
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
562
sce
Ex8_28.sce
//page 307 //Example 8.28 clc; clear; close; disp('x1 and x2 are two real nos. i.e., x1^2 + x2^2 = 1'); x1 = rand(); x2 = sqrt(1 - x1^2); disp(x1,'x1 = '); disp(x2,'x2 = '); B = [x1 x2 0;0 1 0;0 0 1]; disp(B,'B = '); disp('Applying Gram-Schmidt process to B:') a1 = [x1 x2 0]; a2 = [0 1 0] - x2 * [x1 x2 0]; a3 = [0 0 1]; disp(a1,'a1 = '); disp(a2,'a2 = '); disp(a3,'a3 = '); U = [a1;a2/x1;a3]; disp(U,'U = '); M = [1 0 0;-x2/x1 1/x1 0;0 0 1]; disp(M,'M = ') disp(inv(M) * U,'inverse(M) * U = '); disp('So, B = inverse(M) * U'); //end
5316e4abde7545088181ac0e7326ee89dcc551da
c247bce84b3facd1a13b48e7417327c40c8b3898
/FOPID/impulse.sci
96f341aa855df5203402239cd08a1206c92aebdb
[]
no_license
AstroSayan/FuzzyFOPID
9de9fa761301da6ae1f5dfe7b8e7e8214f3b472b
ea0e31e8fa0b36e407de9dfa466cf46b583e4103
refs/heads/main
2023-04-26T19:18:30.590337
2021-05-13T18:27:32
2021-05-13T18:27:32
367,137,779
2
0
null
null
null
null
UTF-8
Scilab
false
false
161
sci
impulse.sci
function impulse(G,t) Gres=csim('impulse',t,G); plot(t,Gres); f=gcf(); xlabel("Time (sec)"); ylabel("Amplitude"); title("Impulse Response"); endfunction
33e579abb70eb9e906c13ec20ea0431c625230df
f542bc49c4d04b47d19c88e7c89d5db60922e34e
/PresentationFiles_Subjects/CONT/JH56CNU/ATWM1_Working_Memory_MRI_Salient_Uncued_Run1.sce
573a3e8ef0b5bc24cab846f39c9ea6aae80a52c7
[]
no_license
atwm1/Presentation
65c674180f731f050aad33beefffb9ba0caa6688
9732a004ca091b184b670c56c55f538ff6600c08
refs/heads/master
2020-04-15T14:04:41.900640
2020-02-14T16:10:11
2020-02-14T16:10:11
56,771,016
0
1
null
null
null
null
UTF-8
Scilab
false
false
12,235
sce
ATWM1_Working_Memory_MRI_Salient_Uncued_Run1.sce
# ATWM1 MRI Experiment scenario = "ATWM1_Working_Memory_MRI_salient_uncued_run1"; scenario_type = fMRI; # Fuer Scanner #scenario_type = fMRI_emulation; # Zum Testen #scenario_type = trials; scan_period = 2000; # TR pulses_per_scan = 1; pulse_code = 1; #pulse_width=6; default_monitor_sounds = false; active_buttons = 2; response_matching = simple_matching; button_codes = 10, 20; default_font_size = 28; default_font = "Arial"; default_background_color = 0 ,0 ,0 ; #write_codes=true; # for MEG only begin; #Picture definitions box { height = 300; width = 300; color = 0, 0, 0;} frame1; box { height = 290; width = 290; color = 255, 255, 255;} frame2; box { height = 30; width = 4; color = 0, 0, 0;} fix1; box { height = 4; width = 30; color = 0, 0, 0;} fix2; box { height = 30; width = 4; color = 255, 0, 0;} fix3; box { height = 4; width = 30; color = 255, 0, 0;} fix4; box { height = 290; width = 290; color = 128, 128, 128;} background; TEMPLATE "StimuliDeclaration.tem" {}; trial { sound sound_incorrect; time = 0; duration = 1; } wrong; trial { sound sound_correct; time = 0; duration = 1; } right; trial { sound sound_no_response; time = 0; duration = 1; } miss; # baselinePre (at the beginning of the session) trial { picture { box frame1; x=0; y=0; box frame2; x=0; y=0; box background; x=0; y=0; bitmap fixation_cross_black; x=0; y=0; }default; time = 0; duration = 9400; mri_pulse = 1; code = "BaselinePre"; #port_code = 1; }; TEMPLATE "ATWM1_Working_Memory_MRI.tem" { trigger_volume_encoding trigger_volume_retrieval cue_time preparation_time encoding_time single_stimulus_presentation_time delay_time retrieval_time intertrial_interval alerting_cross stim_enc1 stim_enc2 stim_enc3 stim_enc4 stim_enc_alt1 stim_enc_alt2 stim_enc_alt3 stim_enc_alt4 trial_code stim_retr1 stim_retr2 stim_retr3 stim_retr4 stim_cue1 stim_cue2 stim_cue3 stim_cue4 fixationcross_cued retr_code the_target_button posX1 posY1 posX2 posY2 posX3 posY3 posX4 posY4; 6 12 292 292 399 125 11543 2992 12342 fixation_cross gabor_134 gabor_005 gabor_056 gabor_029 gabor_134_alt gabor_005_alt gabor_056 gabor_029 "1_1_Encoding_Working_Memory_MRI_P6_LR_Salient_DoChange_CuedRetrieval_300_300_399_11601_3000_12400_gabor_patch_orientation_134_005_056_029_target_position_1_2_retrieval_position_1" gabor_087_framed gabor_circ gabor_circ gabor_circ blank blank blank blank fixation_cross_white "1_1_Retrieval_Working_Memory_MRI_P6_LR_Salient_DoChange_CuedRetrieval_retrieval_patch_orientation_087_retrieval_position_1" 2 45.96 45.96 -45.96 45.96 -45.96 -45.96 45.96 -45.96; 20 26 292 292 399 125 11543 2992 12342 fixation_cross gabor_141 gabor_108 gabor_167 gabor_055 gabor_141_alt gabor_108 gabor_167 gabor_055_alt "1_2_Encoding_Working_Memory_MRI_P6_LR_Salient_NoChange_CuedRetrieval_300_300_399_11601_3000_12400_gabor_patch_orientation_141_108_167_055_target_position_1_4_retrieval_position_1" gabor_141_framed gabor_circ gabor_circ gabor_circ blank blank blank blank fixation_cross_white "1_2_Retrieval_Working_Memory_MRI_P6_LR_Salient_NoChange_CuedRetrieval_retrieval_patch_orientation_141_retrieval_position_1" 1 45.96 45.96 -45.96 45.96 -45.96 -45.96 45.96 -45.96; 34 40 292 292 399 125 11543 2992 12342 fixation_cross gabor_145 gabor_021 gabor_055 gabor_175 gabor_145 gabor_021 gabor_055_alt gabor_175_alt "1_3_Encoding_Working_Memory_MRI_P6_LR_Salient_NoChange_CuedRetrieval_300_300_399_11601_3000_12400_gabor_patch_orientation_145_021_055_175_target_position_3_4_retrieval_position_3" gabor_circ gabor_circ gabor_055_framed gabor_circ blank blank blank blank fixation_cross_white "1_3_Retrieval_Working_Memory_MRI_P6_LR_Salient_NoChange_CuedRetrieval_retrieval_patch_orientation_055_retrieval_position_3" 1 45.96 45.96 -45.96 45.96 -45.96 -45.96 45.96 -45.96; 48 53 292 292 399 125 9543 2992 12342 fixation_cross gabor_147 gabor_034 gabor_093 gabor_122 gabor_147 gabor_034_alt gabor_093_alt gabor_122 "1_4_Encoding_Working_Memory_MRI_P6_LR_Salient_NoChange_CuedRetrieval_300_300_399_9601_3000_12400_gabor_patch_orientation_147_034_093_122_target_position_2_3_retrieval_position_2" gabor_circ gabor_034_framed gabor_circ gabor_circ blank blank blank blank fixation_cross_white "1_4_Retrieval_Working_Memory_MRI_P6_LR_Salient_NoChange_CuedRetrieval_retrieval_patch_orientation_034_retrieval_position_2" 1 45.96 45.96 -45.96 45.96 -45.96 -45.96 45.96 -45.96; 61 66 292 292 399 125 9543 2992 14342 fixation_cross gabor_032 gabor_178 gabor_049 gabor_003 gabor_032_alt gabor_178 gabor_049 gabor_003_alt "1_5_Encoding_Working_Memory_MRI_P6_LR_Salient_DoChange_CuedRetrieval_300_300_399_9601_3000_14400_gabor_patch_orientation_032_178_049_003_target_position_1_4_retrieval_position_4" gabor_circ gabor_circ gabor_circ gabor_139_framed blank blank blank blank fixation_cross_white "1_5_Retrieval_Working_Memory_MRI_P6_LR_Salient_DoChange_CuedRetrieval_retrieval_patch_orientation_139_retrieval_position_4" 2 45.96 45.96 -45.96 45.96 -45.96 -45.96 45.96 -45.96; 75 80 292 292 399 125 9543 2992 12342 fixation_cross gabor_142 gabor_018 gabor_105 gabor_171 gabor_142 gabor_018 gabor_105_alt gabor_171_alt "1_6_Encoding_Working_Memory_MRI_P6_LR_Salient_DoChange_CuedRetrieval_300_300_399_9601_3000_12400_gabor_patch_orientation_142_018_105_171_target_position_3_4_retrieval_position_3" gabor_circ gabor_circ gabor_060_framed gabor_circ blank blank blank blank fixation_cross_white "1_6_Retrieval_Working_Memory_MRI_P6_LR_Salient_DoChange_CuedRetrieval_retrieval_patch_orientation_060_retrieval_position_3" 2 45.96 45.96 -45.96 45.96 -45.96 -45.96 45.96 -45.96; 88 94 292 292 399 125 11543 2992 14342 fixation_cross gabor_003 gabor_080 gabor_169 gabor_113 gabor_003_alt gabor_080 gabor_169_alt gabor_113 "1_7_Encoding_Working_Memory_MRI_P6_LR_Salient_NoChange_UncuedRetriev_300_300_399_11601_3000_14400_gabor_patch_orientation_003_080_169_113_target_position_1_3_retrieval_position_4" gabor_circ gabor_circ gabor_circ gabor_113_framed blank blank blank blank fixation_cross_white "1_7_Retrieval_Working_Memory_MRI_P6_LR_Salient_NoChange_UncuedRetriev_retrieval_patch_orientation_113_retrieval_position_4" 1 45.96 45.96 -45.96 45.96 -45.96 -45.96 45.96 -45.96; 103 108 292 292 399 125 9543 2992 14342 fixation_cross gabor_130 gabor_070 gabor_021 gabor_099 gabor_130_alt gabor_070 gabor_021 gabor_099_alt "1_8_Encoding_Working_Memory_MRI_P6_LR_Salient_NoChange_CuedRetrieval_300_300_399_9601_3000_14400_gabor_patch_orientation_130_070_021_099_target_position_1_4_retrieval_position_1" gabor_130_framed gabor_circ gabor_circ gabor_circ blank blank blank blank fixation_cross_white "1_8_Retrieval_Working_Memory_MRI_P6_LR_Salient_NoChange_CuedRetrieval_retrieval_patch_orientation_130_retrieval_position_1" 1 45.96 45.96 -45.96 45.96 -45.96 -45.96 45.96 -45.96; 117 122 292 292 399 125 9543 2992 14342 fixation_cross gabor_040 gabor_128 gabor_166 gabor_108 gabor_040 gabor_128 gabor_166_alt gabor_108_alt "1_9_Encoding_Working_Memory_MRI_P6_LR_Salient_NoChange_CuedRetrieval_300_300_399_9601_3000_14400_gabor_patch_orientation_040_128_166_108_target_position_3_4_retrieval_position_4" gabor_circ gabor_circ gabor_circ gabor_108_framed blank blank blank blank fixation_cross_white "1_9_Retrieval_Working_Memory_MRI_P6_LR_Salient_NoChange_CuedRetrieval_retrieval_patch_orientation_108_retrieval_position_4" 1 45.96 45.96 -45.96 45.96 -45.96 -45.96 45.96 -45.96; 131 137 292 292 399 125 11543 2992 12342 fixation_cross gabor_159 gabor_032 gabor_016 gabor_105 gabor_159_alt gabor_032 gabor_016 gabor_105_alt "1_10_Encoding_Working_Memory_MRI_P6_LR_Salient_DoChange_UncuedRetriev_300_300_399_11601_3000_12400_gabor_patch_orientation_159_032_016_105_target_position_1_4_retrieval_position_2" gabor_circ gabor_081_framed gabor_circ gabor_circ blank blank blank blank fixation_cross_white "1_10_Retrieval_Working_Memory_MRI_P6_LR_Salient_DoChange_UncuedRetriev_retrieval_patch_orientation_081_retrieval_position_2" 2 45.96 45.96 -45.96 45.96 -45.96 -45.96 45.96 -45.96; 145 150 292 292 399 125 9543 2992 14342 fixation_cross gabor_019 gabor_073 gabor_105 gabor_142 gabor_019_alt gabor_073 gabor_105_alt gabor_142 "1_11_Encoding_Working_Memory_MRI_P6_LR_Salient_DoChange_CuedRetrieval_300_300_399_9601_3000_14400_gabor_patch_orientation_019_073_105_142_target_position_1_3_retrieval_position_1" gabor_158_framed gabor_circ gabor_circ gabor_circ blank blank blank blank fixation_cross_white "1_11_Retrieval_Working_Memory_MRI_P6_LR_Salient_DoChange_CuedRetrieval_retrieval_patch_orientation_158_retrieval_position_1" 2 45.96 45.96 -45.96 45.96 -45.96 -45.96 45.96 -45.96; 159 164 292 292 399 125 9543 2992 14342 fixation_cross gabor_009 gabor_139 gabor_079 gabor_050 gabor_009_alt gabor_139 gabor_079 gabor_050_alt "1_12_Encoding_Working_Memory_MRI_P6_LR_Salient_NoChange_CuedRetrieval_300_300_399_9601_3000_14400_gabor_patch_orientation_009_139_079_050_target_position_1_4_retrieval_position_4" gabor_circ gabor_circ gabor_circ gabor_050_framed blank blank blank blank fixation_cross_white "1_12_Retrieval_Working_Memory_MRI_P6_LR_Salient_NoChange_CuedRetrieval_retrieval_patch_orientation_050_retrieval_position_4" 1 45.96 45.96 -45.96 45.96 -45.96 -45.96 45.96 -45.96; 173 179 292 292 399 125 11543 2992 12342 fixation_cross gabor_003 gabor_062 gabor_125 gabor_167 gabor_003 gabor_062 gabor_125_alt gabor_167_alt "1_13_Encoding_Working_Memory_MRI_P6_LR_Salient_NoChange_UncuedRetriev_300_300_399_11601_3000_12400_gabor_patch_orientation_003_062_125_167_target_position_3_4_retrieval_position_1" gabor_003_framed gabor_circ gabor_circ gabor_circ blank blank blank blank fixation_cross_white "1_13_Retrieval_Working_Memory_MRI_P6_LR_Salient_NoChange_UncuedRetriev_retrieval_patch_orientation_003_retrieval_position_1" 1 45.96 45.96 -45.96 45.96 -45.96 -45.96 45.96 -45.96; 187 193 292 292 399 125 11543 2992 14342 fixation_cross gabor_015 gabor_164 gabor_090 gabor_125 gabor_015 gabor_164_alt gabor_090_alt gabor_125 "1_14_Encoding_Working_Memory_MRI_P6_LR_Salient_DoChange_CuedRetrieval_300_300_399_11601_3000_14400_gabor_patch_orientation_015_164_090_125_target_position_2_3_retrieval_position_3" gabor_circ gabor_circ gabor_043_framed gabor_circ blank blank blank blank fixation_cross_white "1_14_Retrieval_Working_Memory_MRI_P6_LR_Salient_DoChange_CuedRetrieval_retrieval_patch_orientation_043_retrieval_position_3" 2 45.96 45.96 -45.96 45.96 -45.96 -45.96 45.96 -45.96; 202 207 292 292 399 125 9543 2992 14342 fixation_cross gabor_074 gabor_027 gabor_090 gabor_054 gabor_074_alt gabor_027 gabor_090 gabor_054_alt "1_15_Encoding_Working_Memory_MRI_P6_LR_Salient_DoChange_CuedRetrieval_300_300_399_9601_3000_14400_gabor_patch_orientation_074_027_090_054_target_position_1_4_retrieval_position_4" gabor_circ gabor_circ gabor_circ gabor_006_framed blank blank blank blank fixation_cross_white "1_15_Retrieval_Working_Memory_MRI_P6_LR_Salient_DoChange_CuedRetrieval_retrieval_patch_orientation_006_retrieval_position_4" 2 45.96 45.96 -45.96 45.96 -45.96 -45.96 45.96 -45.96; }; # baselinePost (at the end of the session) trial { picture { box frame1; x=0; y=0; box frame2; x=0; y=0; box background; x=0; y=0; bitmap fixation_cross_black; x=0; y=0; }; time = 0; duration = 20600; code = "BaselinePost"; #port_code = 2; };
268f4fac0b5aed9ebfebafa79855a370ef26d7d9
6e257f133dd8984b578f3c9fd3f269eabc0750be
/ScilabFromTheoryToPractice/CreatingPlots/testgetgraphicentity2.sce
6a10ba25135dc99af4f41c9ba8d173cfbc09e9ac
[]
no_license
markusmorawitz77/Scilab
902ef1b9f356dd38ea2dbadc892fe50d32b44bd0
7c98963a7d80915f66a3231a2235010e879049aa
refs/heads/master
2021-01-19T23:53:52.068010
2017-04-22T12:39:21
2017-04-22T12:39:21
89,051,705
0
0
null
null
null
null
UTF-8
Scilab
false
false
118
sce
testgetgraphicentity2.sce
lines(10)//to delete clf //to delete plot2d() F=gcf() // figure A=gca() // axes E=gce() // handle of type Fac3D
1710e5c1018d6f8eaa7302d591f4be5e0ce9a6f5
449d555969bfd7befe906877abab098c6e63a0e8
/2024/CH8/EX8.3/8_3.sce
a2ee79fa713d8f167bc374562eb41106c03f0247
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
389
sce
8_3.sce
clc //Initialization of variables t1=500 //R t2=1000 //R //calculations function y = cp1(t) y= 7.484 - 3.47*10^3 /t + 1.16*10^6 /t^2 endfunction function y = cp2(t) y = 7.484/t - 3.47*10^3 /t^2 + 1.16*10^6 /t^3 endfunction Q=intg(t1,t2,cp1) ds=intg(t1,t2,cp2) //results printf("heat transferred = %d Btu/mole",Q) printf("\n change in entropy = %.3f Btu/mole R",ds)
12ec440f132e396b28e0205aee6b6b8de9aefe2d
449d555969bfd7befe906877abab098c6e63a0e8
/1862/CH15/EX15.2/C15P2.sce
0ce3d7d865cb4c33cb81daa9904a6d5a7ee6738b
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
1,231
sce
C15P2.sce
clear clc //to find applied force //to find distance by which car is raised // GIVEN: //refer to figure 15-9 from page no. 338 //diameter of smaller piston Di = 2.2//in cm //combined mass M = 1980//in Kg //diameter of larger piston D0 = 16.4//in cm //length of pump handle L = 36//in cm //distance of pivot to the piston x = 9.4//in cm //acceleration due to gravity g = 9.8//in m/s^2 //vertical distance by which hand moves h = 28//in cm // SOLUTION: //area of larger piston A0 = %pi*(D0/2)^2//in cm^2 //area of smaller piston Ai = %pi*(Di/2)^2//in cm^2 //applied force to the smaller piston Fi = M*g*(Ai/A0)//in N //using Newton's third law of motion //applied force at the end of pump handle Fh = Fi*(x/L)//in N //distance moved by smaller piston di = h*(x/L)//in cm //equating pressure on each side //distance moved by larger piston and car is raised by d0 = di*(Ai/A0)//in cm printf ("\n\n Applied force to the smaller piston Fi = \n\n %3i N",Fi) printf ("\n\n Applied force at the end of pump handle Fh = \n\n %2i N",Fh) printf ("\n\n Distance moved by smaller piston di = \n\n %.1f cm",di) printf ("\n\n Distance moved by larger piston and car is raised by d0 = \n\n %.2f cm",d0)
c5e64e13b4ff4f63674fcabcb373c7bd8841c33e
449d555969bfd7befe906877abab098c6e63a0e8
/2615/CH13/EX61.6/61.sce
0d279ecc714b79fe4b9b93fbdc108d92a83e8f3d
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
223
sce
61.sce
clc //initialisation of variables d=80//mm p=400//kg n=477//kg h=1000//mm t=60//sec //CALCULATIONS V=(%pi*d*n)/(h*t)//m/sec N=p*V/75//hp //RESULTS printf('the peripheral velocity of the workpicece=% f m/sec',N)
3bef103bb019a0f75e195c92005e5afce183eaf1
a62e0da056102916ac0fe63d8475e3c4114f86b1
/set5/s_Digital_Principals_And_Applications_D._P._Leach_And_A._P._Malvino_45.zip/Digital_Principals_And_Applications_D._P._Leach_And_A._P._Malvino_45/CH10/EX10.10/example_10_10.sce
41e7d39af13d60a3299d95d3e9116faf47ca89c0
[]
no_license
hohiroki/Scilab_TBC
cb11e171e47a6cf15dad6594726c14443b23d512
98e421ab71b2e8be0c70d67cca3ecb53eeef1df6
refs/heads/master
2021-01-18T02:07:29.200029
2016-04-29T07:01:39
2016-04-29T07:01:39
null
0
0
null
null
null
null
UTF-8
Scilab
false
false
119
sce
example_10_10.sce
errcatch(-1,"stop");mode(2);//example 10.10 ; ; printf('The correct expresion is ""8"" = Qd Qc'' Qb Qa'''); exit();
fd60f32e483b858379a350789717efff86059109
449d555969bfd7befe906877abab098c6e63a0e8
/2438/CH5/EX5.19/Ex5_19.sce
99e69cd4d9b4f9f0b1f5256ff34e21ed104c733c
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
759
sce
Ex5_19.sce
//================================================================================= // chapter 5 example 19 clc; clear; //input data m = 9.1*10^-31; //mass of electron in kg h = 6.62*10^-34; //planck's constant in (m^2)*kg/s //formula //x=N/V x = 2.5*10^28; //calculation EF = ((h^2)/(8*(%pi^2)*m))*((3*(%pi^2)*x)^(2/3)); //fermi energy in J EF1 = EF/(1.6*10^-19); //fermi energy in eV vF = (h/(2*m*%pi))*((3*(%pi^2)*x)^(1/3)); //fermi velocity in m/s //result mprintf('energy=%3.2e.eV\n',EF1); mprintf(' speed= =%3.2e.m/s\n',vF); //================================================================================
a0a7f3707be6997e06387f8a99cd38c70352d304
449d555969bfd7befe906877abab098c6e63a0e8
/2318/CH3/EX3.18/ex_3_18.sce
54253c0e62b9fcd3ccc7c6416772fd087e981d8d
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
242
sce
ex_3_18.sce
//Example 3.18:Resistance clc; clear; close; //given data : R2=100;// in ohm R3=32.7;// in ohm R4=100;// in ohm R=1.36;// in ohm L=47.8;// in mH R1=(R2*R3/R4)-R; disp(R1,"Resistance,R1(ohm) = ") L1=(R2/R4)*L; disp(L1,"inductance,L1(mH) = ")
b37e40aacd9c3d710caa6ea853eeecdd67b24589
449d555969bfd7befe906877abab098c6e63a0e8
/3769/CH20/EX20.12/Ex20_12.sce
de9fa08aafd1bc88e5f3d6d6d1ad0fc845437a73
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
181
sce
Ex20_12.sce
clear //Given R=6.4*10**6 //m h=110 //Calculation // d=(sqrt(2*R*h))*10**-3 P=%pi*d**2 //Result printf("\n Population covered is %0.1f *10**6",P*10**-3)
43da8206c2e8e3bfb6f7cd43e202b76947514423
449d555969bfd7befe906877abab098c6e63a0e8
/2609/CH6/EX6.11/Ex6_11.sce
e6fb3cffbc0d5bd2c9429d11b1ad9af73315a71b
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
355
sce
Ex6_11.sce
//Ex 6.11 clc; clear; close; format('v',6); T=10;//ms//(Time period) f0=1/(T*10^-3);//Hz C=0.05;//micro F//Chosen for the design //Formula : f0=1/{2*Rf*C*log(1+2*R2/R1)} Rf=1/(f0*2*C*10^-6*log(1+2))/1000;//kohm//By putting R1=R2 for this case Rf=round(Rf);//kohm disp(Rf,"Resistance Rf(kohm)"); disp(C,"Capacitance for the design(micro F)");
7b78f1e632d2b056d36e921cbd974d25aeb7b451
e82d1909ffc4f200b5f6d16cffb9868f3b695f2a
/Lista 6/QuestaoAlc.sce
5e69333e6fe7d51c2198d30fa37e26e4593a9197
[]
no_license
AugustoCam95/Computational-Linear-Algebra
eb14307dd3b45ccc79617efe74d1faca639c36c5
99b1a1f9499fbc4343bd5c878444e9e281952774
refs/heads/master
2020-03-30T22:26:23.790763
2018-10-05T03:34:06
2018-10-05T03:34:06
151,666,289
0
0
null
null
null
null
UTF-8
Scilab
false
false
1,802
sce
QuestaoAlc.sce
function [autovetores, autovalores, inversa]=QuestaoAlc(A) [l,c] = size(A)//Extrai as dimenssões da matriz A I = eye(l,c) Bi = eye(l,c) C=zeros(l,c)//Matriz C para armazenar as matrizes Bk autovetores=zeros(l,c) coef_p=0 //armazena os coeficientes de p coef_p(1,c+1) = 1 col=1 for i=1:c Ai = A*Bi qi = (trace(Ai) / i) coef_p(1,c+1-i) = (-1*qi) //armazena coeficientes do polinômio //caracteristico reversamente Bi = Ai - (qi*I) [lB,cB] = size(Bi) C(1:lB,col:col+cB-1) = Bi //armazena as matrizes Bk col = col+cB end //Monta polinomio caracteristico p = poly(coef_p,"x","coeff") p = ((-1)^c) * p //Extrai os autovalodes das raizes do polinomio caracteristico autovalores = roots(p) //calcula inversa if coef_p(1,1) / -1 == 0 then inversa = 0 //caso em que não é possivel calcular inversa else inversa = C(1:l,c*(c-2)+1 : c*(c-1)) / (coef_p(1,1) / -1) end //Dado que obtivemos os autovalores, podemos começar a calcular os autovetores associados [Nautovalores,lixo] = size(autovalores) for i=1 :Nautovalores u0 = eye(l,1) u_j=0 incrementador=1 //selecionar primeira coluna da matriz B correspondente for j=1:l-1 u_j = (autovalores(i,1)*u0) + C(1:l, incrementador:incrementador) u0 = u_j incrementador = incrementador+c //pula para primeira coluna da proxima matriz B end //armazena na coluna i o autovetor associado ao i-ésimo autovalor autovetores(1:l,i:i) = u_j end endfunction
79bb7ad5a4ebcfae77a50bf6b61dee782902a993
c3f643385a9e4946fb4cf17283614f355316307b
/String-search/tests/simple_substr_004.tst
ab152df94231294268bcba35aa591a0244e024d8
[]
no_license
rsBio/PGM
cc099009454dc91a9775690dda2f5c93a254ad5d
6f98ce54bdcc536102fc98caef51af08663c70ca
refs/heads/master
2023-07-09T04:05:18.865805
2023-06-27T16:26:20
2023-06-27T16:26:20
44,537,326
0
0
null
null
null
null
UTF-8
Scilab
false
false
17
tst
simple_substr_004.tst
../inputs/Ax5.str
13b3dc1a3d317b9621d1b20a9fe07f97a9312b2a
449d555969bfd7befe906877abab098c6e63a0e8
/1205/CH3/EX3.8/S_3_8.sce
2dfa70479509a2cc228339a46727965d258c1374
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
846
sce
S_3_8.sce
clc; // Given forces with direction shown by sign -ve to downwards, +ve for upwards. j shows that firceis along y direction f1=150;//N, j f2=-600;//N, j f3=100;//N , j f4=-250;//N,j //a) force couple system at A R=f1+f2+f3+f4;//N, j Resultant force, sum of all forces //M_RA=sum(r*f) M_RA=1.6*f2+2.8*f3+4.8*f4;//m, k sum of moments by each force printf("Equivalent force couple system at A is thus R= %.2f N and M_RA= %.2f N.m \n",R,M_RA); //B) Force couple system at B BA=-4.8;//m, i M_RB=M_RA+BA*R;//N.m printf("Equivalent force couple system at B is thus R= %.2f N and M_RB= %.2f N.m \n",R,M_RB); //c)single force or resultant // r*R=M_RA //x.i * (-600N)j=-(1800N.m)k x=M_RA/R;//m, distance of point of application from A printf("Equivalent single force is defined as at R= %.2f N and acts at x= %.2f m \n",R,x);
ce17bada6fa4c08e93f189468ee3c47d85ca463f
449d555969bfd7befe906877abab098c6e63a0e8
/548/DEPENDENCIES/4_14data.sci
9beb41a96b1aafa9432de157ab858dd822ebf7a8
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
318
sci
4_14data.sci
//Consider a low subsonic wind tunnel. A1=2; //reservoir area,m^2 A2=0.5; //test section area,m^2 P2=1.01*10^5;//test section pressure,N/m^2 V2=40;//flow velocity in test section //from continuity equation V1=V2*(A2/A1)//velocity before test section D=1.23; //density of flow equals standard sea level,Kg/m^3
7f4b96234a266c6122f0f0e480cc108272f4607f
87749481136b7b72a47930f587f27667e0c0f97d
/FIR filter design/ideal_highpass.sci
7882a41d11c05dfcb46da4354d103ea3d8f0896c
[ "MIT" ]
permissive
brooky56/Digital_Signal_Processing
cf15e5ac443a16edcb3efc8d7703cf4746dedcba
f28651e40b0a99b79e9ba27deabc4db8bfc7f08e
refs/heads/master
2022-06-30T17:59:28.072522
2020-05-11T18:58:39
2020-05-11T18:58:39
242,598,653
0
1
null
null
null
null
UTF-8
Scilab
false
false
213
sci
ideal_highpass.sci
function H = ideal_highpass(N, cutoff, stop_value) N = (N - modulo(N,2)) / 2 cutoff = floor(2 * N * cutoff) H = ones(1, N) * stop_value H(1,cutoff:N) = 1. H = [0. H flipdim(H, 2)] endfunction
e095cb9571ff693196cf1fa31219986090b93b44
676ffceabdfe022b6381807def2ea401302430ac
/library/Demos/StdRegions/Tests/StdProject3D_Hex_Lagrange_P6_Q7.tst
071e4bcb91a31be789d85eebc9176c53f72507cf
[ "MIT" ]
permissive
mathLab/ITHACA-SEM
3adf7a49567040398d758f4ee258276fee80065e
065a269e3f18f2fc9d9f4abd9d47abba14d0933b
refs/heads/master
2022-07-06T23:42:51.869689
2022-06-21T13:27:18
2022-06-21T13:27:18
136,485,665
10
5
MIT
2019-05-15T08:31:40
2018-06-07T14:01:54
Makefile
UTF-8
Scilab
false
false
526
tst
StdProject3D_Hex_Lagrange_P6_Q7.tst
<?xml version="1.0" encoding="utf-8"?> <test> <description>StdProject3D Hexahedron Lagrange basis P=6 Q=7</description> <executable>StdProject</executable> <parameters>-s hexahedron -b GLL_Lagrange GLL_Lagrange GLL_Lagrange -o 6 6 6 -p 7 7 7</parameters> <metrics> <metric type="L2" id="1"> <value tolerance="1e-12">3.06382e-14</value> </metric> <metric type="Linf" id="2"> <value tolerance="1e-12">3.41061e-13</value> </metric> </metrics> </test>
aa9af1a37d5d04cc14b8b7a57917ae2a6b086c72
8217f7986187902617ad1bf89cb789618a90dd0a
/browsable_source/2.2/Unix/scilab-2.2/macros/percent/%lnm.sci
6b5b88b2edc9f9ca72bc931e715c9fc301edc6ba
[ "LicenseRef-scancode-warranty-disclaimer", "LicenseRef-scancode-public-domain", "MIT" ]
permissive
clg55/Scilab-Workbench
4ebc01d2daea5026ad07fbfc53e16d4b29179502
9f8fd29c7f2a98100fa9aed8b58f6768d24a1875
refs/heads/master
2023-05-31T04:06:22.931111
2022-09-13T14:41:51
2022-09-13T14:41:51
258,270,193
0
1
null
null
null
null
UTF-8
Scilab
false
false
125
sci
%lnm.sci
//[r]=%lnm(l1,l2) //%lnm(l1,l2) correspond a l'operation logique l1==l2 avec l1 une liste //et l2 une macro //! r=%t //end
18b3b302b3d3dd3082817f597b10c2bb5c2ac0b8
449d555969bfd7befe906877abab098c6e63a0e8
/2276/CH4/EX4.1/chapter4_ex1.sce
68631773b6c10601cf903b1976f292b94e4afdef
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
510
sce
chapter4_ex1.sce
clc clear //input r=10;//resistance of a coil in ohms l=0.08;//inductance of the coil in henry v=250;//a.c. supply voltage in volts f=50;//supply frequency in hertz //calculations Xl=2*%pi*f*l;//reactance of the coil in ohms z=((r^2)+(Xl^2))^0.5;//impedance of the circuit I=v/z;//current in amperes phi=acos(r/z);// phase angle in radians PHI=(phi*180)/%pi;//phase angle in degrees //output mprintf('the coil will take a current of %3.2f A lagging by %3.0f degree on the voltage',I,PHI)
c9a01e7dc76ad664cc6fe5a37a5904ff188e894a
449d555969bfd7befe906877abab098c6e63a0e8
/2705/CH13/EX13.3/Ex13_3.sce
511e4e183434e3cbbe527fbbd8cd1be48d7d50cd
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
648
sce
Ex13_3.sce
clear; clc; disp('Example 13.3'); // aim : To determine // (a) the power output of the turbine // (b) the diagram efficiency // given values U = 150;// mean blade speed, [m/s] Cai1 = 675;// nozzle speed, [m/s] na = 20;// nozzle angle, [degree] m_dot = 4.5;// steam flow rate, [kg/s] // solution // from Fig. 13.15(diagram 13.3) Cw1 = 915;// [m/s] Cw2 = 280;// [m/s] // (a) P = m_dot*U*(Cw1+Cw2);// power of turbine,[W] mprintf('\n (a) The power of turbine is = %f kW\n',P*10^-3); // (b) De = 2*U*(Cw1+Cw2)/Cai1^2;// diagram efficiency mprintf('\n (b) The diagram efficiency is = %f percent\n',De*100); // End
3e58d647701736f1e3c227e351f6a1d1427a526c
3c47dba28e5d43bda9b77dca3b741855c25d4802
/microdaq/macros/mdaqBlockAdd.sci
9656e663c2ce03940183e63ecb23f0191e210f9e
[ "BSD-3-Clause" ]
permissive
microdaq/Scilab
78dd3b4a891e39ec20ebc4e9b77572fd12c90947
ce0baa6e6a1b56347c2fda5583fb1ccdb120afaf
refs/heads/master
2021-09-29T11:55:21.963637
2019-10-18T09:47:29
2019-10-18T09:47:29
35,049,912
6
3
BSD-3-Clause
2019-10-18T09:47:30
2015-05-04T17:48:48
Scilab
UTF-8
Scilab
false
false
15,582
sci
mdaqBlockAdd.sci
function mdaqBlockAdd(block_def) if type(block_def) <> 17 then disp("ERROR: Wrong type of input argument!"); if type(block_def) == 13 then disp("Input argument type is function - use ''block = mdaqBlock()'' instead of ''block = mdaqBlock''") else disp("Use mdaqBlock() function to create initialized block sctructure!") end return; end if size(block_def.in, 'r' ) > 1 then if size(block_def.in, 'c' ) > 1 then disp("ERROR: Wrong block ''in'' parameter - one dimentional array expected!"); return; end block_def.in = block_def.in'; end if size(block_def.out, 'r' ) > 1 then if size(block_def.out, 'c' ) > 1 then disp("ERROR: Wrong block ''out'' parameter - one dimentional array expected!") return; end block_def.out = block_def.out'; end if length(block_def.name) > 20 then disp("ERROR: Block name too long!"); return; end FORCE_SIM = %F; if haveacompiler() == %F & block_def.use_sim_script == %F then warning("Compiler not found."); warning("This block will use simulation script instead of C code during simulation mode."); FORCE_SIM = %T; end path = fileparts(get_function_path('mdaqBlockAdd')); module_path = part(path,1:length(path)-length("macros") - 1 ); SCRIPT_FILE_ROOT = path + 'user_blocks' + filesep(); C_FILE_ROOT = module_path+'src'+filesep()+'c'+ filesep()+'userlib'+filesep(); IMAGE_FILE_ROOT = module_path + filesep() + 'images' + filesep(); // =============================PREPARE INPUT===================================== params_size = max(size(block_def.param_name)); params_size_size = max(size(block_def.param_size)); params_def_val_size = max(size(block_def.param_def_val)); in_size = max(size(block_def.in)); out_size = max(size(block_def.out)); if block_def.in(1) < 1 then in_size = 0; end if block_def.out(1) < 1 then out_size = 0; end //If user did not enter enough information about size of parameters then //we set it to default 1. if params_size > params_size_size then sizes = ones(1:params_size)'; sizes(1:params_size_size) = block_def.param_size; block_def.param_size = sizes; end //If user did not enter enough information about default parameters value then //we set it to default 0. def_val = list(); for i=1:params_size def_val(i) = zeros(1:block_def.param_size(i))'; if i <= params_def_val_size then i_params_def_val_size = max(size(block_def.param_def_val(i))); def_val(i)(1:i_params_def_val_size) = block_def.param_def_val(i); end end block_def.param_def_val = def_val; // if block name changed without desc - change block name in desc if block_def.desc == "Set new_block parameters" then block_def.desc = strsubst(block_def.desc, "new_block", block_def.name); end // =============================GENERATE STRINGS===================================== // converted params params_converted = ''; // script file params_string1 = ''; params_string2 = ''; params_string3 = ''; params_string4 = ''; params_string5 = ''; //default values string params_string6 = ''; // C file in_ports_string = ''; out_ports_string = ''; params_c_string = ''; params_sci_string = ''; name_converted = convstr(block_def.name,'l'); name_converted = strsubst(name_converted, ' ', '_'); if strstr(name_converted, 'sim') <> "" then error("Cannot create block with '"*sim*'" word (known issue). Choose another block name."); end name_converted = 'mdaq_' + name_converted; for i = 1:params_size // Remove spaces and convert to lower case params_converted(i) = convstr(block_def.param_name(i),'l') params_converted(i) = strsubst(params_converted(i), ' ', '_') params_converted(i) = strsubst(params_converted(i), ';', '_') params_converted(i) = strsubst(params_converted(i), ':', '_') params_converted(i) = strsubst(params_converted(i), ',', '_') params_converted(i) = strsubst(params_converted(i), '.', '_') params_string1 = params_string1 + params_converted(i)+','; params_string2 = params_string2 + ''''+block_def.param_name(i)+':'';'; params_string3 = params_string3 + '''vec'','+ string(block_def.param_size(i)) + ','; params_string4 = params_string4 + 'sci2exp(' + params_converted(i) + ');'; params_string5 = params_string5 + params_converted(i)+';'; i_def_param_size = max(size(block_def.param_def_val(i))); i_param_def_string = ''; for j = 1:block_def.param_size(i) i_param_def_string = i_param_def_string + string(block_def.param_def_val(i)(j))+';'; end //default values string params_string6(i) = ' '+params_converted(i)+' = ['+i_param_def_string+'];'; end //delete last character ',' params_string3 = part(params_string3, 1:(length(params_string3)-1) ); in_string = ''; out_string = ''; if in_size > 0 then for i = 1:(in_size-1) in_string = in_string + string(block_def.in(i)) + ';'; end in_string = in_string + string(block_def.in(in_size)); end if out_size > 0 then for i = 1:(out_size-1) out_string = out_string + string(block_def.out(i)) + ';'; end out_string = out_string + string(block_def.out(out_size)); end block_v_size = 3; if max([out_size in_size]) > 2 then block_v_size = block_v_size + (max([out_size in_size]) - 2); end block_h_size = 4; if length(block_def.name) > 8 then block_h_size = block_h_size + ((length(block_def.name) - 8) * 0.2); end // =============================GENERATE SCRIPT===================================== // TODO define default params value // (block_def.name).sci script generator block_script = [ '// Generated with MicroDAQ toolbox ver: ' + mdaq_version() + ''; 'function [x,y,typ] = '+ name_converted + '(job,arg1,arg2)'; ' block_desc = [''' + block_def.desc + ''';'; ' '''';]'; ''; ' x=[];y=[];typ=[];'; ' select job'; ' case ''set'' then'; ' x=arg1;';]; if params_size > 0 then block_script = [block_script; ' model=arg1.model;'; ' graphics=arg1.graphics;'; ' exprs=graphics.exprs;'; ''; ' while %t do'; ' try'; ' getversion(''scilab'');'; ' [ok,'+params_string1+'exprs]=..' ' scicos_getvalue( block_desc,..'; ' ['+params_string2+'],..'; ' list('+params_string3+'), exprs)'; ' catch'; ' [ok,'+params_string1+'exprs]=..' ' getvalue(block_desc,..'; ' ['+params_string2+'],..'; ' list('+params_string3+'), exprs);'; ' end;'; ''; ' if ~ok then'; ' break'; ' end'; ''; ' if ok then'; ' [model,graphics,ok] = check_io(model,graphics, ['+in_string+'], ['+out_string+'], 1, []);'; ' graphics.exprs = exprs;'; ' model.rpar = ['+params_string5+'];'; ' model.ipar = [];'; ' model.dstate = [];'; ' x.graphics = graphics;'; ' x.model = model;'; ' break'; ' end'; ''; ' end']; end use_sim_string = [ ' if c_link('''+name_converted+''') then'; ' model.sim=list('''+name_converted+''',4);'; ' else'; ' model.sim=list('''+name_converted+'_sim'',5);'; ' warning(''Cannot link '''''+name_converted+''''' C function. Script '''''+name_converted+'_sim.sci'''' will be used instead.'');'; ' end'; ]; if block_def.use_sim_script == %T then use_sim_string = ' model.sim=list('''+name_converted+'_sim'',5);'; end block_script = [block_script; ' case ''define'' then'; params_string6; ' model=scicos_model();'; use_sim_string; ' model.in=['+in_string+'];'; ' model.in2=1;'; ' model.out=['+out_string+'];'; ' model.out2=1;'; ' model.outtyp=1;'; ' model.intyp=1;'; ' model.evtin=1;'; ' model.rpar=['+params_string5+'];'; ' model.ipar=[];'; ' model.dstate=[];'; ' model.blocktype=''d'';'; ' model.dep_ut=[%t %f];'; ' exprs=['+params_string4+'];'; ' gr_i=[''xstringb(orig(1),orig(2),['''''''' ; ],sz(1),sz(2),''''fill'''');''];'; ' x=standard_define([' + string(block_h_size) + ' '+string(block_v_size)+'],model,exprs,gr_i);'; ' x.graphics.in_implicit=[];'; ' x.graphics.exprs=exprs;'; ' x.graphics.style=[""blockWithLabel;verticalLabelPosition=center;displayedLabel=' + block_def.name + '""]'; ' end'; 'endfunction'; ]; // =============================GENERATE SIM SCRIPT===================================== index = 0; n_lines = 1; l = 1; for i = 1:n_lines:(params_size*n_lines) params_sci_string(i+1) = ' '+params_converted(l)+' = block.rpar('+string(index + 1)+');'; index = index + block_def.param_size(l); l = l + 1; end // (block_def.name)_sim.sci script generator init_string = ''; if FORCE_SIM == %T then init_string = [ ' mprintf('"\nWARNING: The '''''+name_converted+''''' block uses '''''+name_converted+'_sim.sci'''' script instead of C code during\n\t simulation mode. '');'; ' mprintf('"Make sure that the valid compiler is installed. More information is available at:\n'');'; ' mprintf('"\t https://help.scilab.org/doc/5.5.2/en_US/supported_compilers.html'');'; ]; end block_script_sim = [ '// Generated with MicroDAQ toolbox ver: ' + mdaq_version() + ''; 'function block='+name_converted+'_sim(block,flag)'; ''; ' global %microdaq'; ' if %microdaq.dsp_loaded == %F then'; params_sci_string; ' select flag'; ' case -5 // Error'; ' case 0 // Derivative State Update'; ' case 1 // Output Update'; ' case 2 // State Update'; ' case 3 // OutputEventTiming'; ' case 4 // Initialization'; init_string; ' case 5 // Ending'; ' case 6 // Re-Initialisation'; ' case 9 // ZeroCrossing'; ' else // Unknown flag'; ' break'; ' end'; 'end'; 'endfunction'; ]; // save scripts file_name = SCRIPT_FILE_ROOT+name_converted+'.sci'; save_string(file_name, block_script); file_name = SCRIPT_FILE_ROOT+name_converted+'_sim.sci'; save_string(file_name, block_script_sim); // =============================GENERATE C FILE ===================================== l = 1; n_lines = 3; index = 0; if in_size > 0 then in_ports_string(1) = ' /* Block input ports */'; for i = 2:n_lines:(in_size*n_lines+1) in_ports_string(i) = ' double *u'+string(l)+' = GetRealInPortPtrs(block,'+string(l)+');'; in_ports_string(i+1) = ' int u' +string(l)+ '_size = GetInPortRows(block,'+ string(l)+');'+... ' /* u' + string(l)+ '_size = '+string(block_def.in(l))+' */'; in_ports_string(i+2) = ''; l = l + 1; end end l = 1; if out_size > 0 then out_ports_string(1) = ' /* Block output ports */'; for i = 2:n_lines:(out_size*n_lines+1) out_ports_string(i) = ' double *y'+string(l)+' = GetRealOutPortPtrs(block,'+string(l)+');'; out_ports_string(i+1) = ' int y'+string(l)+'_size = GetOutPortRows(block,'+string(l)+');'+.... ' /* y' + string(l)+ '_size = '+string(block_def.out(l))+' */'; out_ports_string(i+2) = ''; l = l + 1; end end index = 0; n_lines = 2; l = 1; for i = 1:n_lines:(params_size*n_lines) if block_def.param_size(l) == 1 then params_c_string(i) = ' /* param size = 1 */'; params_c_string(i+1) = ' double '+params_converted(l)+' = params['+string(index)+'];'; else params_c_string(i) = ' int '+params_converted(l)+'_size = '+string(block_def.param_size(l))+';'; params_c_string(i+1) = ' double *'+params_converted(l)+' = &params['+string(index)+'];'; end index = index + block_def.param_size(l); l = l + 1; end block_c_file = [ '/* Generated with MicroDAQ toolbox ver: ' + mdaq_version() + ' */'; '#include '"scicos_block4.h'"'; ''; ''; 'extern double get_scicos_time( void );'; ''; '/* This function will executed once at the beginning of model execution */' 'static void init(scicos_block *block)'; '{'; ' /* Block parameters */'; ' double *params = GetRparPtrs(block);'; ''; params_c_string; ''; ' /* Add block init code here */'; '}'; ''; '/* This function will be executed on every model step */'; 'static void inout(scicos_block *block)'; '{'; ' /* Block parameters */'; ' double *params = GetRparPtrs(block);'; params_c_string; ''; in_ports_string; out_ports_string; ''; ' /* Add block code here (executed every model step) */'; ''; '}'; ''; '/* This function will be executed once at the end of model execution (only in Ext mode) */' 'static void end(scicos_block *block)'; '{'; ' /* Prameters */'; ' double *params = GetRparPtrs(block);'; ''; params_c_string; ''; ' /* Add block end code here */'; '}'; ''; 'void '+name_converted+'(scicos_block *block,int flag)'; '{'; ' if (flag == 1){ /* set output */'; ' inout(block);'; ' }'; ' else if (flag == 5){ /* termination */'; ' end(block);'; ' }'; ' else if (flag == 4){ /* initialisation */'; ' init(block);'; ' }'; '}'; ] file_name = C_FILE_ROOT+name_converted+'.c'; save_string(file_name, block_c_file); svg_path = IMAGE_FILE_ROOT + 'svg' + filesep(); gen_svg(svg_path, name_converted, block_def.name); // build macros and compile C code mdaqBlockBuild(%F, ~block_def.use_sim_script); mprintf("\tRestart Scilab to use new block\n"); endfunction function res = save_string(filename, content) [f,res] = mopen(filename,'w'); if res == 0 then mprintf(" ### Generating %s\n", filename); mputl(content,f) mclose(f) end endfunction function gen_svg(path,filename,label); doc = xmlRead(path+'mdaq_template.svg'); // Label handle node = doc.root.children(13).children(1); node.content = ""; xmlDump(node); xmlWrite(doc,path+filename+'.svg'); xmlDelete(doc); endfunction
28502adfd0ea32e733d71f481177b5f2af09620d
d5bd4b5a4760efd0a3d16d7c39c7b495c5874d28
/AnalogDigtitalCommunication/unipolarNRZ.sci
d6a4eefe498d8eebc8cf4477f307e679488f61f6
[]
no_license
APU-PhasedArrayBeamForming/Array-Based-Beam-Forming
27a61bc3cf93e544364121e508dc4d140b7e0cb1
4cde46b7aa3f4e995297ac72fc5038fa0cdf083d
refs/heads/master
2021-01-25T08:01:17.468481
2017-06-15T18:47:40
2017-06-15T18:47:40
93,699,808
1
1
null
2017-06-15T18:47:40
2017-06-08T02:36:01
Scilab
UTF-8
Scilab
false
false
616
sci
unipolarNRZ.sci
function [unipolar_out]=unipolarNRZ(x) //x-digital information signal binary_one = [1,1,1,1,1]; binary_zero = [0,0,0,0,0]; unipolar_out = []; for i = 1:length(x) if(x(i)==1) unipolar_out = [unipolar_out,binary_one]; else unipolar_out = [unipolar_out,binary_zero]; end end c = gca(); c.x_location = 'origin' plot2d2([0:length(unipolar_out)-1],unipolar_out); a = gce(); b = a.children(1); b.thickness = 3; title('Unipolar NRZ Line Coding technique') endfunction //Example 1 //x =[1,1,0,0,0,1,1,0]; //unipolarNRZ(x);
8bf6e394a21827262800d0a554b3801c39f5d9fe
d465fcea94a1198464d7f8a912244e8a6dcf41f9
/system/kiks_asciidecode.sci
3e520fbf92783cb5886768d95293d8bacb5c46fe
[]
no_license
manasdas17/kiks-scilab
4f4064ed7619cad9e2117a6c0040a51056c938ee
37dc68914547c9d0f423008d44e973ba296de67b
refs/heads/master
2021-01-15T14:18:21.918789
2009-05-11T05:43:11
2009-05-11T05:43:11
null
0
0
null
null
null
null
UTF-8
Scilab
false
false
669
sci
kiks_asciidecode.sci
function [res] = kiks_asciidecode(str) // Ouput variables initialisation (not found in input variables) res=[]; // Display mode mode(0); // Display warning for floating point exception ieee(1); // ----------------------------------------------------- // (c) 2000-2004 Theodor Storm <theodor@tstorm.se> // http://www.tstorm.se // ----------------------------------------------------- res = []; str = double(mtlb_double(str)); [tmp,sz] = size(str); for i = 1:2:sz // !! L.13: Matlab function bitshift not yet converted, original calling sequence used res = [res,mtlb_a(mtlb_double(bitshift(str(i)-asciimat("A"),4)),str(i+1)-asciimat("A"))]; end; endfunction
3da8caed2617ea40e3bb86664fe10f3286e6d0c2
449d555969bfd7befe906877abab098c6e63a0e8
/1445/CH2/EX2.6/ch2_ex_6.sce
078b110aa3531d47b4694adf53a71e2b47e79515
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
784
sce
ch2_ex_6.sce
//CHAPTER 2- STEADY-STATE ANALYSIS OF SINGLE-PHASE A.C. CIRCUIT //Example 6 disp("CHAPTER 2"); disp("EXAMPLE 6"); //VARIABLE INITIALIZATION f=50; //in Hertz I1=20; //in Amperes pf1=0.75; //power factor v=230; //in Volts pf2=0.9; //power factor(lagging) //SOLUTION phi1=acos(pf1); res1=tan(phi1); //result1 = tan(Φ1) phi2=acos(pf2); res2=tan(phi2); //result2 = tan(Φ2) Ic=I1*pf1*(res1-res2); w=2*%pi*f; c=Ic/(v*w); disp(sprintf("The value of capacitance is %f μF",c*(10^6))); Qc=v*Ic; disp(sprintf("The reactive power is %f kVAR",Qc/(10^3))); I2=I1*(pf1/pf2); disp(sprintf("The new supply current is %f A",I2)); //END
fc932d03a3940f665c91a0c0ccb60d350843d689
449d555969bfd7befe906877abab098c6e63a0e8
/1208/CH9/EX9.13/Exa13.sce
bfddb7572181792e352af6fd9d9e35e612e3bfef
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
528
sce
Exa13.sce
//Exa 13 clc; clear; close; // given data : ST=4300;//in hours AT=4000;//in hours SR=3;//in Rs/Hour GWP=16400;//in RS AR=GWP/AT;//in Rs/Hour //Labour Cost variance LCV=(ST*SR)-(AT*AR) //Labour Efficiency variance LEV=SR*(ST-AT);// in Rs //Labour Rate variance LRV=AT*(SR-AR);// in Rs disp(LCV,"Labour Cost variance : ") disp(LRV,"Labour Rate variance : ") disp(LEV,"Labour Efficiency variance : ") disp("Negative variances indicate adverse value "); disp("Positive variances indicate favourable value ");
fd2d07fc9838bc00f8d18f5dd7fc758b93157c3b
449d555969bfd7befe906877abab098c6e63a0e8
/2666/CH13/EX1.7/13_8.sce
3557cc6906088de5a56d713d484a001910182d28
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
220
sce
13_8.sce
clc //initialisation of variables c=1.390//Btu c1=1.491//Btu o=0.403//Btu n=2.087//Btu //CALCULATIONS M=c+c1+o+n//Btu per mol per deg //RESULTS printf('The specific heat of mixture =% f Btu per mol per deg',M)
e71f78d538239988109aac35a8f9c49fd53554bf
449d555969bfd7befe906877abab098c6e63a0e8
/1904/CH3/EX3.4/3_4.sce
81f50f250b8b2862816374a456e8e3e4a308db1a
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
565
sce
3_4.sce
//To determine the maximum load carried by the transformer //Page 122 clc; clear; //Transformer Ratings in kVA Sr1=250; Sr2=500; //percentage impedances Zr1=2.4; Zr2=3.1; //Ratio of Maximum Loads R=Sr1*Zr2/(Sr2*Zr1); //If 500 kVA is chosen as the full load transformer, Transformer 1 becomes overloaded SL1=Sr1; //To Avoid OverLoading of transformer 1 SL2=SL1/R; //Maximum Load on transformer 2 Tl=SL1+SL2; //Total Load without overloading printf('The Maximum Load Carried without overloading any of the transformer is %g kVA\n',Tl)
581cc6edc443d040e23569e399ede5462cd7491a
449d555969bfd7befe906877abab098c6e63a0e8
/1835/CH2/EX2.8/Ex2_8.sce
7fd767360480218d829007328ffebba972a1ea13
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
758
sce
Ex2_8.sce
//CHAPTER 2,ILLUSTRATION 8 PAGE 62 //TITLE:TRANSMISSION OF MOTION AND POWER BY BELTS AND PULLEYS clc clear //INPUT t=9//THICKNESS IN mm b=250//WIDTH IN mm D=90//DIAMETER OF PULLEY IN cm N=336//SPEED IN rpm PI=3.141 U=.35//COEFFICIENT FRICTION e=2.71 THETA=120*PI/180 Fb=2//STRESS IN MPa d=1000//DENSITY IN KG/M^3 //CALCULATION M=b*10^-3*t*10^-3*d//MASS IN KG V=PI*D*10^-2*N/60//VELOCITY IN m/s Tc=M*V^2//CENTRIFUGAL TENSION Tmax=b*t*Fb//MAX TENSION IN N T1=Tmax-Tc T2=T1/(e^(U*THETA)) P=(T1-T2)*V/1000 //OUTPUT printf('THE TENSION ON TIGHT SIDE OF THE BELT IS %f N\n',T1) printf('THE TENSION ON SLACK SIDE OF THE BELT IS %f N\n',T2) printf('CENTRIFUGAL TENSION =%f N\n',Tc) printf('THE POWER CAPACITY OF BELT IS %f KW\n',P)
4112a81775643f0f8228ae2cd917658d310917c4
449d555969bfd7befe906877abab098c6e63a0e8
/296/CH8/EX8.2/eg8_2.sce
b2f66d2e91adf71056c956af0fb10b401916f59a
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
101
sce
eg8_2.sce
Isc=100; Voc=0.8; ff = 0.7; Pmax = ff*Isc*Voc; disp(Pmax,"maximum power delivered(in miliwatt)=")
a242468a8dd9d438d257c5b930a006a52645d355
a5de878687ee2e72db865481785dafbeda373e2a
/trunck/OpenPR-0.0.2/demos/ahclustering.dem.sce
df75430f122f1a0c47d4b47a29df81776aae7c79
[ "BSD-3-Clause" ]
permissive
Augertron/OpenPR
8f43102fd5811d26301ef75e0a1f2b6ba9cbdb73
e2b1ce89f020c1b25df8ac5d93f6a0014ed4f714
refs/heads/master
2020-05-15T09:31:08.385577
2011-03-21T02:51:40
2011-03-21T02:51:40
182,178,910
0
0
null
null
null
null
UTF-8
Scilab
false
false
828
sce
ahclustering.dem.sce
mode(-1); lines(0); my_handle = scf(0); clf(my_handle,"reset"); demo_viewCode("ahclustering.dem.sce"); // DEMO START samples = rand(2,30); cluster_num = 3; dist_type = 'avg'; [centers, labels] = ahclustering(samples, cluster_num, dist_type); //show figures //scf(0); plot(samples(1,:), samples(2,:), 'b.', 'MarkerSize', 3); scf(1); clusters = unique(labels); plot(samples(1,find(labels==clusters(1))),samples(2,find(labels==clusters(1))),'g.','MarkerSize',3); set(gca(),"auto_clear","off"); plot(samples(1,find(labels==clusters(2))),samples(2,find(labels==clusters(2))),'y.','MarkerSize',3); set(gca(),"auto_clear","off"); plot(samples(1,find(labels==clusters(3))),samples(2,find(labels==clusters(3))),'m.','MarkerSize',3); set(gca(),"auto_clear","off"); plot(centers(1,:), centers(2,:), 'r.', 'MarkerSize', 4); // DEMO END
ac8e0601b22a8067c405e65e421d1ad35fd87c54
449d555969bfd7befe906877abab098c6e63a0e8
/779/CH9/EX9.16/9_16.sce
90320d710ec23ff0ab7edb3ed9e60ce36d740e09
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
816
sce
9_16.sce
// At dead state of 1 bar, 300K u0 = 113.1; h0 = 113.2; v0 = 0.001005; s0 = 0.0395; T0 = 300; P0 = 100; K = h0-(T0*s0); // Part (a) u = 376.9; h = 377; v = 0.001035; s = 1.193; m = 3; fi = m*(h-(T0*s)-K); // As P = P0 = 1 bar disp("kJ",fi,"Energy of system in Part (a) is") // Part (b) u = 3099.8; h = 3446.3; v = 0.08637; s = 7.090; // At P = 4 Mpa, t = 500 degree m = 0.2; fib = m*(u+P0*v-T0*s-K); disp("kJ",fib,"Energy of system in Part (b) is") // Part (c) m = 0.4; x = 0.85; // Quality u = 192+x*2245; h = 192+x*2392; s = 0.649+x*7.499; v = 0.001010+x*14.67; fic = m*(u+P0*v-T0*s-K); disp("kJ",fic,"Energy of system in Part (c) is") // Part (d) m = 3; h = -354.1; s = -1.298; // at 1000kPa, -10 degree fid = m*((h-h0)-T0*(s-s0)); disp("kJ",fid,"Energy of system in Part (d) is")
3c0dac6b0a032812c6f1f8a67572207efa46c7ee
449d555969bfd7befe906877abab098c6e63a0e8
/830/CH5/EX5.1.3/DFT2.sce
a9178f3dba9c128e49e6d01741e4781fc0fd20b9
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
215
sce
DFT2.sce
//Graphical// //Example 5.1.3 //Finding DFT and IDFT clear; clc; close; L = 4; // Length of the sequence N = 4; // N -point DFT x = [0,1,2,3]; //Computing DFT X = fft(x,-1) //Computing IDFT x_inv = real(fft(X,1))
eaba6d265f973c0c8dc3c4120e4728732ae3c22d
449d555969bfd7befe906877abab098c6e63a0e8
/623/CH1/EX1.1.12/U1_C1_12.sce
d7b2ad5e343e65297d1d22ec1abdf91e13332f40
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
776
sce
U1_C1_12.sce
//variable initialization deltaTow=1*10^(-6); //mean proper lifetime of particle (second) Beta=0.9 //value of Beta v=2.7*10^8; //velocity of particle (meter/second) //part(i):lifetime of the particle in the laboratory frame deltaT=deltaTow/((1-Beta^2)^(1/2)); //lifetime of the particle in the laboratory frame (second) //part(ii):distance traversed by the particle in the laboratory frame d=v*deltaT; //distance traversed by the particle in the laboratory before disintegration (meter) printf("\nIn laboratory frame:\n\t lifetime of the particle = %.2e second\n\t distance traversed by the particle = %.1e meter",deltaT,d);
95ca9e8c485ad1c808909a02a1b3e19dea3ab7b0
449d555969bfd7befe906877abab098c6e63a0e8
/2318/CH3/EX3.35/ex_3_35.sce
96b44b238140aa075b64077c11ca11c202eb71e3
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
305
sce
ex_3_35.sce
//Example 3.35:unknown resistance clc; clear; close; P=100.24;//ohms Q=200;//ohms S=100.03;//ohms x=(P/Q)*S*10^-6;//ohms q=200;//ohms r=700;//micro ohms p=100.31;//ohms y=((q*r*10^-6)/(p+q+(r*10^-6)));//ohms z=((P/Q)-(p/q));//ohms R=x+(y*z);//micro ohms disp(R*10^6,"unknown resistance is ,(micro-ohm)=")
347dd479669b90961395347a0c3c19eab255be00
449d555969bfd7befe906877abab098c6e63a0e8
/1952/CH12/EX12.26/Ex26.sce
5b7af6463302e2dee7ee49b0fff29d6f42e7fe2a
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
327
sce
Ex26.sce
// Additional solved examples , Example 26 , pg 343 I=22 // current(in A) A=9*10^-3 //area(in m^2) M=I*A //magnetic moment associated with the loop printf("Magnetic moment associated with the loop(in A m^2)=") disp(M) printf("M is directed towards the observer and is perpendicular to the plane of the loop")
a563f72f497607977d347f29fc9f3d8b5a8f560b
38012281b6334f56780d83d57af821a009c37ebe
/out/20_02_2019/Final_LrFijo_Repeticiones/Gijon_TEST_0.tst
f79804479983f9c8a7f2bfa2c655c68413c13c7e
[]
no_license
uo232368/TripAdvisor
2140422daa42fbae57b2eeb17d8829ff2378a822
74fa0131da52162d2f0bbcf6ceff91caa47ae220
refs/heads/master
2020-03-29T09:23:12.984191
2019-04-24T09:26:40
2019-04-24T09:26:40
149,755,513
0
0
null
null
null
null
UTF-8
Scilab
false
false
3,125
tst
Gijon_TEST_0.tst
Using TensorFlow backend. Obteniendo datos... [AVISO] Usuarios: 5139 [AVISO] Restaurantes: 598 [AVISO] Cargando datos generados previamente... Creando modelo... ################################################## MODELV4 ################################################## modelv4d2 ################################################## 0/45 1/45 2/45 3/45 4/45 5/45 6/45 7/45 8/45 9/45 10/45 11/45 12/45 13/45 14/45 15/45 16/45 17/45 18/45 19/45 20/45 21/45 22/45 23/45 24/45 25/45 26/45 27/45 28/45 29/45 30/45 31/45 32/45 33/45 34/45 35/45 36/45 37/45 38/45 39/45 40/45 41/45 42/45 43/45 44/45 /usr/lib/python3/dist-packages/xlsxwriter/worksheet.py:833: DeprecationWarning: invalid escape sequence \w if re.match('\w:', url) or re.match(r'\\', url): /usr/lib/python3/dist-packages/xlsxwriter/worksheet.py:962: DeprecationWarning: invalid escape sequence \s if re.search('^\s', token) or re.search('\s$', token): /usr/lib/python3/dist-packages/xlsxwriter/worksheet.py:962: DeprecationWarning: invalid escape sequence \s if re.search('^\s', token) or re.search('\s$', token): /usr/lib/python3/dist-packages/xlsxwriter/worksheet.py:3610: DeprecationWarning: invalid escape sequence \| elif re.match('(or|\|\|)', conditional): /usr/lib/python3/dist-packages/xlsxwriter/worksheet.py:3840: DeprecationWarning: invalid escape sequence \. name = re.sub('\..*$', '', name) /usr/lib/python3/dist-packages/xlsxwriter/worksheet.py:5136: DeprecationWarning: invalid escape sequence \s if re.search('^\s', string) or re.search('\s$', string): /usr/lib/python3/dist-packages/xlsxwriter/worksheet.py:5136: DeprecationWarning: invalid escape sequence \s if re.search('^\s', string) or re.search('\s$', string): /usr/lib/python3/dist-packages/xlsxwriter/sharedstrings.py:103: DeprecationWarning: invalid escape sequence \s if re.search('^\s', string) or re.search('\s$', string): /usr/lib/python3/dist-packages/xlsxwriter/sharedstrings.py:103: DeprecationWarning: invalid escape sequence \s if re.search('^\s', string) or re.search('\s$', string): /usr/lib/python3/dist-packages/xlsxwriter/comments.py:160: DeprecationWarning: invalid escape sequence \s if re.search('^\s', text) or re.search('\s$', text): /usr/lib/python3/dist-packages/xlsxwriter/comments.py:160: DeprecationWarning: invalid escape sequence \s if re.search('^\s', text) or re.search('\s$', text): ---------------------------------------------------------------------------------------------------- N_FOTOS_TRAIN (>=) N_ITEMS %ITEMS RND-MOD AC CNT-MOD AC MODELO 9 193 0.18866080156402737 0.12431166408328206 0.20188351181270722 0.13769103848508576 5 349 0.3411534701857282 0.09864989582301516 0.20550456548573884 0.16872803029441874 4 537 0.5249266862170088 0.07466648720854706 0.180556319865289 0.18544726144834833 2 798 0.7800586510263929 0.06400727887364521 0.15934351303336386 0.2146452526209656 1 1023 1.0 0.06155934920372694 0.15806459221402638 0.23406738950568629 ---------------------------------------------------------------------------------------------------- 45 0.0172 22.6794 0.2874 0.2341
6b793872ffc7709eb5e11e07a60cf3c2fbf0d2c1
e6d5f1d801a3fe887b5dc04b8cc0a9eabc1fd432
/Semana_4/nucleo.sce
d8802c34e1ba9e31f7bb876a28dbb09fc8575c06
[]
no_license
lordjuacs/MateIII
70def332063e56eb10fb47678a7e6130dc0dca63
164c53b61c9e35e565121f77ba2c578680a3ab56
refs/heads/master
2021-05-24T15:56:01.078904
2020-07-27T19:57:34
2020-07-27T19:57:34
253,643,962
0
0
null
null
null
null
UTF-8
Scilab
false
false
267
sce
nucleo.sce
clc M = [-2 0 3; -23 -15 -18; -5 -3 -3] X = [0 0 0]' N = M*X disp(N, "N1") X = [12 -28 8] N = M*X' disp(N, "N2") X = [1 -2 1]' N = M*X disp(N, "N3") X = [3 -7 2]' N = M*X disp(N, "N4") X = [2 -4 -4]' N = M*X disp(N, "N5") X = [9 -18 -15]' N = M*X disp(N, "N6")
6925ad94301bce7f69ee36aaafabc039bcf47c3e
6e257f133dd8984b578f3c9fd3f269eabc0750be
/ScilabFromTheoryToPractice/CreatingPlots/testuicontrol.sce
72c4b6a9cc9efd667eef58187ab0c76375898bf2
[]
no_license
markusmorawitz77/Scilab
902ef1b9f356dd38ea2dbadc892fe50d32b44bd0
7c98963a7d80915f66a3231a2235010e879049aa
refs/heads/master
2021-01-19T23:53:52.068010
2017-04-22T12:39:21
2017-04-22T12:39:21
89,051,705
0
0
null
null
null
null
UTF-8
Scilab
false
false
565
sce
testuicontrol.sce
hfig = figure(... 'Tag', 'myfigure', ... 'BackgroundColor', name2rgb("lightblue")/255, ... 'Figure_name', 'My Figure', ... 'Position', [20 20 300 200]); hobj = uicontrol(hfig, ... 'Style', 'edit', ... 'Tag', 'val', ... 'String', 'enter text', ... 'HorizontalAlignment', 'left', ... 'FontAngle', 'italic', ... 'FontSize', 20, ... 'FontWeight', 'bold', ... 'BackgroundColor', name2rgb("gray")/255, ... 'ForegroundColor', name2rgb("black")/255, ... 'FontUnits', 'pixels', ... 'FontName', 'helvetica', ... 'Position', [50 100 200 20]);
0338ebe9c37910f8762dd96c92f83bfa9b55d864
449d555969bfd7befe906877abab098c6e63a0e8
/2495/CH4/EX4.6.2/Ex4_6_2.sce
785a232a5a3617986a9c8aa8c052b7259ab8cb0f
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
557
sce
Ex4_6_2.sce
clear clc V1=500;//volume of H2O in cm^3 V2=15.03;//volume of CH4 in cm^3 V=V2/V1;//volume dissolved in 1 cm^3 water P=1;//pressure in atm T=273;//Temperature in K R=82.06;//In cm^3atm/Kmol X=(P*V)/(R*T);//amount of gas dissolved in mol M=(X*16);//mass of gas dissolved in gm K=M/P;// m1=0.001;//amount of CH4 in mol m2=300;//amount of H20 in cm^3 M1=(m1*16)/m2;//mass of gas dissolved in 1 cm^3 P0=M1/K;//pressure if Henry's law holds in atm printf('P0=%.3f atm',P0) //There are some errors in the solution given in textbook //page 58
2686c60c809a69e0986d11246976b2aabf3c2112
1d7cb1dbfad2558a4145c06cbe3f5fa3fc6d2c08
/Scilab/NRZBandwidthStudy/Fig2-TimeDomainPulseTrapezoid.sce
241eef1372b3970582e4813a2c6f73b535048061
[]
no_license
lrayzman/SI-Scripts
5b5f6a8e4ae19ccff53b8dab7b5773e0acde710d
9ab161c6deff2a27c9da906e37aa68964fabb036
refs/heads/master
2020-09-25T16:23:23.389526
2020-02-09T02:13:46
2020-02-09T02:13:46
66,975,754
0
0
null
null
null
null
UTF-8
Scilab
false
false
644
sce
Fig2-TimeDomainPulseTrapezoid.sce
// Plot of arbitrary pulse train // (c)2008 Lenny Rayzman //////////SPECIFY///////////////////// samplerate=1000; // Number of points per period (must be multiple of 2) ////////////////////////////////////// pulseofn=zeros(1, samplerate+1); // Generate a single pulse pulseofn(250:749)=ones(1, samplerate/2); tofn=[-1:1/(samplerate/2):1]; plot2d(tofn, pulseofn, style=2, rect=[-1, -0.25, 1, 1.25]); //xgrid(4); trapofn=zeros(1, samplerate+1); // Generate trapezoidal pulse trapofn(350:649)=ones(1, 649-350+1); plot2d(tofn, trapofn, style=5, rect=[-1, -0.25, 1, 1.25]); //xgrid(4);
e45d30ad8671c873014fce2a75e08d0f20ef3499
9bc415d58bf063a1bca303fea640e644333dbdbd
/Scilab/polar2.sce
55f9acc3ac79c9aee48fb79d472cc75d3886af68
[]
no_license
Roast-Lord/SMGcodes
36e55be6c1cc17af91ab2e3f5117c78684f20604
b75107be829fb4373dc1bc4b8696fe4b9cec437a
refs/heads/main
2023-07-05T05:25:50.557705
2021-08-17T17:46:25
2021-08-17T17:46:25
301,012,145
1
0
null
null
null
null
UTF-8
Scilab
false
false
193
sce
polar2.sce
function [mod,fase]=polar2(z) mod = abs(z) fase = atan(imag(z),real(z)) endfunction function [mod,fase] = polard(z) mod = abs(z) fase = atand(imag(z),real(z)) endfunction
2bfe63556264682bfb8a5f80fe673988118d14b1
449d555969bfd7befe906877abab098c6e63a0e8
/1673/CH3/EX3.17/3_17.sce
9c87d06e06682821aa591463690a1be25004ee48
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
589
sce
3_17.sce
//lagrange's interpolation //example 3.17 //page 106 clc;clear;close; x=[0 3 4]; y=[-12 12 24]; //1 appears to be one the roots the polynomial for i=1:3 r_x(i)=y(i)/(x(i)-1); end deff('y=l0(x)','y=((x-3)*(x-4))/((-3)*(-4))') x=poly(0,'x'); disp(l0(x),'l0(x)='); deff('y=l1(x)','y=((x-0)*(x-4))/((3)*(-1))') x=poly(0,'x'); disp(l1(x),'l1(x)='); deff('y=l2(x)','y=((x-0)*(x-3))/((4)*(1))') x=poly(0,'x'); disp(l2(x),'l2(x)='); disp(l0(x)*r_x(1)+l1(x)*r_x(2)+l2(x)*r_x(3),'f_(x)='); disp((x-1)*(l0(x)*r_x(1)+l1(x)*r_x(2)+l2(x)*r_x(3))','the required polynimial is :')
74e884198b4e1051ae64ffa85f61c6a4b8a94b65
449d555969bfd7befe906877abab098c6e63a0e8
/1640/CH6/EX6.15/6_15.sce
9415f6440eb260c65616206f1c21642977f80a81
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
321
sce
6_15.sce
clc //initialisation of variables Q= 360 //cfs d1= 1 //ft B= 18 //ft g= 32.2 //ft/sec^2 w1= 624. //lb/ft^3 d2=4.5 //ft //CALCULATIONS w= Q/B v1= w/d1 v2= v1/d2 d2= -0.5+sqrt((2*v1^2*d1/(g))+(d1^2/4)) El= (d1+(w^2/(2*g)))-(d2+(v2^2/(2*g))) EL= w1*Q*El //RESULTS printf ('loss in energy = %.f lb ',EL)
50629e8f55a42bfdb2e85fa6579cef3852d33da0
449d555969bfd7befe906877abab098c6e63a0e8
/50/CH5/EX5.15/ex_5_15.sce
b56793e06ff5b93b056ee795041199052f18136e
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
754
sce
ex_5_15.sce
// example :5.15 // find the quadrature formula of // integral of f(x)*(1/sqrt(x(1+x))) in the range [0,1]= a1*f(0)+a2*f(1/2)+a3*f(1)=I // hence find integral 1/sqrt(x-x^3) in the range [0,1] // making the method exact for polinomials of degree upto 2, // I=I1=a1+a2+a3 // I=I2=(1/2)*a2+a3 // I=I3=(1/4)*a2+a3 // A=[a1 a2 a3]' I1=integrate('1/sqrt(x*(1-x))','x',0,1) I2=integrate('x/sqrt(x*(1-x))','x',0,1) I3=integrate('x^2/sqrt(x*(1-x))','x',0,1) //hence // [1 1 1;0 1/2 1 ;0 1/4 1]*A=[I1 I2 I3]' A=inv([1 1 1;0 1/2 1 ;0 1/4 1])*[I1 I2 I3]' // I=(3.14/4)*(f(0)+2*f(1/2)+f(1)); // hence, for solving the integral 1/sqrt(x-x^3) in the range [0,1]=I deff('[y]=f(x)','y=1/sqrt(1+x)'); I=(3.14/4)*[1+2*sqrt(2/3)+sqrt(2)/2]
7d3cb620995865608a5db002631f25bc9a3d2596
449d555969bfd7befe906877abab098c6e63a0e8
/620/CH1/EX1.5/example1_5.sce
ad53dc34d6a2c36c5250dd5dd1082df5274fea56
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
249
sce
example1_5.sce
disp("Part a"); disp("at A the reading is 0.72 V"); disp("at B the reading is 2.37 V"); disp("at C the reading is 4.30 V"); disp("Part b"); disp("at A the reading is 23 V"); disp("at B the reading is 75 V"); disp("at C the reading is 136 V");
856c8a238801f97dfd5fa7d99350334d3eadc71a
449d555969bfd7befe906877abab098c6e63a0e8
/401/CH6/EX6.5/Example6_5.sce
1d0d91a55d0b4670500faf0843d7ab044f520783
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
786
sce
Example6_5.sce
//Example 6.5 //Program to determine the threshold current density and the //threshold current for the device clear; clc ; close ; //Given data n=3.6; //REFRACTIVE INDEX OF GaAs beeta_bar=21*10^(-3); //A/cm^3 - GAIN FACTOR alpha_bar=10; //per cm - LOSS COEFFICIENT L=250*10^(-4); //cm - LENGTH OF OPTICAL CAVITY W=100*10^(-4); //cm - WIDTH OF OPTICAL CAVITY //Reflectivity for normal incidence r=((n-1)/(n+1))^2; //Threshold current density Jth=1/beeta_bar*(alpha_bar+1/L*log(1/r)); //Threshold current Ith=Jth*W*L; //Displaying the Results in Command Window printf("\n\n\t Threshold current density is %0.2f X 10^3 A/cm^2.",Jth/10^3); printf("\n\n\t Threshold current is %0.1f mA.",Ith/10^(-3));
98e6cbdff883d61e38d4ad44d19de683d12a8b04
449d555969bfd7befe906877abab098c6e63a0e8
/1034/CH4/EX4.4/4s4.sce
cf9890d009a923a80b664328e027febaf8cb96c3
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
3,854
sce
4s4.sce
//Deletion from the list: function[link2]=append(ele,link1) link2=list(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,,0,0); if(link1(1)(1).add==0) link1(1)(1).data=ele; link1(1)(1).add=1; link1(1)(1).nexadd=0; link1(1)(1).prevadd=0; link2(1)=link1(1)(1); else if(link1(1)(1).nexadd==0) lin2=link1(1)(1); lin2.data=ele; lin2.add=link1(1)(1).add+1; link1(1)(1).nexadd=lin2.add; lin2.nexadd=0; lin2.prevadd=link1(1)(1).add; link2(1)=link1(1)(1); link2(2)=lin2; else lin2=link1(1)(1); i=1; while(link1(i)(1).nexadd~=0) i=i+1; end j=i; lin2.data=ele; lin2.add=link1(i).add+1; lin2.nexadd=0; link1(i).nexadd=lin2.add; lin2.prevadd=link1(i).add; link2(1)=link1(1)(1); i=2; while(link1(i).nexadd~=lin2.add) link2(i)=(link1(i)); i=i+1; end link2(i)=link1(i); link2(i+1)=lin2; end end endfunction function[link2]=add(ele,pos,link1); link2=list(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,,0,0); i=1; while(i<=pos) if(link1(i).nexadd==0) break; else i=i+1; end end if(link1(i).nexadd~=0) i=i-1; lin2.data=ele; lin2.add=i; j=i; while(link1(j).nexadd~=0) link1(j).prevadd=link1(j).prevadd+1; link1(j).add=link1(j).add+1; link1(j).nexadd=link1(j).nexadd+1; j=j+1; end link1(j).prevadd=link1(j).prevadd+1; link1(j).add=link1(j).add+1; lin2.nexadd=link1(i).add; link1(i).prevadd=lin2.add; lin2.prevadd=link1(i-1).add; link1(i-1).nexadd=lin2.add; k=1; while(k<i) link2(k)=link1(k); k=k+1; end link2(k)=lin2; k=k+1; link2(k)=link1(k-1); k=k+1 l=k-1; while(k~=j) link2(k)=link1(l); k=k+1; l=l+1; end link2(j)=link1(j-1);; link2(j+1)=link1(j); else if(i==pos) k=1; lin2.data=ele; lin2.add=link1(i-1).add+1; link1(i).add=link1(i).add+1; lin2.nexadd=link1(i).add; link1(i).prevadd=lin2.add; lin2.prevadd=link1(i-1).add; k=1; while(k<pos) link2(k)=link1(k); k=k+1; end link2(k)=lin2; link2(k+1)=link1(k) end end endfunction function[link2]=delete1(pos,link1) link2=list(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,,0,0); i=1; while(i<=pos) if((link1(i).nexadd==0)) break; else i=i+1; end end if(link1(i).nexadd~=0) i=i-1; j=1; if(i==1) j=1; while(link1(j).nexadd~=0) link2(j)=link1(j); j=j+1; end link2(j)=link1(j); else link1(i-1).nexadd=link1(i+1).add; link1(i+1).prevadd=link1(i-1).add; while(link1(j).nexadd~=link1(i+1).add) link2(j)=link1(j); j=j+1; end if(j~=i-1) link2(j)=link1(j); link2(j+1)=link1(j+1); k=i+1; l=2; else link2(j)=link1(j); k=i+1; l=1; end while(link1(k).nexadd~=0) link2(j+l)=link1(k); k=k+1; l=l+1; end link2(j+l)=link1(k); end else if(i==pos) j=1; link1(i-1).nexadd=0; while(j<=i-1) link2(j)=link1(j); j=j+1; end end end endfunction //Calling Routine: link1=struct('data',0,'add',0,'nexadd',0); link1=append(4,link1); link1=append(6,link1); link1=add(10,2,link1); link1=delete1(3,link1); disp(link1,"After the above manipulation the list is");
ff257c1811e4a7a64b8ad5598515c51fa3759722
449d555969bfd7befe906877abab098c6e63a0e8
/135/CH3/EX3.8/EX8.sce
a957ff43507a49d8379192a4e17163d6f8c0ed33
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
223
sce
EX8.sce
// Example 3.8: Full-scale reading clc, clear Idc=5e-3; // in amperes Rf=40; // in ohms RL=20e3; // in ohms Vrms=Idc*(RL+Rf)*%pi/(2*sqrt(2)); // Full-scale deflection in volts disp(Vrms,"Full-scale deflection (V) =");
aad85ac33705e29d3bb15a6210b926f17d1c95e9
449d555969bfd7befe906877abab098c6e63a0e8
/599/CH2/EX2.2/example2_2.sce
a55167831d90f97786705a7e048f6b90a8fe3679
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
569
sce
example2_2.sce
clear; clc; printf("\t Example 2.2\n"); //kopp's law is valid u=1.145*10^-3; //viscosity of water1.145cp v_a=5*.0148+12*.0037+1*.0074; //by kopp's law t=288; //temperature of water in kelvin MB=18; //molecular weight of water phi=2.26; //association parameter for solvent-water D_ab=(117.3*10^-18)*((phi*MB)^.5)*(t)/(u*(v_a)^.6); printf("\n the diffusivity of isoamyl alcohol is :%f *10^-9 m^2/s",D_ab/10^-9); //end
59e10fc0ea0c8e849c7a3baf7c1920adf90c096d
449d555969bfd7befe906877abab098c6e63a0e8
/3159/CH8/EX8.3/Ex8_3.sce
60f1830061fae070c5cfb3acc542d56d8afcde94
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
746
sce
Ex8_3.sce
// Calculate minimum depth up to which post machining is to be done clc D_0 = 0.7e-4 // diffusion coefficient Q = 157 // Energy in kJ mol^-1, considered from table 8.2 R = 8.314// Universal gas constant T = 950 // temperature in Celsius c2 = 0.8 // concentration in percentage cs = 0 // concentration in percentage c_x = 0.6// concentration in percentage t = 4 // time in hours a = 1 //let printf("\n Example 8.3") A = cs B = c2-cs D = D_0*exp(-Q*1e3/(R*(T+273))) k = erf(((A-c_x)/B))*-1 if k >0.7 then if k<0.712 then z = 0.81 // from table end end x = z*2*sqrt(D*t*3600) printf("\n Depth up to which machining is required is nearly %.2f mm",x*1e3) // numerical value of answer in book is 0.75
941fc39fd4db7c0d67acde74256780c2838e17c4
d5bd4b5a4760efd0a3d16d7c39c7b495c5874d28
/Scripts/wavread.sce
645038e7fad35d9ada348c7ed39659e8ea176354
[]
no_license
APU-PhasedArrayBeamForming/Array-Based-Beam-Forming
27a61bc3cf93e544364121e508dc4d140b7e0cb1
4cde46b7aa3f4e995297ac72fc5038fa0cdf083d
refs/heads/master
2021-01-25T08:01:17.468481
2017-06-15T18:47:40
2017-06-15T18:47:40
93,699,808
1
1
null
2017-06-15T18:47:40
2017-06-08T02:36:01
Scilab
UTF-8
Scilab
false
false
270
sce
wavread.sce
y=wavread("./Fc100KHz_2MSPS_1KHzModulation_June12_2017.wav") //[y,Fs,bits]=wavread("./Record.wav");Fs,bits //Fs //bits subplot(2,1,1) plot2d(y(1,:)) // first channel subplot(2,1,2) plot2d(y(2,:)) // second channel //y=wavread("./Record.wav") //the first five samples
257b71eb194e4a11296a23869f35da08fbf6965b
449d555969bfd7befe906877abab098c6e63a0e8
/1163/CH11/EX11.6/example_11_6.sce
75d95467e190728911c800027035f0aa7cf48c15
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
865
sce
example_11_6.sce
clear; clc; disp("--------------Example 11.6---------------") // example explaination printf("This an example of Go-Back-N. This is an example of a case where the forward channel is reliable, but the reverse is not.\nNo data frames are lost, but some ACKs are delayed and one is lost. The example also shows how cumulative\nacknowledgments can help if acknowledgments are delayed or lost.\n"); printf("\nAfter initialization, there are seven sender events. Request events are triggered by data from the network layer;\narrival events are triggered by acknowledgments from the physical layer. There is no time-out event here because all\noutstanding frames are acknowledged before the timer expires.Although ACK 2 is lost, ACK 3 serves as both ACK 2 and ACK3.\n\nThere are four receiver events, all triggered by the arrival of frames from the physical layer.")
83fa969a799fa8a778374de30ca1ca730f8d6549
449d555969bfd7befe906877abab098c6e63a0e8
/668/CH9/EX9.3/eg9_3.sce
7490ea8ea8681961dfdd669d57823b554e41f0c3
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
721
sce
eg9_3.sce
Na = 3*10^16; t = 500*10^-8; Vfb = -1.13; T = 300; kT = 26*10^-3; //in eV q = 1.6*10^-19; ni = 1.5*10^10; eps0 = 8.85*10^-14; //in F/m eps = 11.9*eps0; eps1 = 3.9*eps0; c = 10^11; phiF = kT*log(Na/ni); disp(phiF,"The position of the Fermi level (in V) is given by (measured from the intrinsic Fermi level)") Qs = (4*eps*phiF*q*Na)^0.5; disp(Qs,"Under the assumption that the charge Qs is simple NaW where W is the maximum depletion width, we get Qs (in C per cm2)= ") Vt = Vfb+2*phiF+(Qs*t/eps1); disp(Vt,"In the absence of any oxide charge, the threshold voltage (in V) = ") dVt = c*q*(t/eps1); disp(dVt,"In the case where the oxide has trap charges, the threshold voltage is shifted by ΔVT (in V)= ")
0cadc77c07b6a50f2737281e534636db6b46e2f2
449d555969bfd7befe906877abab098c6e63a0e8
/2681/CH8/EX8.3/Ex8_3.sce
48c110812fb5179d70ad93b7997ad2616de2bf55
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
587
sce
Ex8_3.sce
//half power radiation pattern and beamwidth between first null //given clc Da=0.15//metre f=9d+9//hertz v=3d+8//m/s lemda=v/f//metre NNBW=140*(lemda/Da)//degree HPBW=70*(lemda/Da)//degree gp=6.4*(Da/lemda)^2//gain pattern gp_decibles=10*log10(gp)//changing to db gp_decibles=round(gp_decibles*100)/100///rounding off decimals HPBW=round(HPBW*100)/100///rounding off decimals NNBW=round(NNBW*100)/100///rounding off decimals disp(gp_decibles,HPBW,NNBW,'the half power beamwidth and beamwidth between first null and the gain pattern in degrees and decibles')//degree,db
6ad4302546a053667136bb6f5713acdea1c53b0a
449d555969bfd7befe906877abab098c6e63a0e8
/1026/CH11/EX11.5/Example11_5.sce
b4f1c540e4726b8865c7b85ae8b5a0b413e6e362
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
232
sce
Example11_5.sce
//chapter11,Example11_5,pg 300 mn=1.676*10^-27//mass of neutron h=6.625*10^-34 En=1.6*10^-19//energy of neutron v=sqrt((2*En)/mn) lam=(h/(mn*v))//de-broglie wavelength printf("de-broglie wavelength\n") disp(lam)
eca09561b6306bc8d0473b6f9feb3d87a8d99c84
27fecbbeb6c49dcf03b9bddf1b867c31e13a3825
/Modelagem e controle/root_locus.sce
32bbfb5fd7fd658fcfc8d1f1a93a14bae6eed644
[]
no_license
LucasHattoriCosta/Poli
42c9fc2d34c31e01336265fbdac3e4921d56e096
b1ac609c3675539b4e921909c35ea196ffc44df3
refs/heads/master
2023-03-15T12:22:03.745943
2020-06-29T17:32:48
2020-06-29T17:32:48
null
0
0
null
null
null
null
UTF-8
Scilab
false
false
1,016
sce
root_locus.sce
// Questão 1 // t = 0:0.01:10 s = %s num = s + 1 den = s^4 + 3*s^3 + 12*s^2 - 16*s Kp = 30 Kd = 700 PD = Kp + Kd*s FTMA_1 = syslin('c', (PD*num)/(den + PD*num)) disp(FTMA_1) y = csim('step', t, tf2ss(FTMA_1)) scf(0) plot2d(t, y, 2) xgrid() xtitle("Ganho Kd = 700", "Tempo (segundos)", "Resposta") // Questão 2 // // Em MA G = 1/(s^2+4*s+5) H = 1/(s+1) FTMA = syslin('c', G*H) scf(1) evans(FTMA) // Em MF Kp = 25 FTMF = syslin('c', Kp*G/(1+Kp*G*H)) y = csim('step', t, tf2ss(FTMF)) scf(2) plot2d(t, y, 3) xgrid() xtitle("Kp = 25", "Tempo (segundos)", "Resposta") // Questão 3 // i = %i s = %s G3 = ((s+i)*(s-i))/(s*(s+1)) FTMA_3 = syslin('c', G3) // Questão 4 // G4 = (s+2)/((s+1+i)*(s+1-i)) FTMA_4 = syslin('c', G4) // Questão 5 // Gc = (1+(2/3)*s+1/(3*s)) Gp = 1/((20*s+1)*(10*s+1)) H = 1/((s/2)+1) K = 1 FTMA_5 = syslin('c', Gc*Gp*H) FTMF_5 = syslin('c', K*Gc*Gp/(1+K*H*Gc*Gp)) disp(FTMA_5) disp(FTMF_5) scf(3) evans(FTMA_5) // Questão 6 // G = (s+1)/(s^2*(s+9)) FTMA_6 = syslin('c', G) scf(4) evans(FTMA_6)
500083561b64417e95a24db3d7b37cbcafb30f79
dc1d4188dde04f37ab742ea41096ef8c2696f393
/hw2.sci
e74a68f71c50bef1a2e686aebb875c0e690a40cb
[]
no_license
reservoirman/QC
0253b184a2f75e5e5b7e83187b49b0e9c0bcf376
3e6c2ac1b6e47ffbbc2638afa3bf86f925182272
refs/heads/master
2021-01-23T00:06:27.731537
2015-03-03T17:22:13
2015-03-03T17:22:13
31,513,036
0
0
null
null
null
null
UTF-8
Scilab
false
false
2,452
sci
hw2.sci
//Ten-Seng Guh tg2458 //COMS 4281 Intro to Quantum Computing //Homework 2 Programming Part args = sciargs() numargs = size(args, 2) epsilon = 10e-4 badinput = 0 if (numargs == 7) then components = tokens(args(7),[" ";" ";",";"(";")"]) if (size(components, 1) == 8) then epsilon = (strtod(args(6))) u11a = (components(1)) u11b = (components(2)) u12a = (components(3)) u12b = (components(4)) u21a = (components(5)) u21b = (components(6)) u22a = (components(7)) u22b = (components(8)) //disp(components) u11 = complex(strtod(u11a), strtod(u11b)) u12 = complex(strtod(u12a), strtod(u12b)) u21 = complex(strtod(u21a), strtod(u21b)) u22 = complex(strtod(u22a), strtod(u22b)) //disp(u11) //disp(u12) //disp(u21) //disp(u22) U = [u11 u12; u21 u22]; //shorthand secret way of inputting the 6 unitary matrices: //just simply input the else if (size(components, 1) == 1) select components(1) case 'X' U = [ 0 1; 1 0]; case 'Y' U = [0 -%i; %i 0]; case 'Z' U = [1 0; 0 -1]; case 'H' U = (1/sqrt(2)) * [1 1; 1 -1]; case 'S' U = [1 0; 0 %i]; case 'T' U = [1 0; 0 sqrt(%i)]; end else badinput = 1 printf("Matrix submitted incorrectly! Must be in the form:\n\n") end end else //default values for j,k, and m disp("Incorrect number of args! Must be in the form:") badinput = 1 end if (badinput == 0) then disp("U = ") disp(U) get0 = [1;0] get1 = [0;1] U3 = U * U * U Udiff = U - U3 disp("U^3 = ") disp(U3) disp("U - U3 = ") disp(Udiff) upperBound = abs(2 * sqrt( ((U - U3)*get0).^2 + ((U - U3)*get1).^2 ) ) disp("Upper Bound = ") disp(upperBound) if (upperBound <= epsilon) disp("YES") else disp("NO") end else printf("scilab -nw -f hw1.sci -args epsilon\""(a1, b1), (a2, b2), (a3, b3), (a4, b4)\""\n\n") printf("Epsilon represents the cutoff value to check if the circuits are equivalent. It should be represented as a small floating point number, eg. \""10e-4\""\n\n") printf("Each tuple (a, b) represents a complex number.") end exit
94365c1a99aae220436780f968814224eabb1c4a
00fc439a1f2cc38d50ec7b050222d6ba1c2b76cf
/main.sce
9dc8455867a6448ec7dca8cf077e5bce7fde227a
[]
no_license
slevin48/datadeploy
c9cc657db8d45aa0ab8fa5845b8f2552f3781140
1ed8be8d0b4ad5ab5cbdb91f20338df90e913f88
refs/heads/master
2022-07-28T20:19:46.917688
2020-05-25T08:58:25
2020-05-25T08:58:25
266,721,169
0
0
null
null
null
null
UTF-8
Scilab
false
false
307
sce
main.sce
// First time use M = ['A','B'; '1','2'; '3','4'] header = M(1,:) data = M(2:$,:) herokuapp='datadeploy48'; // datadeploy(header,data,herokuapp) //Full workflow gitinit(herokuapp) cd(SCIHOME) // gitclone() cd('datadeploy') csvWrite([header;data],"data.csv") // gitpull() herokupython() gitpush()
963f302db7ce1b240495ceb4e1ad88fbc4d3bd10
e9d5f5cf984c905c31f197577d633705e835780a
/GED/nonlinear/scilab/nonlin_rn96_2/nonlin_rn96_2.sce
72e36549eaf65207fcd7a80ba1ae9342ade8bfe7
[]
no_license
faiz-hub/dr-ged-benchmarks
1ad57a69ed90fe7595c006efdc262d703e22d6c0
98b250db9e9f09d42b3413551ce7a346dd99400c
refs/heads/master
2021-05-18T23:12:18.631904
2020-03-30T21:12:16
2020-03-30T21:12:16
null
0
0
null
null
null
null
UTF-8
Scilab
false
false
7,200
sce
nonlin_rn96_2.sce
// Data Reconciliation Benchmark Problems From Lietrature Review // Author: Edson Cordeiro do Valle // Contact - edsoncv@{gmail.com}{vrtech.com.br} // Skype: edson.cv //Rao, R Ramesh, and Shankar Narasimhan. 1996. //“Comparison of Techniques for Data Reconciliation of Multicomponent Processes.” //Industrial & Engineering Chemistry Research 35:1362-1368. //http://dx.doi.org/10.1021/ie940538b. //Bibtex Citation //@article{Rao1996, //author = {Rao, R Ramesh and Narasimhan, Shankar}, //isbn = {0888-5885}, //journal = {Industrial \& Engineering Chemistry Research}, //month = apr, //number = {4}, //pages = {1362--1368}, //publisher = {American Chemical Society}, //title = {{Comparison of Techniques for Data Reconciliation of Multicomponent Processes}}, //url = {http://dx.doi.org/10.1021/ie940538b}, //volume = {35}, //year = {1996} //} // 12 Streams // 7 Equipments // 4 Compounds getd('.'); getd('../functions'); clear tstraoflow_full tstraoflow tstraocomp_full tstraocomp At umeas fixed red lower upper var_lin_type constr_lin_type constr_lhs constr_rhs just_measured observ non_obs spec_cand x_sol f_sol lower upper extra xmfull ncomp var jac nc nv nnzjac nnz_hess sparse_dg sparse_dh lower upper var_lin_type constr_lin_type constr_lhs constr_rhs // In the original paper, streams 2 to 12 are unmeasured, //theses values are estimates givem by the paper's original author. // 1 2 3 4 5 6 7 8 9 10 11 12 tstrao_flow_full_rn96_2 = [695 730 700 685 35 15 30 20 35 5 10 15]; // 1 2 3 4 5 6 7 8 9 10 11 12 tstrao_comp_full_rn96_2 = [ 0.679 1.108 0.587 0.340 9.616 11.871 13.246 7.925 14.661 23.149 23.889 23.642 2.919 2.971 2.609 2.578 3.993 4.040 11.410 3.959 10.441 4.626 26.313 19.083 3.795 4.277 3.985 3.814 13.851 11.780 11.103 15.404 12.026 17.562 2.502 7.522 92.606 91.644 92.819 93.268 72.540 72.309 64.241 72.713 62.872 54.662 47.297 49.752]/100; //information of measured/unmeasured(-1)/fixed(-5) // 1 2 3 4 5 6 7 8 9 10 11 12 tstrao_flow_rn96_2 = [-5, -1, -1, -1, -1, -1, -1 , -1, -1, -1, -1, -1] ; // 1 2 3 4 5 6 7 8 9 10 11 12 tstrao_comp_rn96_2 = [0.41 0.86 0.32 0.1 9.6 12.4 22 8.1 22.4 23 47.5 34.9; 2.58 2.63 2.88 2.94 3.64 4.1 3.52 4.38 4 4.82 2.56 3.5; 4 4.38 4.5 4.5 11.8 12.8 12.2 13.2 12.4 14.8 10.2 12.2; -100 -100 -100 -100 -100 -100 -100 -100 -100 -100 -100 -100]/100 //The jacobian of the constraints // 1 2 3 4 5 6 7 8 9 10 11 12 jac = [ 1 -1 0 0 1 0 0 0 0 0 0 0 0 1 -1 0 0 0 -1 0 0 0 0 0 0 0 1 -1 0 -1 0 0 0 0 0 0 0 0 0 0 -1 1 0 1 0 0 0 0 0 0 0 0 0 0 0 -1 1 0 0 -1 0 0 0 0 0 0 1 0 -1 1 0 0 0 0 0 0 0 0 0 0 0 -1 -1 1 ]; // 1 2 3 4 5 6 7 8 9 10 11 12 // organizing the vector for the constraints residuals xmfull_rn96_2=[tstrao_flow_full_rn96_2(:);matrix(tstrao_comp_full_rn96_2',-1)]; xm=xmfull_rn96_2; //the variance proposed by the original author sd = (0.01*xmfull_rn96_2); //recalculating variance for i=1: length(sd) if sd(i) <= 0.0001 sd(i) = 0.0001; end end ncomp = 4; // to run with equaly weighted standard deviation, uncomment the line below //sd = ones(size(xmfull_rn96_2,1),size(xmfull_rn96_2,2)); var = sd.^2; //observability/redundancy tests [At_rn96_2,umeas_rn96_2, fixed_rn96_2] = jac_compound_residuals(jac,ncomp,tstrao_flow_full_rn96_2,tstrao_comp_full_rn96_2, tstrao_flow_rn96_2, tstrao_comp_rn96_2); [red_rn96_2, just_measured, observ_rn96_2, non_obs_rn96_2, spec_cand_rn96_2] = qrlinclass(At_rn96_2,umeas_rn96_2) // reconcile with all measured. To reconcile with only redundant variables, uncomment the "red" assignments measured_rn96_2 = setdiff([1:length(xmfull_rn96_2)], umeas_rn96_2); // to reconcile with all variables, comment the line above and uncomment bellow //measured_rn96_2 = [1:length(xmfull_rn96_2)]; red = measured_rn96_2; // to run robust reconciliation,, one must choose between the folowing objective functions to set up the functions path and function parameters: //WLS = 0 // Absolute sum of squares = 1 //Cauchy = 2 //Contamined Normal = 3 //Fair = 4 //Hampel = 5 //Logistic = 6 //Lorenztian = 7 //Quasi Weighted = 8 // run the configuration functions with the desired objective function type obj_function_type = 0; exec ../functions/setup_DR.sce; // to run robust reconciliation, it is also necessary to choose the function to return the problem structure // ipopt needs some information about the problem, such as jacobian and hessian structure, [nc, nv, nnzjac, nnz_hess, sparse_dg, sparse_dh, lower, upper, var_lin_type, constr_lin_type, constr_lhs, constr_rhs] = structure_compound(jac,ncomp, tstrao_flow_full_rn96_2,tstrao_comp_full_rn96_2); pause params = init_param(); // We use the given Hessian params = add_param(params,"hessian_approximation","exact"); // notice that the option bellow must only be set when the Hessians are constant, // eg: weighted least squares objective function and linear or bilinear Jacobian //params = add_param(params,"hessian_constant","yes"); //params = add_param(params,"derivative_test","first-order"); //params = add_param(params,"derivative_test","second-order"); //params = add_param(params,"derivative_test_print_all","yes"); params = add_param(params,"tol",1e-4); params = add_param(params,"acceptable_tol",1e-4); params = add_param(params,"mu_strategy","monotone"); params = add_param(params,"journal_level",5); params = add_param(params,"fixed_variable_treatment", "relax_bounds"); disp('begore start ipopt') //according to the original paper, we fix the measured total flow if length(fixed_rn96_2) > 0 then lower(fixed_rn96_2) = xmfull_rn96_2(fixed_rn96_2); upper(fixed_rn96_2) = xmfull_rn96_2(fixed_rn96_2); end tic //xrd=rand(size(xmfull,1),size(xmfull,2)); //[x_sol, f_sol, extra] = ipopt(xrd, objfun, gradf, confun, dg1, sparse_dg, dh, sparse_dh, var_lin_type, constr_lin_type, constr_rhs, constr_lhs, lower, upper, params); [x_sol, f_sol, extra] = ipopt(xmfull_rn96_2, objfun, gradf, confun, dg1, sparse_dg, dh, sparse_dh, var_lin_type, constr_lin_type, constr_rhs, constr_lhs, lower, upper, params); toc mprintf("\n\nSolution: , x\n"); for i = 1 : nv mprintf("x[%d] = %e\n", i, x_sol(i)); end mprintf("\n\nObjective value at optimal point\n"); mprintf("f(x*) = %e\n", f_sol); //printing results [Aeqp, Astreams] =size(jac) xx=matrix(x_sol,Astreams,ncomp + 1) TotalFlowMeasured = xx(:,1)' compoundMeasured = 100*xx(:, 2:$)
e68a34f70cb6d71226c0f082bee7f84aa0148498
449d555969bfd7befe906877abab098c6e63a0e8
/1850/CH2/EX2.7/exa_2_7.sce
0dbcdd4d83edb27cbb812afa195923ed9395bca8
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
119
sce
exa_2_7.sce
// Exa 2.7 clc; clear; close; // Given data Ad= 10^5; CMRR= 10^5; Acm= Ad/CMRR; disp(Acm,"Common mode gain");
3606d3b28825444d189f615860f42b64d4b5fce5
449d555969bfd7befe906877abab098c6e63a0e8
/3809/CH8/EX8.5/EX8_5.sce
f843a3a1cb811d58b29e2a092fc478036fccea2b
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
517
sce
EX8_5.sce
//Chapter 8, Example 8.5 clc //Initialisation c=10*10**-6 //capacitance in farad r=10**3 //resistance in ohm pi=3.14 //pi //Calculation t=c*r //time constant wc=1/t //angular frequency f=wc/(2*pi) //cyclic frequency //Result printf("Time Constant, T = %.2f s\n",t) printf("Angular Cut-off Frequency, F = %d rad/s \n",wc) printf("Cyclic Cut-off Frequency, Fc = %.1f Hz\n",f)
dcbb12a91544516e26e94689e332a0a3675b219e
449d555969bfd7befe906877abab098c6e63a0e8
/3760/CH5/EX5.24/Ex5_24.sce
95035647e47d3eb16d8875aa24ead79803fe5763
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
1,136
sce
Ex5_24.sce
clc; xd=1.2; // d axis synchronous reactance xq=0.8; // q axis synchronous reactance ra=0.025; // armature resistance vt=1; // pu rated per phase voltage disp('case a'); disp('For lagging power factor') pf=0.8; // power factor ia=1*(pf-sqrt(1-pf^2)*%i); // armature current Ef1=vt+%i*(ia*xq)+ia*ra; // excitation EMF id=1*sind(atand(imag(Ef1),real(Ef1))+acosd(pf)); // d component of armature current iq=1*cosd(atand(imag(Ef1),real(Ef1))+acosd(pf)); // q component of armature current Ef=abs(Ef1)+id*(xd-xq); // excitation EMF printf('Excitation EMF is %f p.u. at a load angle of %f degrees\n',abs(Ef),atand(imag(Ef1),real(Ef1))); disp('case b'); disp('For leading power factor') pf=0.8; // power factor ia=1*(pf+sqrt(1-pf^2)*%i); // armature current Ef1=vt+%i*(ia*xq)+ia*ra; // excitation EMF id=1*sind(atand(imag(Ef1),real(Ef1))-acosd(pf)); // d component of armature current iq=1*cosd(atand(imag(Ef1),real(Ef1))-acosd(pf)); // q component of armature current Ef=abs(Ef1)+id*(xd-xq); // excitation EMF printf('Excitation EMF is %f p.u.at a load angle of %f degrees\n',abs(Ef),atand(imag(Ef1),real(Ef1)));
06cf7d5bc80d7eb73518a1928bf296df503ee51c
c61d570c37971fa455028a89d2163f455f91c291
/interpolador_lagrange.sci
344faaefd6e0f961f39d8c0e5f974f64d20e8f44
[]
no_license
OgliariNatan/-ScientificComputing
a0af891f900f3f146a9751fd169f96052bd4ba83
070ea9d70430ef0c9e7944f491426b73af7c12b0
refs/heads/master
2020-04-04T23:13:12.585946
2017-07-03T21:46:18
2017-07-03T21:46:18
81,988,821
1
0
null
null
null
null
UTF-8
Scilab
false
false
1,415
sci
interpolador_lagrange.sci
// // Autor: Jonas Vieira de Souza // // TODO: Interpolador de Lagrange // Exemplo de chamada: // $$ exec( caminho + 'interpolador_lagrange.sci', -1 ); // $$ x [1 2 5 7 9 21]; // $$ y [4 5 6 7 9 20]; // $$ pa = 15; // $$ [ vi ] = interpolador_lagrange( x, y, pa ); // // Retornos: // $$ vi $$ variavel independente do interpolado // // Argumentos: // $$ _x $$ vetor de valores da Variavel Dependente // $$ _y $$ vetor de valores da Variavel Independente // $$ _pa $$ ponto de avalição do Polinônio Interpolador // function vi = interpolador_lagrange( _x, _y, _pa ) //Sendo o tamanho dos vectores correspondentes a ordem+1 de lagranje [ mx, nx ] = size(_x); [ my, ny ] = size(_y); if nx ~= ny then disp("Dados incompatíveis - Tamanho dos dados desiguais"); error("x e y devem ter a mesma dimensão"); end // Termos do Polinomio interpolador de Lagrange for i = 1:nx L(i) = 1; for j = 1:nx if j ~= i then L(i) = L(i)*((_pa-_x(j))/(_x(i)-_x(j))) end end printf("L(%d) = %.4f\n",i,L(i)); // Olhar Slide 13 (pg 35) - Esta Devolvendo o Polinomio. end //Avaliando o ponto no polinomio interpolador de Lagrange vi = 0; for i = 1:nx printf("L(%d)*y(%d) = %.4f\n",i,i,(L(i)*_y(i))); vi = vi + (L(i)*_y(i)) end endfunction
57a43f292b40e9670fdb281b7b7201c7a558309d
449d555969bfd7befe906877abab098c6e63a0e8
/1595/CH1/EX1.13/ex1_13.sce
fc528bd4de9eda8651721a5fad109360f18a75d1
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
509
sce
ex1_13.sce
//Introductory Topics :example 1-13 : (pg no. 40 & 41) a=460*10^3; b=450*10^3; BW=a-b; fr=455*10^3; Q=(fr/BW); C=0.001*10^-6; x=(fr*2*%pi); y=(1/x)^2; z=y/C; R=(2*%pi*z*BW); //part(a) : bandwidth printf("\nBW = fhc-flc = %.f Hz",BW); //part(b) : Quality factor //filter's peak o/p occurs at 455kHz printf("\nQ = fr/BW = %.1f kHz",Q); //part(c) : value of inductance printf("\nfr = 1/2.pi.sqrt(LC) = %.5f H",z); //part(d): total circuit resistance printf("\nBW = R/2.pi.L \nR = %.2f Ohm",R);
64837e8735e9304468377a5382e9f2dc6cab94b4
449d555969bfd7befe906877abab098c6e63a0e8
/3161/CH13/EX13.4/Ex13_4.sce
e04563c2c5d4aa5770b1be96cf0dec100837afc2
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
895
sce
Ex13_4.sce
clc; //page 649 //problem 13.4 //Given bandwidth(B) = 4000Hertz & Noise PSD(n/2) = 10^-9 Watt/Hertz B = 4000 n = 2*10^-9 //Chanel capacity(C) = B*log2 (1+S/(n*B)) //case 1 //Signal energy(S) = 0.1Joule S = 0.1 C = B*log2 (1+S/(n*B)) disp('Channel capacity for bandwidth = 4000Hertz, Noise PSD = 10^-9 Watt/Hertz & Signal energy(S) = 0.1Joule is '+string(C)+' bits/sec') //case 2 //Signal energy(S) = 0.001Joule S = 0.001 C = B*log2 (1+S/(n*B)) disp('Channel capacity for bandwidth = 4000Hertz, Noise PSD = 10^-9 Watt/Hertz & Signal energy(S) = 0.001Joule is '+string(C)+' bits/sec') //case 3 //Signal energy(S) = 0.001Joule & incresed bandwidth(B) = 10000Hertz B = 10000 S = 0.001 C = B*log2 (1+S/(n*B)) disp('Channel capacity for bandwidth = 10000Hertz, Noise PSD = 10^-9 Watt/Hertz & Signal energy(S) = 0.001Joule is '+string(C)+' bits/sec')
bc865466433b294aba4ae9ecfc2fad0ecd8f3de7
449d555969bfd7befe906877abab098c6e63a0e8
/2741/CH10/EX10.60/ExampleA60.sce
1040a4cab4af35110df1f6d18ab4ee8e9d459f96
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
1,103
sce
ExampleA60.sce
clc clear //Page number 500 //Input data m=12.5*10^-3;//The amount of ice in kg li=80;//Latent heat of ice in cal/gram l=536;//Latent heat of steam in cal/gram si=0.5;//Specific heat of ice in cal/gram-K sw=1;//Specific heat of water in cal/gram-K T1=-24+273;//The initial temperature of ice in K T2=0+273;//The final temperature of ice in K T3=100+273;//The final temperature of water in K //Calculations Li=li*10^3*4.2;//The latent heat of ice in J/kg Ls=l*10^3*4.2;//The latent heat of water in J/kg Si=si*10^3*4.2;//The specific heat of ice in J/kg-K Sw=sw*10^3*4.2;//The specific heat of water in J/kg-K s1=m*Si*log(T2/T1);//The increase in entropy of ice from 249 K to 273 K in J/K s2=(m*Li)/T2;//The increase in entropy from 273 K ice to 273 K water in J/K s3=m*Sw*log(T3/T2);//The increase in entropy of water from 273 K to 373 K in J/K s4=(m*Ls)/T3;//The increase in entropy from water at 373 K to steam at 373 K in J/K S=s1+s2+s3+s4;//The total increase in entropy in J/K //Output printf('The total increase in entropy is %3.2f J/K ',S)
1afbed11a934fdcf89f22bc1dd344f5d5a78578d
449d555969bfd7befe906877abab098c6e63a0e8
/3020/CH13/EX13.6/ex13_6.sce
1a8deb51075a20b5d2381c9e6d2609088520d51c
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
301
sce
ex13_6.sce
clc; clear all; a = 2.814e-10; // Lattice constant in meters h = 1; //Miller indices of diffracted plane k = 0; //Miller indices of diffracted plane l = 0;// Miller indices of diffracted plane d = a/sqrt(h^2+k^2+l^2);// Lattice constant disp('m',d,'The lattice spacing for plane (1,1,0) is')
3e299429b4cfb53a2d91dfdea4e6dfbe844da4e3
449d555969bfd7befe906877abab098c6e63a0e8
/226/CH11/EX11.6/example6_sce.sce
195c758c78aaa0457632d86a8f09f44514bdcb2d
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
375
sce
example6_sce.sce
//chapter 11 //example 11.6 //page 459 printf("\n") printf("given") Yfs=6000*10^-6;R1=100*10^3;R2=47*10^3;vs=50*10^-3;Rd=2.7*10^3;Rl=33*10^3;vs=50*10^-3;rs=600;Rs=Rd; disp(" CS circuit") Av=-Yfs*((Rd*Rl)/(Rd+Rl)) Zi=(R1*R2)/(R1+R2) vi=(vs*Zi)/(rs+Zi) vo=Av*vi disp("CG circuit") Av=Yfs*((Rd*Rl)/(Rd+Rl)) Zi=((1/Yfs)*Rs)/((1/Yfs)+Rs) vi=(vs*Zi)/(rs+Zi) vo=Av*vi
c2ebeaf5972f59cd8057e93b9f9980dc50b14b0f
f23e565144f1b0f63c7b613c0f549944d425a073
/Cours/TP_INFO/TP_note/td4 Scilab, noté_ PENAUD-ROUHAUD Td machine.sce
7a7f6e79d2f2ced251cb0f646165ea4c4a69fbe2
[]
no_license
Antoine-Gerard/Valar-Morghulis
c45766f03898241bd9c424256744b5ffa16dd82c
796363bfbc6f2e3249c90f1762e041ff5a4e705a
refs/heads/master
2021-08-31T06:06:55.296982
2017-12-20T13:54:33
2017-12-20T13:54:33
null
0
0
null
null
null
null
UTF-8
Scilab
false
false
1,025
sce
td4 Scilab, noté_ PENAUD-ROUHAUD Td machine.sce
//ROUHAUD Maïlys //PENAUD Chloé //vo= zeros (1,50) //v1= 10*ones (1, 50) //v2= z= 0:0.3:9.9 //v5= linspace (-3, 7, 50) function r = truc(x) r = (1 + x) .* sin(%pi .* x); endfunction x = linspace(-2, 2, 100); y = truc(x); plot2d(x,y,style=[color("pink")]); function r=P1(x) r=%pi.*x endfunction y1 = P1(x) function r=P2(x) r= %pi.*x+%pi.*x.^2 endfunction y2 = P2(x) plot2d(x,y2,style=[color("green")]); plot2d(x,y1,style=[color("blue")]); function f = G(t,y) f=y./t+t.*log(t) endfunction x1 = linspace(1, 4, 100); yn = ode("rk", 1, 1, x1, G) fenetre = figure("Figure_name", "Equations", "position", [100 50 1000 600]); fenetre.background = color("white"); set("current_figure", fenetre); plot2d(x1,yn,style=[color("purple")]) function f = G(t,y) f=y./t+t.*log(t) endfunction x1 = linspace(1, 4, 100); yn = ode("rk", -2, 1, x1, G) plot2d(x1,yn,style=[color("red")]) function f = G(t,y) f=y./t+t.*log(t) endfunction x1 = linspace(1, 4, 100); yn = ode("rk", 2, 1, x1, G) plot2d(x1,yn,style=[color("black")])
c873e6d5bf6fbe98c0edeb929193d1107064ebdb
717ddeb7e700373742c617a95e25a2376565112c
/10/CH4/EX6/cha4_6.sce
e5766b3ed366e20d3380583bd3f7f22a11e13e72
[]
no_license
appucrossroads/Scilab-TBC-Uploads
b7ce9a8665d6253926fa8cc0989cda3c0db8e63d
1d1c6f68fe7afb15ea12fd38492ec171491f8ce7
refs/heads/master
2021-01-22T04:15:15.512674
2017-09-19T11:51:56
2017-09-19T11:51:56
92,444,732
0
0
null
2017-05-25T21:09:20
2017-05-25T21:09:19
null
UTF-8
Scilab
false
false
595
sce
cha4_6.sce
Vt=100;Ra=0.1;Ia=6;If=0.99;Rfw=80; Ia1=5;Iarated=120;N=1000; Afl=0.95;Prot=497.5; Eanl=Vt-(Ia*Ra) Rf=Vt/If Rfc=Rf-Rfw Prot=Ea*5 Eanl=Vt-(Ia*Ra) Eafl=Vt-(Iarated*Ra) Wfl=(Eafl/Eanl)*N Wm=(Wfl/60)*2*%pi T=(Eafl*Iarated)/Wm Pout=(Eafl*Iarated)-(Prot) Pin=(Vt)*(Iarated+If) Eff=(Pout/Pin)*100 Wfl1=(Eafl/Eanl)*(1/Afl)*N Wm1=(Wfl1/60)*(2*%pi) T=(Eafl*Iarated)/(Wm1) Eff1=(Pout/Pin)*100 Wm=(1000/60)*(2*%pi) Ka=Eanl/Wm Ia=1.5*120 Tstart=(Ka*Ia) Ifeff=If-Ifar Ea1=93.5 Ka1=(Ea1/Wm) Tstart1=(Ka1*Ia)
b74e2fe9c343d3b7b808dd7973f04371e176a87d
4f74d8f3b6bf638df3eb088f3ebdf9570faf73d9
/convolution.sce
14f708cf9a196d02471680c00d9f7cd77e78c249
[]
no_license
rohitshetty/scilab-hello
f25b491e2cbf466cb6c96a654a1d82b235f66bf1
c505331617a2cdfd1e1509f08c204cc8062491b7
refs/heads/master
2021-01-02T08:39:29.247367
2015-05-05T13:45:43
2015-05-05T13:45:43
34,436,890
0
0
null
null
null
null
UTF-8
Scilab
false
false
449
sce
convolution.sce
//covolute two discrete signals h = [2,4,5,21,45] //signal h(n) x = [1,2,3,4.5,6] //signal x(n) subplot(221) //should be given before plot function, breaks window to mxn pane look into documentation plot2d3(x) //plots discrete values title('x[n]') subplot(222) plot2d3(h) title('h[n]') y = convol(x,h) //convolutes discrete as well as continous signals. look into documentations subplot(223) plot2d3(y) title('y[n]=x[n]*h[n]')
0b3a3f2fb942f84cdd33487adbf64106e652ac7d
449d555969bfd7befe906877abab098c6e63a0e8
/2168/CH14/EX14.2/Chapter14_example2.sce
142250986145aee9afd71a17f4097ae8a2bcef6c
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
632
sce
Chapter14_example2.sce
clc clear //Input data r=14//Compression ratio p=1.2//Induction pipe pressure in kg/cm^2 bp=0.65//Exhaust back pressure in kg/cm^2 Tc=87+273//Charge temperature in K Te=850+273//Exhaust temperature in K T1=111+273//Temperature at the beginning of compression in K g=1.2//Ratio of specific heats //Calculations Cw1=((bp*10^4)/Te)//specific heat in kJ/kg.K Cw2=((p*10^4*(r-1))/Tc)//specific heat in kJ/kg.K T3=((g*Te*Cw1+Cw2*Tc)/(Cw1*g+Cw2))//Temperature in K t3=T3-273//Temperature in degree C rw=(Cw1/Cw2)//Ratio of specific heats //Output printf('The ratio of the mass residuals to fresh charge is %3.4f',rw)
19a94bf335c7b527284d6586f1c36be43db267e4
449d555969bfd7befe906877abab098c6e63a0e8
/3648/CH10/EX10.8/Ex10_8.sce
928c3448fc14c7b79a92d57cf35125c3656ebc6e
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
510
sce
Ex10_8.sce
//Example 10_8 clc(); clear; //To find the final volume of gas t1=27 //Units in Centigrade t1=t1+273 //Units in Kelvin t2=547 //Units in Centigrade t2=t2+273 //Units in Kelvin t1=27 //Units in Centigrade t1=t1+273 //Units in Kelvin t1=27 //Units in Centigrade t1=t1+273 //Units in Kelvin p2=3700 //units in cm Hg p1=74 //units in cm Hg v1_v2=1/((t1/t2)*(p2/p1)) //In terms of V1 printf("The final volume of gas in terms of original volume is V2=%.5f*V1",v1_v2)
40044286ca720af1c7294e570a720352051b7a3a
449d555969bfd7befe906877abab098c6e63a0e8
/2870/CH1/EX1.7/Ex1_7.sce
148b47847d4eec61b379eb8d87ca436443db1d2d
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
434
sce
Ex1_7.sce
clc;clear; //Example 1.7 //constants used g=9.81;//acceleration due to gravity in m/s^2; //given values h1=0.1; h2=0.2; h3=0.35;//respective heights in m pw=1000; pHg=13600; poil=800;//density of water, mercury and oil in kg/m^3 Patm=85.6; //calculation P1=Patm-(pw*g*h1+poil*g*h2-pHg*g*h3)/1000;//calculating pressure using liquid at same height have same pressure disp(P1,'the air pressure in tank in kPa is ')
e700f4b8665163089627d5f3e856ae38b231c4ba
676ffceabdfe022b6381807def2ea401302430ac
/solvers/ShallowWaterSolver/Tests/LinearSWE_StandingWave_WallBC_CG_P4.tst
a28f29afb60804b050a3a1657dd9c44825b1ba7a
[ "MIT" ]
permissive
mathLab/ITHACA-SEM
3adf7a49567040398d758f4ee258276fee80065e
065a269e3f18f2fc9d9f4abd9d47abba14d0933b
refs/heads/master
2022-07-06T23:42:51.869689
2022-06-21T13:27:18
2022-06-21T13:27:18
136,485,665
10
5
MIT
2019-05-15T08:31:40
2018-06-07T14:01:54
Makefile
UTF-8
Scilab
false
false
899
tst
LinearSWE_StandingWave_WallBC_CG_P4.tst
<?xml version="1.0" encoding="utf-8"?> <test> <description>Standing Wave, CG, P=4</description> <executable>ShallowWaterSolver</executable> <parameters>LinearSWE_StandingWave_WallBC_CG_P4.xml</parameters> <files> <file description="Session File">LinearSWE_StandingWave_WallBC_CG_P4.xml</file> </files> <metrics> <metric type="L2" id="1"> <value variable="eta" tolerance="1e-12">4.34843e-05</value> <value variable="u" tolerance="1e-12">2.56707e-05</value> <value variable="v" tolerance="1e-12">2.56707e-05</value> </metric> <metric type="Linf" id="2"> <value variable="eta" tolerance="1e-12">0.000207527</value> <value variable="u" tolerance="1e-12">9.25444e-05</value> <value variable="v" tolerance="1e-12">9.25444e-05</value> </metric> </metrics> </test>
21d65f82dab05d542a1b5e92a26432289860db1f
99b4e2e61348ee847a78faf6eee6d345fde36028
/Toolbox Test/bartlett/bartlett7.sce
bdf649351f87703044a4fd34afe3ab6cb5f43337
[]
no_license
deecube/fosseetesting
ce66f691121021fa2f3474497397cded9d57658c
e353f1c03b0c0ef43abf44873e5e477b6adb6c7e
refs/heads/master
2021-01-20T11:34:43.535019
2016-09-27T05:12:48
2016-09-27T05:12:48
59,456,386
0
0
null
null
null
null
UTF-8
Scilab
false
false
169
sce
bartlett7.sce
//no i/p w=bartlett(); disp(w); //output // !--error 10000 //Incorrect number of input arguments. //at line 24 of function bartlett called by : //w=bartlett();
1a20e3313bfb41b4923b5fcaaab0bcda2776e9a1
449d555969bfd7befe906877abab098c6e63a0e8
/2513/CH5/EX5.4/5_4.sce
f3dfe940e61d7a5dd58c8baa7b7ce2a1ff8a924b
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
461
sce
5_4.sce
clc //initialisation of variables p=100000//in d=150//in h=1000000//in a1=2.0//draft a2=3.0//draft a3=1.6//draft m=1.5//in q=2.5//in v=1020//in w=100//in t=0.01//in v1=13.2//mgd //CALCULATIONS A=d*p/h//mgd M=m*A//mgd M1=q*A//mgd V=v*sqrt(w)*(1-t*sqrt(w))//gpm D=M+v1//mgd L=a1*A//mgd L1=(4/3)*M//max H=a2*A//mgd H1=(4/3)*M1//max F=a3*A//mgd F1=(4/3)*M//max //RESULTS printf('the resulting capacities of the four system =% f max',F1)
e781ed26b3b8bd4261b0b1dc1d08d3ad1c42451e
717ddeb7e700373742c617a95e25a2376565112c
/3044/CH2/EX2.11/Ex2_11.sce
de6335908b31fc023381fd6a179d1cb0aa0fef4e
[]
no_license
appucrossroads/Scilab-TBC-Uploads
b7ce9a8665d6253926fa8cc0989cda3c0db8e63d
1d1c6f68fe7afb15ea12fd38492ec171491f8ce7
refs/heads/master
2021-01-22T04:15:15.512674
2017-09-19T11:51:56
2017-09-19T11:51:56
92,444,732
0
0
null
2017-05-25T21:09:20
2017-05-25T21:09:19
null
UTF-8
Scilab
false
false
982
sce
Ex2_11.sce
//Variable declaration l = [221, 234, 245, 253, 265, 266, 271, 272, 274, 276,276, 276, 278, 284, 289, 290, 290, 292, 292, 296,297, 298, 300, 303, 304, 305, 305, 308, 308, 309,310, 311, 312, 314, 315, 315, 323, 330, 333, 336,337, 338, 343, 346, 355, 364, 366, 373, 390, 391] //Calculation np = length(l)*0.25 // np-losition in list l(),for first quartile p=1/4 Q1 = l(13) // as np=12.5,so we round up to 13th np = length(l)*0.5 //for second quartile p=1/2 np = int(np) Q2 = (l(np) + l(np+1))*0.5 // Average of 25th and 26th np = length(l)*0.75 //for third quartile p=3/4 Q3 = l(38) // round up to 38th np = length(l)*0.93 //for 93rd percentile p=0.93 Q93 = l(47) // round up to 47th //Results printf ( "First quartile Q1 : %d nm ",Q1) printf ( "Second quartile Q2 : %.1f nm ",Q2) printf ( "Third quartile Q3 : %d nm ",Q3) printf ( "93rd quartile Q93 : %d nm ",Q93)
5549bcf3c872e4ec49a4904365ade90ff1abfe35
449d555969bfd7befe906877abab098c6e63a0e8
/2885/CH6/EX6.2/ex6_2.sce
adfbbaf444f11c8394797aa0282d110c9aa3777f
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
650
sce
ex6_2.sce
//Determine the Q point clear; clc; //soltion //given B=150; //dc beta Rc=1*10^3;//ohm //resistor connected to collector Rb=100*10^3;//ohm //resistor connected to base Vcc=10;//V //Voltage supply across the collector resistor Vbe=0.7;//V //base to emitter voltage Ib=(Vcc-Vbe)/Rb; //Base current Ic=B*Ib; //Colletor current Ics=Vcc/Rc; //Colletor saturation current //Actual Ic is the smaller of the above two values i.e. Ic(sat) and since the transistor is in saturation mode therefore Vce will become 0 Vce=0; printf("The Q point is (%d V, %.0f mA)",Vce,Ics*1000);
384665dc373344cbdc1f7d1c45b9a99180dfa0bc
449d555969bfd7befe906877abab098c6e63a0e8
/3137/CH19/EX19.20/Ex19_20.sce
2e64bf021cc0ff58b0296b84b2fca02a9a7c64fd
[]
no_license
FOSSEE/Scilab-TBC-Uploads
948e5d1126d46bdd2f89a44c54ba62b0f0a1f5e1
7bc77cb1ed33745c720952c92b3b2747c5cbf2df
refs/heads/master
2020-04-09T02:43:26.499817
2018-02-03T05:31:52
2018-02-03T05:31:52
37,975,407
3
12
null
null
null
null
UTF-8
Scilab
false
false
171
sce
Ex19_20.sce
//Initilization of variables wn=25.4 //rad/s t=0.261 //s d=0.316 //Calculations del=d*t*wn //logarithmic decay //Result clc printf('The rate of decay is %f',del)