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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
890e8de93189cc5b38f8cd34b957012c28e69726 | 449d555969bfd7befe906877abab098c6e63a0e8 | /1938/CH5/EX5.28/5_28.sce | 066180d53d8d1755c06dfbf756e782f440ca9ba8 | [] | 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 | 937 | sce | 5_28.sce | clc,clear
printf('Example 5.28\n\n')
V_L=2000,V_ph=V_L/sqrt(3)
VA=1000*10^3
I_L=VA/(sqrt(3)*V_L) //because VA=sqrt(3)*V_L*I_L
I_aph=I_L
I_f=28.5//for this I_aph=288.67513 as obtained from SCC graph
V_oc_ph=1060//for I_f=28.5 as obtained fromOCC graph
Z_s=V_oc_ph/I_aph
R_a=0.2 //armature effective resistance
X_s=sqrt( Z_s^2-R_a^2 )
//Part(i)
phi1=acos(0.8)//lagging
E_ph1=sqrt((V_ph*cos(phi1)+I_aph*R_a)^2+(V_ph*sin(phi1)+I_aph*X_s)^2)
regulation1=100*(E_ph1-V_ph)/V_ph
printf("(i)Full-load percentage regulation at 0.8 pf lagging is %.2f percent",regulation1)
//Part(ii)
phi2=acos(0.8)//leading
E_ph2=sqrt((V_ph*cos(phi2)+I_aph*R_a)^2+(V_ph*sin(phi2)-I_aph*X_s)^2)
regulation2=100*(E_ph2-V_ph)/V_ph
printf("\n(ii)Full-load percentage regulation at 0.8 pf leading is %.2f percent\n\n",regulation2)
printf('Note that the answer mismatches because of calculation mistake done in the last step of part 1')
|
72eedb696cb86b8aad15f9d457db79047555d783 | b4980b761e4b88d097e526fe06ebef2383d3d613 | /lab02/TwoBit4To1LinePriorityMUX/TwoBit4To1LinePriorityMUX.tst | ed2c4d8c2287a44e140f25fc411c3f0931c4cf07 | [] | no_license | Vineeth-Kada/Computer-Systems-Design | aa42b053c709fdbf06713dc3e1e2649faa02c65d | 4c05e393e057ffb1540c74a53a0cb17f7129d8f8 | refs/heads/main | 2023-06-17T06:27:02.442583 | 2021-07-15T10:43:37 | 2021-07-15T10:43:37 | 289,896,111 | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 3,364 | tst | TwoBit4To1LinePriorityMUX.tst | load TwoBit4To1LinePriorityMUX.hdl,
output-file TwoBit4To1LinePriorityMUX.out,
compare-to TwoBit4To1LinePriorityMUX.cmp,
output-list R0%B2.1.2 R1%B2.1.2 R2%B2.1.2 R3%B2.1.2 X01%B2.1.2 X00%B2.1.2 X11%B2.1.2 X10%B2.1.2 X21%B2.1.2 X20%B2.1.2 X31%B2.1.2 X30%B2.1.2 Y1%B2.1.2 Y0%B2.1.2;
/*Only one request input to the priority encoder is active*/
set R0 1, set R1 0, set R2 0, set R3 0, set X01 1, set X00 0, set X11 0, set X10 1, set X21 0, set X20 0, set X31 1, set X30 1,
eval, output;
set R0 1, set R1 0, set R2 0, set R3 0, set X01 0, set X00 1, set X11 0, set X10 0, set X21 1, set X20 1, set X31 1, set X30 0,
eval, output;
set R0 1, set R1 0, set R2 0, set R3 0, set X01 1, set X00 1, set X11 1, set X10 0, set X21 0, set X20 1, set X31 0, set X30 0,
eval, output;
set R0 1, set R1 0, set R2 0, set R3 0, set X01 0, set X00 0, set X11 1, set X10 1, set X21 1, set X20 0, set X31 0, set X30 1,
eval, output;
set R0 0, set R1 1, set R2 0, set R3 0, set X01 1, set X00 0, set X11 0, set X10 1, set X21 0, set X20 0, set X31 1, set X30 1,
eval, output;
set R0 0, set R1 1, set R2 0, set R3 0, set X01 0, set X00 1, set X11 0, set X10 0, set X21 1, set X20 1, set X31 1, set X30 0,
eval, output;
set R0 0, set R1 1, set R2 0, set R3 0, set X01 1, set X00 1, set X11 1, set X10 0, set X21 0, set X20 1, set X31 0, set X30 0,
eval, output;
set R0 0, set R1 1, set R2 0, set R3 0, set X01 0, set X00 0, set X11 1, set X10 1, set X21 1, set X20 0, set X31 0, set X30 1,
eval, output;
set R0 0, set R1 0, set R2 1, set R3 0, set X01 1, set X00 0, set X11 0, set X10 1, set X21 0, set X20 0, set X31 1, set X30 1,
eval, output;
set R0 0, set R1 0, set R2 1, set R3 0, set X01 0, set X00 1, set X11 0, set X10 0, set X21 1, set X20 1, set X31 1, set X30 0,
eval, output;
set R0 0, set R1 0, set R2 1, set R3 0, set X01 1, set X00 1, set X11 1, set X10 0, set X21 0, set X20 1, set X31 0, set X30 0,
eval, output;
set R0 0, set R1 0, set R2 1, set R3 0, set X01 0, set X00 0, set X11 1, set X10 1, set X21 1, set X20 0, set X31 0, set X30 1,
eval, output;
set R0 0, set R1 0, set R2 0, set R3 1, set X01 1, set X00 0, set X11 0, set X10 1, set X21 0, set X20 0, set X31 1, set X30 1,
eval, output;
set R0 0, set R1 0, set R2 0, set R3 1, set X01 0, set X00 1, set X11 0, set X10 0, set X21 1, set X20 1, set X31 1, set X30 0,
eval, output;
set R0 0, set R1 0, set R2 0, set R3 1, set X01 1, set X00 1, set X11 1, set X10 0, set X21 0, set X20 1, set X31 0, set X30 0,
eval, output;
set R0 0, set R1 0, set R2 0, set R3 1, set X01 0, set X00 0, set X11 1, set X10 1, set X21 1, set X20 0, set X31 0, set X30 1,
eval, output;
/*Atleast 2 request inputs to the priority encoder are active*/
set R0 1, set R1 0, set R2 0, set R3 1, set X01 0, set X00 0, set X11 1, set X10 0, set X21 0, set X20 0, set X31 1, set X30 1,
eval, output;
set R0 0, set R1 1, set R2 1, set R3 0, set X01 0, set X00 1, set X11 1, set X10 1, set X21 1, set X20 1, set X31 0, set X30 0,
eval, output;
set R0 0, set R1 0, set R2 1, set R3 1, set X01 1, set X00 0, set X11 0, set X10 0, set X21 1, set X20 0, set X31 1, set X30 0,
eval, output;
set R0 0, set R1 1, set R2 0, set R3 1, set X01 1, set X00 1, set X11 0, set X10 1, set X21 0, set X20 1, set X31 0, set X30 1,
eval, output;
|
20db5f7b920bd5bfcbbdbed6a5582b18e0a71a1f | 449d555969bfd7befe906877abab098c6e63a0e8 | /1184/CH2/EX2.12/Ex2_12.sce | 0929d3ea9ec330843546fc8f46cc3e3392c07da5 | [] | 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 | 256 | sce | Ex2_12.sce | //Example 2-12, Page No - 40
clear
clc
gain1 = 6.8
gain2 = 14.3
attenuation1 = -16.4
attenuation2 = -2.9
vout = 800*10^-3
At = gain1+gain2+attenuation1+attenuation2
vin = vout/10^(At/20)
printf('The input voltage is %.1f mV',vin*10^3)
|
a4c22042153bdb37cc61bf4034066b85feae6caf | ac66d3377862c825111275d71485e42fdec9c1bd | /Resources/res/map/map1312.sce | 97f24fb711a4b971cdd36f837cb8834086a9c085 | [] | no_license | AIRIA/CreazyBomber | 2338d2ad46218180f822682d680ece3a8e0b46c3 | 68668fb95a9865ef1306e5b0d24fd959531eb7ad | refs/heads/master | 2021-01-10T19:58:49.272075 | 2014-07-15T09:55:00 | 2014-07-15T09:55:00 | 19,776,025 | 0 | 2 | null | null | null | null | UTF-8 | Scilab | false | false | 2,988 | sce | map1312.sce | <?xml version="1.0" encoding="UTF-8"?>
<Project Name="map1312" Width="13" Height="15" CellSize="40" BackgroundSize="1" Background="13plus.png">
<Cell Name="冰块" X="1" Y="1" />
<Cell Name="冰块" X="2" Y="1" />
<Cell Name="冰块" X="3" Y="1" />
<Cell Name="冰块" X="4" Y="1" />
<Cell Name="bc-雪球-下" X="6" Y="1" arg0="70" arg1="1.00" arg2="1,4" />
<Cell Name="冰块" X="8" Y="1" />
<Cell Name="冰块" X="9" Y="1" />
<Cell Name="冰块" X="10" Y="1" />
<Cell Name="冰块" X="11" Y="1" />
<Cell Name="通关点-1" X="6" Y="3" />
<Cell Name="雪树" X="2" Y="4" />
<Cell Name="冰雕" X="3" Y="4" />
<Cell Name="雪树" X="4" Y="4" />
<Cell Name="bc-冰面" X="5" Y="4" />
<Cell Name="bc-冰面" X="6" Y="4" />
<Cell Name="bc-冰面" X="7" Y="4" />
<Cell Name="雪树" X="8" Y="4" />
<Cell Name="冰雕" X="9" Y="4" />
<Cell Name="雪树" X="10" Y="4" />
<Cell Name="雪树" X="3" Y="5" />
<Cell Name="bc-冰面" X="4" Y="5" />
<Cell Name="bc-冰面" X="5" Y="5" />
<Cell Name="bc-冰面" X="6" Y="5" />
<Cell Name="bc-冰面" X="7" Y="5" />
<Cell Name="bc-冰面" X="8" Y="5" />
<Cell Name="雪树" X="9" Y="5" />
<Cell Name="bc-冰面" X="3" Y="6" />
<Cell Name="bc-冰面" X="4" Y="6" />
<Cell Name="bc-冰面" X="5" Y="6" />
<Cell Name="bc-冰面" X="7" Y="6" />
<Cell Name="bc-冰面" X="8" Y="6" />
<Cell Name="bc-冰面" X="9" Y="6" />
<Cell Name="bc-雪球-右" X="1" Y="7" arg0="70" arg1="2.00,1" arg2="3,4" />
<Cell Name="bc-冰面" X="3" Y="7" />
<Cell Name="bc-冰面" X="4" Y="7" />
<Cell Name="bc-冰面" X="5" Y="7" />
<Cell Name="章鱼(Boss)" X="6" Y="7" arg0="19" />
<Cell Name="bc-冰面" X="7" Y="7" />
<Cell Name="bc-冰面" X="8" Y="7" />
<Cell Name="bc-冰面" X="9" Y="7" />
<Cell Name="bc-雪球-左" X="11" Y="7" arg0="75" arg1="3.00,2" arg2="2,4" />
<Cell Name="bc-冰面" X="3" Y="8" />
<Cell Name="bc-冰面" X="4" Y="8" />
<Cell Name="bc-冰面" X="5" Y="8" />
<Cell Name="bc-冰面" X="6" Y="8" />
<Cell Name="bc-冰面" X="7" Y="8" />
<Cell Name="bc-冰面" X="8" Y="8" />
<Cell Name="bc-冰面" X="9" Y="8" />
<Cell Name="雪树" X="2" Y="9" />
<Cell Name="冰雕" X="3" Y="9" />
<Cell Name="雪树" X="4" Y="9" />
<Cell Name="bc-冰面" X="5" Y="9" />
<Cell Name="bc-冰面" X="6" Y="9" />
<Cell Name="bc-冰面" X="7" Y="9" />
<Cell Name="雪树" X="8" Y="9" />
<Cell Name="冰雕" X="9" Y="9" />
<Cell Name="雪树" X="10" Y="9" />
<Cell Name="雪树" X="3" Y="10" />
<Cell Name="bc-冰面" X="4" Y="10" />
<Cell Name="bc-冰面" X="5" Y="10" />
<Cell Name="bc-冰面" X="6" Y="10" />
<Cell Name="bc-冰面" X="7" Y="10" />
<Cell Name="bc-冰面" X="8" Y="10" />
<Cell Name="雪树" X="9" Y="10" />
<Cell Name="bc-雪球-右" X="1" Y="11" arg0="75" arg1="3.00,2" arg2="3,4" />
<Cell Name="bc-雪球-左" X="11" Y="11" arg0="80" arg1="2.00,1" arg2="2,4" />
<Cell Name="出生点" X="6" Y="12" />
</Project> |
48c496132d6ca6a5d8d033d69da742eb93252621 | 449d555969bfd7befe906877abab098c6e63a0e8 | /2175/CH7/EX7.21/7_21.sce | d42d159be2650ae54a0e04e16010a6e1ad9ecdd4 | [] | 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 | 239 | sce | 7_21.sce | clc;
m_EtOH=46;
aof=1/m_EtOH;
m_a=28.96;
AF=8.957;
aoa=AF/m_a;
Total=aof+aoa;
R=8314.5;
T=288;
p=1.013*10^5;
V=Total*R*T/p;
NCVf=27.8;
NCVm=NCVf/V;
disp("MJ/m^3",NCVm,"calorific value of the combustion mixture is:");
|
0f39800caee665caf735aa017c9336119e12b9f1 | 449d555969bfd7befe906877abab098c6e63a0e8 | /2459/CH20/EX20.7/Ex20_7.sce | e3caf439c3c828a9079ce8dfdc3775163415dfcf | [] | 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 | 198 | sce | Ex20_7.sce | //chapter20
//example20.7
//page442
Vz=10 // V
Vbe=0.5 // V
Rl=1000 // ohm
Vout=Vz-Vbe
Il=Vout/Rl
printf("load voltage = %.3f V \n",Vout)
printf("load current = %.3f mA \n",Il*1000)
|
a005e27432eea78bc9788dd9e367bd08f813ecbd | 6e257f133dd8984b578f3c9fd3f269eabc0750be | /ScilabFromTheoryToPractice/Programming/testtrycatch.sce | 1a6dd8aa7901f492d2acbe89a1ce0efb9560dcc8 | [] | 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 | 128 | sce | testtrycatch.sce | x=input('Compute 1/x for x=?');
try 1/x
catch disp('An error occurred!')
end
disp('The end of the script still gets executed.')
|
e523ecb38a208cf8a9f3230f282230cc0544233a | 449d555969bfd7befe906877abab098c6e63a0e8 | /1247/CH6/EX6.10/example6_10.sce | dac65c594f32534fe08e6d5bc930c050c3b43924 | [] | 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 | 775 | sce | example6_10.sce | clear;
clc;
// Stoichiometry
// Chapter 6
// Stoichiometry and Unit Operations
// Example 6.10
// Page 368
printf("Example 6.10, Page 368 \n \n");
// solution
// basis 100kg free water in original sol
// initial T = 353K
W1 = (126/120.3)*64.2 //kg
Wfree1 = 100-W1
MS1 = ((64.20+W1)*100)/32.76 // MgSO4.7H2O in 100kg free water
// 4% of original sol evaporates
E = (MS1 + 100)*.04
Wfree2 = 100-E // free water in mother liquor
// at 303.15 K
W2 = (126/120.3)*40.8
Wfree3 = 100-W2
MS2 = (W2+40.80)*Wfree2/Wfree3 // crystals of MgSO4.7H2O
y = MS1-MS2 //kg
q = 501.2*1000/284.6 // quantity of original sol to be fed
printf(" Quantity if original solution to be fed to the crystallizer per 1000kg crystals of MgSO4.7H2O = "+string(q)+"kg.")
|
d875ea2b201e6a23d205582a9b7d57f45e8e4ea1 | 2450f461793af2c597fff95b0ae07954ceafc8a8 | /Exp 5/FT task1.sce | eb8611768e868f6198054c44da7732a20aa6ad9c | [] | no_license | Kulkarni-Aditi/SS-Submission | 25d2062e13adf01e7da1d3911aa23f0829479909 | a06c6fd44e551c2b83545d743d14f985bf13e48a | refs/heads/main | 2023-01-22T05:43:10.189918 | 2020-11-24T10:23:56 | 2020-11-24T10:23:56 | 315,592,882 | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 234 | sce | FT task1.sce | clc;
t=-1:0.02:1;
w=2*%pi;
n_har=5;
n=1:1:n_har
b=2 ./(n*%pi)
x=0.5+b*sin(w*n'*t)
plot(x)
figure;
n_har=10;
n=1:1:n_har
b=2 ./(n*%pi)
x=0.5+b*sin(w*n'*t)
plot(x)
figure;
n_har=15;
n=1:1:n_har
b=2 ./(n*%pi)
x=0.5+b*sin(w*n'*t)
plot(x)
|
d1cf825e655ad6ca2cbfb863fdf94309a3383e79 | 449d555969bfd7befe906877abab098c6e63a0e8 | /2150/CH5/EX5.10/ex5_10.sce | c80bc3fc4e69e04fb34060afd66e7228d2a2250c | [] | 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 | 284 | sce | ex5_10.sce | // Exa 5.10
clc;
clear;
close;
// Given data
R_L = 10;// in kohm
R_L= R_L*10^3;// in ohm
R_C = 3.6;// in kohm
R_C= R_C*10^3;// in ohm
r_e_desh = 22.73;// in ohm
R_L_desh = R_L/2;// in ohm
A_v = ( (R_C*R_L_desh)/(R_C+R_L_desh))/r_e_desh;
disp(A_v,"The voltage gain is");
|
8298f8150ac5c578922bbf86982818734210309e | 449d555969bfd7befe906877abab098c6e63a0e8 | /3507/CH9/EX9.25/Ex9_25.sce | 07a5e64c62538211df9d6f93296622584735163e | [] | 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 | 274 | sce | Ex9_25.sce | //chapter9
//example9.25
//page173
Ei=45 // V
Vz1=15 // V
Vz2=15 // V
Iz=200d-3 // current rating for each zener in ampere
Eo=Vz1+Vz2
R=(Ei-Eo)/Iz
printf("regulated output voltage = %.3f V \n",Eo)
printf("required series resistance = %.3f ohm \n",R)
|
030d1b30e8b638e50f399de83653122f37499573 | 449d555969bfd7befe906877abab098c6e63a0e8 | /182/CH3/EX3.15/example3_15.sce | 115e377ded6158d99537b4fa5f6f1306e1ff29d3 | [] | 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 | 728 | sce | example3_15.sce |
//example3-15 in page 63
clc;
//Given data
R1=15e+3; // resistance R1=15 K-ohm
Rm=50;// coil resistance in ohm
R2=50;// resistance R2 in ohm
Im=50e-6;// FSD=50 micro-ampere
//calculations
printf("at Rx=0 & Eb=1.3 V,\n");
Rx=0; Eb=1.3;
Ib=Eb/(Rx+R1);
I2=Ib-Im;
Vm=Im*Rm;
R21=Vm/I2;// the resistance R2 in ohm
printf("R2=%.2f ohm\n",R21);
for Eb=1.5:-0.2:1.3,// To find Rx
Vm=0.5*Im*Rm;
if Eb==1.3
R2=R21;
end
I2=Vm/R2;
Ib=I2+Im*0.5;
Rx=(Eb/Ib)-R1;
printf("At 0.5 FSD with Eb=%.1f V,\n",Eb);
printf("Rx=%d K-ohm \n",Rx/1000);
end
//result
//at Rx=0 & Eb=1.3 V
//R2=68.181818 ohm
//At 0.5 FSD with Eb=1.5V,
//Rx=15 K-ohm
//At 0.5 FSD with Eb=1.3 V,
//Rx=15 K-ohm |
140f2f79dc51a55e232c27c4520297bbbd1110ef | f81f2aca21a9a22746300d097acd62205d34fb61 | /instantInsolation.sce | 2bd8668e641bd7b9695ddd74e1d3a6851a046213 | [] | no_license | br3688/SunPosition | e695d9f69e6ab8a6b1394ffe0e8c24b42f849d17 | 5169ba7e5374f617487c95c34e0c2410b08d2573 | refs/heads/master | 2020-07-01T04:57:25.732520 | 2016-11-22T18:51:29 | 2016-11-22T18:51:29 | 74,095,307 | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 989 | sce | instantInsolation.sce | clc
clear
latitudeDirection = "N";
degreesLat = 29;
minutesLat = 39;
secondsLat = 7.19;
longitudeDirection = "W";
degreesLong = 82;
minutesLong = 19;
secondsLong = 29.97;
standardMeridian = 75;
month = 2;
day = 1;
localTime = 12; // enter in integers (hourly)
panelTiltAngle = 30;
panelAzimuthAngle = 10;
groundReflectance = 0.2;
exec('convertGlobal.sce');
exec('convertLst.sce');
exec('calcSunCoordinates.sce');
exec('NumberDays.sce');
exec('calcInsolation.sce');
daysPassed = numberDays(month,day);
[latitude, longitude] = convertGlobal(degreesLat, minutesLat, secondsLat, latitudeDirection, degreesLong, minutesLong, secondsLong, longitudeDirection);
solarHourAngle = convertLst(localTime, longitude, standardMeridian,daysPassed)
[solarAltitudeAngle,solarAzimuthAngle] = calcSunCoordinates(latitude, daysPassed,solarHourAngle);
[insolationTotal] = calcInsolation(solarAltitudeAngle,solarAzimuthAngle, panelTiltAngle, panelAzimuthAngle, groundReflectance, month, daysPassed);
|
c94e81e5fea5ef9d083ffa39baf27d3e9ecc654b | 449d555969bfd7befe906877abab098c6e63a0e8 | /3705/CH11/EX11.3/Ex11_3.sce | 08382169c54639a4db7073f562465d781ae9349b | [] | 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 | 825 | sce | Ex11_3.sce |
clear//
//
//Variable Declaration
M=32 //Moment in kN.m
Iy=4.73*10**6 //Moment of inertia in y-axis in mm^4
Iz=48.9*10**6 //Moment of inertia in z-axis in mm^4
Sy=64.7*10**3 //Sectional Modulus in y-axis in mm^3
Sz=379*10**3 //Sectional Modulus in z-axis in mm^3
theta=16.2 //Angle between moment and z-axis in degrees
//Calculations
//Part 1
alpha=atan((Iz*Iy**-1)*tan(theta*%pi*180**-1))*180*%pi**-1 //Angle between NA and z-axis in degrees
//Part 2
My=-M*sin(theta*%pi*180**-1) //Bending Moment in y in kN.m
Mz=-M*cos(theta*%pi*180**-1) //Bending Moment in z in kN.m
sigma_max=My*Sy**-1+Mz*Sz**-1 //Largest Bending Stress in MPa
//Result
printf("\n The angle between the Neutral Axis and Z-Axis is %0.1f degrees",alpha)
printf("\n The maximum Bending Moment is %0.0f MPa",-sigma_max*10**6)
|
7db5421cbc08be42629450b820c5d895874a1988 | f8551f1c22ee634be672d893e6755b100f0d1994 | /ICP/appariement.sci | 9a9b78fd33da07287e6fafbc67a6024cccc5cc68 | [] | no_license | yanisdxw/computer-vision | ed605061a632ae0c7536007de6f83e2ff5ee1d51 | e9bd0961194f2e4290211296dbe6268ecad8f1c1 | refs/heads/master | 2021-08-23T05:30:24.864657 | 2017-12-03T17:05:35 | 2017-12-03T17:05:35 | 111,726,798 | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 819 | sci | appariement.sci | function [X1_ap,X2_ap,n_ap]=appariement(X1,X2,dmin)
[n1,l1]=size(X1);
[n2,l2]=size(X2);
X1_ap = X1;
[n_ap l_ap] = size(X1);
X2_ap = [];
for i = 1:n_ap
p_diff = [];
// matrix of points that includes all the points cloest possible
// and their distance to original points.
for j = 1:n2
dist = distance(X1_ap(i,:),X2(j,:))
// calcule distance entre point origin and point decalage
if dist<dmin then
// if their distance is les than dmin then add it to matrix p_diff
p_diff = [p_diff;X2(j,:) dist]
end
end
[X index] = min(p_diff(:,4));//find the point that has least distance to point original.
X2_ap(i,:)=p_diff(index,1:3);
end
endfunction
|
e12e6f6f5532d80b993305d906dfffa9ac5ee2da | 449d555969bfd7befe906877abab098c6e63a0e8 | /3673/CH17/EX17.3/Ex17_3.sce | c1bfe85fbc04e6619129e5b1dabd9dcb8632e0f0 | [] | 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,094 | sce | Ex17_3.sce | //Example 17_3 page no:831
clc;
//given
k=400;
fc=1000;
fx=1100;
//calculating m,L,C
m=sqrt(1-(fc/fx)^2)
L=k/(%pi*fc);
C=1/(%pi*k*fc);
//calculating T-section elements are
L1=m*L/2;
L1=L1*1000;//converting to milliHenry
C1=m*C;
C1=C1*10^6;//converting to microFarad
L2=(1-(m^2))*L/(4*m);
L2=L2*1000;//converting to milliHenry
disp("the values of T-section elements are");
disp(L1,"the inductance between which capacitance is connected is (in mH)");
disp(C1,"the capacitance connected between inductor is (in microFarad)");
disp(L2,"the inductance connected in series with capacitance is (in mH)");
//calculating the pi section elements are
C1=m*C/2;
C1=C1*10^6;//converting to microFarad
C2=(1-m^2)*C/(4*m);
C2=C2*10^6;//converting to microFarad
L1=m*L;
L1=L1*1000;//converting to milliHenry
disp("the values of pi section elements are");
disp(C1,"the capacitance connected in parallel is (in microFarad)");
disp(C2,"the capacitance connected in parallel to inductor is (in microFarad)");
disp(L1,"the inductor connected in parallel to capacitance is (in mH)");
|
8fdcea63777e36e0f346b9515071ee472af2acd9 | fbd17575bab2ee4dc49cc7d13b5b94d24ab9482c | /TP5/foncjaclap.sci | b0ac5ff3b4dbb63a762d9192e30168ee350ac9a2 | [] | no_license | 1saac-W/MT09-Analyse-Num-rique | 05b509981dfa00e3b7b550716b1487cbbf0a3fed | 0853f8053254f5dd23179073187ada3d936aff84 | refs/heads/master | 2020-09-27T04:34:36.549125 | 2020-01-05T16:02:18 | 2020-01-05T16:02:18 | 226,431,201 | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 462 | sci | foncjaclap.sci | function [F,J] = foncjac_lap(v)
alpha = 5;
bet = 5;
n = length(v)+1;
h = 1/n;
x = h*[1:n-1]';
F = zeros(n-1,1);
A =2*diag(ones(n-1,1))-diag(ones(n-2,1),+1)-diag(ones(n-2,1),-1);
deff('[b]=rhs(x)','b=-x.*(x-1)');
deff('[b]=g(x)','b=10*x./(1+x)');
deff('[b]=gp(x)','b=(10.)./((1+x)^2)');
F = A*v + h^2*g(v) - h^2*rhs(x);
F(1) = F(1) - alpha;
F(n-1) = F(n-1) - bet;
J = A+diag(gp(v))*h^2;
endfunction
|
e9960488540b2161018941050eaf212942c32a91 | 449d555969bfd7befe906877abab098c6e63a0e8 | /32/CH19/EX19.04/19_04.sce | 38d0322470f102f080f0349f7af054e4bb7db12a | [] | 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,041 | sce | 19_04.sce | //pathname=get_absolute_file_path('19.04.sce')
//filename=pathname+filesep()+'19.04-data.sci'
//exec(filename)
//Velociy of turbojet plane(in m/s):
Ca=277.78
//Thrust to velocity ratio:
r1=0.5
//Rate at which air enters(in kg/s):
m=50
//Air fuel ratio:
r=52
//Lower calorific value of fuel:
LCV=43100
//Jet velocity(in m/s):
Ce=Ca/r1
printf("\n RESULT \n")
printf("\nJet velocity = %f m/s",Ce)
//Thrust(in N):
T=(m+m/r)*Ce-m*Ca
printf("\nThrust = %f kN",T/10^3)
//Specific thrust(in N/kg/s):
St=T/m
printf("\nSpecific thrust = %f N/kg/s",St)
//Thrust power(in kW):
P=T*Ca/10^3
printf("\nThrust power = %f kW",P)
//Propulsive efficiency:
np=2/(1+1/r1)*100
printf("\nPropulsive efficiency = %f percent",np)
//Thermal efficiency:
nt=((1+1/r)*Ce^2-Ca^2)/(2*1/r*LCV)/10
printf("\nThermal efficiency = %f percent",nt)
//Overall efficiency:
no=np*nt/100
printf("\nOverall efficiency = %f percent",no)
//Specific fuel consumption(in kg/h.N):
sfc=m/r*3600/(T)
printf("\nSpecific fuel consumption = %f kg/h.N",sfc) |
bd146a6a4474609b4c13ccabebcae5a184a45abd | a62e0da056102916ac0fe63d8475e3c4114f86b1 | /set9/s_Engineering_Physics_K._V._Kumar_3537.zip/Engineering_Physics_K._V._Kumar_3537/CH1/EX1.12/Ex1_12.sce | df969c24ce3815faebaf95ad2b1ddf23fa8f6c64 | [] | 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 | 378 | sce | Ex1_12.sce | errcatch(-1,"stop");mode(2);//Example 1_13
;
;
//To calculate the fringe width
dist1=0.005 //units in mm
dist2=15 //units in cm
alpha=dist1/dist2 //units in radians
lamda=6000*10^-9 //units in cm
betaa=(lamda)/(2*alpha) //units in
printf("Fringe width beta=%.3fcm",betaa)
//In text book answer is printed wrong as 0.09 cm answer is 0.009 cm
exit();
|
5ec6dfb7c25758b2f3064f1e945aa026a81e1a5e | 449d555969bfd7befe906877abab098c6e63a0e8 | /2063/CH9/EX9.3/9_3.sce | 8c51a4dfea1a5e9442e4f9ca68d6e97fd47d5a73 | [] | 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 | 701 | sce | 9_3.sce | clc
clear
//Input data
D=0.15;//Diameter of a cylinder of a single acting reciprocating air compressor in m
L=0.2;//Length of the stroke in m
P1=1;//The pressure at which compressor sucks air in bar
P2=10;//Final pressure in bar
T1=298;//Initial Temperature in K
N=150;//Operating speed of the compressor in rpm
n=1.3;//Polytropic index of the process
//Calculations
V1=((3.14*D^2*L)/4);//Volume of air before compression in m^3
W=((n/(n-1))*P1*10^5*V1*((P2/P1)^((n-1)/n)-1));//Work done by the compressor for a polytropic compression of air in Nm
Pi=((W*N)/60)/1000;//Indicated power of the compressor in kW
//Output
printf('The indicated power of the compressor is %3.3f kW',Pi)
|
e3fac1cab67f3f8936eedbf0fc4cb9e427f5cff9 | 3c47dba28e5d43bda9b77dca3b741855c25d4802 | /microdaq/macros/microdaq_macros/mdaqAOScanInit.sci | 71a1e225d01cc705c545d04b5c3882fa61089da2 | [
"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 | 5,705 | sci | mdaqAOScanInit.sci | function result = mdaqAOScanInit(arg1, arg2, arg3, arg4, arg5, arg6, arg7)
global %microdaq;
result = []
link_id = -1;
channelNames = [];
if argn(2) == 1 then
channels = arg1.Channels;
data = [];
ao_range = arg1.Range;
continuous = arg1.isContinuous;
scan_freq = arg1.Rate;
scan_time = arg1.DurationInSeconds;
channelNames = arg1.Name
elseif argn(2) == 2 then
channels = arg2.Channels;
data = [];
ao_range = arg2.Range;
continuous = arg2.isContinuous;
scan_freq = arg2.Rate;
scan_time = arg2.DurationInSeconds;
channelNames = arg2.Name
elseif argn(2) == 6 then
channels = arg1;
data = arg2;
ao_range = arg3;
continuous = arg4;
scan_freq = arg5;
scan_time = arg6;
elseif argn(2) == 7 then
link_id = arg1;
channels = arg2;
data = arg3;
ao_range = arg4;
continuous = arg5;
scan_freq = arg6;
scan_time = arg7;
if link_id < 0 then
error("Invalid connection id!")
end
end
global %microdaq;
if %microdaq.private.mdaq_hwid <> [] then
if %microdaq.private.mdaq_hwid(3) == 0 then
error("Unable to detect MicroDAQ configuration. Run mdaqHWInfo() function.");
end
dac_info = get_dac_info(%microdaq.private.mdaq_hwid);
if find([1 2 6 7] == argn(2)) == [] then
mprintf("Description:\n");
mprintf("\tInitiates analog signal generation\n");
mprintf("Usage:\n");
mprintf("\tmdaqAOScanInit(linkID, channels, initialData, range, isStreamMode, rate, duration)\n")
mprintf("\tlinkID - connection id (optional)\n");
mprintf("\tchannels - analog output channels\n");
mprintf("\tinitialData - initial output data\n");
mprintf("\trange - analog output range\n");
mprintf("\t [-10,10] - single range argument applied for all used channels\n");
mprintf("\t [-10,10; -5,5] - multi-range argument for two channels\n");
mprintf("\tisStreamMode - mode of operation (%s - stream, %s - periodic)\n", "%T", "%F");
mprintf("\trate - update per second per channel rate\n");
mprintf("\tduration - duration in seconds (-1 - infinity)\n");
return;
end
else
error('Unable to detect MicroDAQ configuration. Run mdaqHWInfo() function.');
end
ch_count = size(channels, "c");
dac_ch_count = strtod(dac_info.channel);
if size(channels, 'r') > 1 then
error("Wrong channel - single row vector expected!")
end
if ch_count < 1 | ch_count > dac_ch_count then
error("Wrong AO channel selected!")
end
if max(channels) > dac_ch_count | min(channels) < 1 then
error("Wrong AO channel selected!")
end
if size(data, "c") <> ch_count & data <> [] then
error("Wrong output data - colums should match selected channels!")
end
if size(ao_range, 'c') <> 2 then
error("Vector range [low,high;low,high;...] expected!")
return;
end
if size(ao_range, 'r') == 1 then
range_tmp = ao_range;
ao_range = ones(ch_count,2);
ao_range(:,1) = range_tmp(1);
ao_range(:,2) = range_tmp(2);
end
range_tmp = ao_range;
ao_range = matrix(ao_range', 1, ch_count*2);
if data <> [] then
data_size = size(data, "*");
else
data_size = 0;
end
if type(continuous) == 1 then
if size(find(continuous>1), '*') > 0
error('Wrong isContinuous - boolean value expected (%T/1, %F/0)');
end
end
if continuous == %T | continuous == 1 then
continuous = 1;
else
continuous = 0;
end
if scan_time < 0 & scan_time <> -1 then
warning("For infinite AO scan operation use -1 as a duration parameter.\n");
scan_time = -1;
end
%microdaq.private.ao_scan_ch_count = ch_count;
if argn(2) == 6 | argn(2) == 1 then
link_id = mdaqOpen();
if link_id < 0 then
error("Unable to connect to MicroDAQ device!");
end
end
result = [];
result = call("sci_mlink_ao_scan_init",..
link_id, 1, "i",..
channels, 2, "i",..
ch_count, 3, "i",..
data, 4, "d",..
data_size, 5, "i",..
ao_range, 6, "d",..
continuous, 7, "i", ..
scan_freq, 8, "d",..
scan_time, 9, "d",..
"out",..
[1, 1], 10, "i");
if argn(2) == 6 | argn(2) == 1 then
mdaqClose(link_id);
end
if result < 0 then
error(mdaq_error2(result), 10000 + abs(result));
else
if result == 1 then
mprintf("\nWARNING: Your MicroDAQ device does not support running AI and AO scan simultaneously.\n")
end
dac_res = strtod(part(dac_info.resolution, 1:2))
for j=1:ch_count
if continuous == 1 then
isContinous = %t
else
isContinous = %f
end
dataSize = size(data);
result = tlist(["mdaqao",..
"Rate","DurationInSeconds","_ChannelCount","_DACResolution","Range", "Channels", "isContinuous", "BufferSize", "Name"],..
scan_freq, scan_time, ch_count, dac_res, matrix(ao_range, 2, ch_count)', channels, isContinous, dataSize, channelNames);
end
end
endfunction
|
7760aff69ae06d9174ffbf70e53f97a9d6af68f5 | f14f2861ee7e97cb37f69216b207bf431873cfb5 | /SciLab/Diferenciacion numerica.sce | 29593fad0402b011663837cb8c7df3d48e87a676 | [] | no_license | osfprieto/Personal | f97307f1014569baa9a10865c255072b8b949c11 | f0353c25718f29feebfb26da2003408e448a0aeb | refs/heads/master | 2022-09-20T13:11:19.242327 | 2022-09-12T19:53:37 | 2022-09-12T19:53:37 | 14,189,787 | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 5,138 | sce | Diferenciacion numerica.sce | //ofprietoc@unal.edu.co
//angarciariv@unal.edu.co
//Desarrollo profesor
function demoSegundaDer()
vv = -sin(0.8)
disp("Cálculo de f''''(0.8)")
disp(vv)
disp(["H" "VA" "EV" "EA"])
h1 = 0.1
d1 = derivada2(f, 0.8, h1)
ev1 = abs(vv-d1)
disp([h1 d1 ev1])
h01 = 0.01
d01 = derivada2(f, 0.8, h01)
ev01 = abs(vv-d01)
disp([h01 d01 ev01 abs(ev01-ev1)])
h001 = 0.001
d001 = derivada2(f, 0.8, h001)
ev001 = abs(vv-d001)
disp([h001 d001 ev001 abs(ev001-ev01)])
endfunction
function [y]=f(x)
y = cos(x)
endfunction
function [f2] = derivada2(f, xi, h)
f2 = (feval(xi-h, f)-2*feval(xi, f)+feval(xi+h, f))/(h^2)
endfunction
//Desarrollo adicional.
//Realiza la prueba para un arreglo de valores que se generan con
//función seno y luego de eso revisa los errores.
function realizarPrueba(h, x_inicial, x_final)
x = x_inicial:h:x_final
y = cos(x')
derivadaReal = -sin(x')
derivadaAproximada = diferencia_n_vector(y, h, 1)
errorAproximacion = abs(derivadaReal-derivadaAproximada)
disp("Valores de x usados")
disp(x')
disp("Valores calculados de la función cos(x)")
disp(y)
disp("Valores reales de la derivada d/dx(cos(x)) = -sin(x)")
disp(derivadaReal)
disp("Valores aproximados de la derivada d/dx(cos(x)) = -sin(x)")
disp(derivadaAproximada)
disp("Error de la aproximación")
disp(errorAproximacion)
disp("Promedio de los errores")
disp(mean(errorAproximacion))
plot(x, derivadaReal', '-', x, derivadaAproximada', '-', x, errorAproximacion', '-')
endfunction
//Retonar un vecotr con los valores aproximados de la derivada enésima
//de una función de valores dados con respecto al tamaño del salto.
//n: Grado de la derivada que se quiere obtener.
function vector_diferenciado=diferencia_n_vector(y_conocidos, h, n)
vec = y_conocidos
for i=1:n
vec = diferenciar_vector(vec, h)
disp("Derivada de orden")
disp(i)
disp(vec)
end
vector_diferenciado = vec
endfunction
//Retorna un vector con los valores aproximados de la derivada de
//una función de valores dados con respecto al tamaño del salto.
//y_conocidos: Datos medidos para cada punto xi igualmente separado
//otros
//h: Espacio entre cada uno de los puntos xi
function vector_diferenciado=diferenciar_vector(y_conocidos, h)
//Tamaño mínimo del vector: 3
//Derivadas centradas en el centro del vector
//Derivadas progresivas en el inicio
//Derivadas regresivas en el final
//yi = f(xi)
n = length(y_conocidos)
if n>=3 then
dif = []
//Diferencia progresiva al inicio del vector
dif(1) = (-3*y_conocidos(1)+4*y_conocidos(2)-y_conocidos(3))/(2*h)
//Diferencias centradas
for i=2:(n-1)
dif(i) = (y_conocidos(i+1) - y_conocidos(i-1))/(2*h)
end
//Diferencia regresiva al final de vector
//dfx(j,5)=(fx(j,3)-2*fx(j,2)+fx(j,1))/(h(1,j)^2);
dif(n) = (3*y_conocidos(n)-4*y_conocidos(n-1)+y_conocidos(n-2))/(2*h)
vector_diferenciado = dif
else
disp("Datos erróneos.")
vector_diferenciado = []
end
endfunction
//Ejercicio derivadas direccionales.
//Función multivariable
function z=fmulti(x, y)
z = x*x+y*y
endfunction
//Recibe dos vectores de valores
//X contiene los valores x a usar para calcular los valores z
//Y contiene los valores y a usar para calcular los valores z
//dibujar tiene la instrucción de dibujar los valores en pantalla o no.
//Devuelve una matriz con los valores evaluados después de
function z=evalFMulti(valores_x, valores_y, dibujar)
z_mat = []
m = length(valores_x)
n = length(valores_y)
for i = 1:m
for j = 1:n
z_mat(i,j) = fmulti(valores_x(i), valores_y(j))
end
end
if dibujar then
plot3d(valores_x, valores_y, z_mat)
end
z = z_mat
endfunction
//Demostración de la derivada direccional
//origen: vector desde dónde se quiere empezar a caminar
//pasos: Cantidad de pasos que queremos dar
//dv: Vector direccional
//h: Distancia del paso que queremos dar
//n: Orden de la derivada a calcular
function demoDerivadaDireccional(origen, pasos, dv, h, n)
//Sólo dibujamos
evalFMulti(-5:h:5, -5:h:5, %t)
//Convertir el vector dirección en vector unitario
dvu = (1.0/norm(dv))*dv
//Nuestro vector de movimiento (h en versión de vectores)
hv = h*dvu
vectorDiferenciar = []
puntosEvaluados = []
actual = origen
//Calculamos los valores de la función sobre la línea del vector dirección.
for i=1:pasos
vectorDiferenciar(i) = fmulti(actual(1), actual(2))
puntosEvaluados(i, 1) = actual(1)
puntosEvaluados(i, 2) = actual(2)
actual = actual + hv
end
disp("Puntos en donde se evaluó fmult")
disp(puntosEvaluados)
disp("Valores evaluados sobre el vector de dirección")
disp(vectorDiferenciar)
vector_diferenciado = diferencia_n_vector(vectorDiferenciar, h, n)
endfunction
|
e56bba5c9e2ba0fb92ddba8b7495772c70e6b9b8 | 449d555969bfd7befe906877abab098c6e63a0e8 | /3821/CH10/EX10.24/Example10_24.sce | 2c53ee79a6ef9bd83a73053c7dd6f4607467679d | [] | 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,105 | sce | Example10_24.sce | /////////Chapter 10 Properties Of Steam
///Example 10.24 Page No:204
///Find Enthalpy of steam of first boiler
clc;
clear;
//Input data;
FB=15; //First boiler in bar
SB=15; //Second boiler in bar
tsup1=300; //Temperature of the steam in degree celsius
tsup2=200; //Temperature of the steam in degree celsius
//From steam table (pressure basis at 15 bar )
ts=198.3; //In degree celsius
hf=844.7; //In KJ/Kg
hfg=1945.2; //In KJ/Kg
hg=2789.9; //In KJ/I
Cps=2.3;
//Calculation
h1=hg+Cps*(tsup1-ts); //Enthalpy of steam of first boiler in KJ/Kg
h3=hg+Cps*(tsup2-ts); //Enthalpy of steam in steam main in KJ/Kg
h2=2*h3-h1; //Energy balance in KJ/Kg
x2=(h2-hf)/hfg; //Enthalpy of wet steam
//OUTPUT
printf('Enthalpy of steam of first boiler= %f KJ/Kg\n',h1);
printf('Enthalpy of steam in steam main=%f KJ/Kg \n ',h3);
printf('Energy balance=%f KJ/Kg \n ',h2);
printf('Enthalpy of wet steam= %f \n ',x2);
|
f4196307a8bee06675713462596e975c3e261c3c | f0919c8ea73f22939a890aa4f8327f8200344d2b | /html/tcp_rec.tst | a57c6ed7d118548a0ab0bbb333be19b2189ba3e0 | [] | no_license | kalex375/OVC | af5e91f90754454b90f339e846c5b9112d38d6c8 | f4b47dfc497299c4944b4ff9b93253c279012454 | refs/heads/master | 2021-05-31T07:55:44.326597 | 2013-12-02T14:15:52 | 2013-12-02T14:15:52 | null | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 1,248 | tst | tcp_rec.tst | PL/SQL Developer Test script 3.0
28
DECLARE
c utl_tcp.connection; -- TCP/IP connection to the Web server
ret_val pls_integer;
BEGIN
c := utl_tcp.open_connection(remote_host => '192.168.100.2',
remote_port => 8084,
charset => 'US7ASCII'); -- open connection
--ret_val := utl_tcp.write_line(c, 'OPTIONS /svn/ORA_VER/trunk/$svn/act/exp/ HTTP/1.1'); -- send HTTP request
ret_val := utl_tcp.write_line(c, 'CHECKOUT /svn/ORA_VER/trunk/exp/EXP.log HTTP/1.1');
--MKACTIVITY http://www.example.com/repos/foo/$svn/act/01234567-89ab-cdef-0123-45789abcdef
ret_val := utl_tcp.write_line(c, 'Host: 192.168.100.2'); -- send HTTP request
ret_val := utl_tcp.write_line(c, 'Authorization: Basic bWFkY2FwOkdmaGprbTgy'); -- send HTTP request
ret_val := utl_tcp.write_line(c, 'Content-Length: 0'); -- send HTTP request
ret_val := utl_tcp.write_line(c);
--CHECKOUT /his/12/ver/V3 HTTP/1.1
--Host: repo.webdav.org
--Content-Length: 0
BEGIN
LOOP
dbms_output.put_line(utl_tcp.get_line(c, TRUE)); -- read result
END LOOP;
EXCEPTION
WHEN utl_tcp.end_of_input THEN
NULL; -- end of input
END;
utl_tcp.close_connection(c);
END;
0
0
|
a1d96070c4873baf3ce18e9636ccb6005552cfd4 | 449d555969bfd7befe906877abab098c6e63a0e8 | /1898/CH1/EX1.5/Ex1_5.sce | 2d76cfca323d0ffa05b23354dfe29e27cfa94e58 | [] | 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,839 | sce | Ex1_5.sce | clear all; clc;
disp("Scilab Code Ex 1.5 :")
// Given:
f_a = 50; //N
m_a = 70; // Moment at A in Nm
l_ad = 1.25; //Length of AD in m.
l_bd = 0.5; //Length of BD in m.
l_cb = 0.75; //Length of BC in m.
w_l = 2; //Kg/m
g = 9.81; //N/kg- acceleration due to gravity
//Free Body Diagram :
w_bd = w_l*l_bd*g; //in N. Weight of each segment of pipe that acts through the centre of gravity of each segment.
w_ad = w_l*l_ad*g;
// Equations of Equilibrium
//Balancing forces in the x direction:
f_b_x = 0; // N
//Balncing forces in the y direction:
f_b_y = 0; //N
//Balncing forces in the z direction:
f_b_z = g + w_ad + f_a; //N
// Balancing Moments in the x direction:
m_b_x = - m_a + (f_a*l_bd) + (w_ad*l_bd) + (l_bd/2)*g; //Nm
// Balancing Moments in the y direction:
m_b_y = - (w_ad*(l_ad/2)) - (f_a*l_ad); //Nm
// Balancing Moments in the z direction:
m_b_z = 0; //Nm
v_b_shear = sqrt(f_b_z ^2 + 0); //Shear Force in N
t_b = - m_b_y; //Torsional Moment in Nm
m_b = sqrt(m_b_x ^2+ 0); // Bending moment in Nm
//Display
// Displaying results:
printf('\n\n The weight of segment BD = %.1f N',w_bd);
printf('\n The weight of segment AD = %.1f N',w_ad);
printf('\n The force at B in the Z direction = %.1f N',f_b_z);
printf('\n The moment about B in the X direction = %.1f Nm',m_b_x);
printf('\n The moment about G in the Y direction = %.1f Nm',m_b_y);
printf('\n The Shear Force at B = %.1f N',v_b_shear);
printf('\n The Torsional Moment at B = %.1f Nm',t_b);
printf('\n The Bending Moment at B = %.1f Nm',m_b);
//-----------------------------------------------------END-----------------------------------------------------------------------------
|
6eb74c8bde2e598713c51a7396f59962f5cab7b8 | 449d555969bfd7befe906877abab098c6e63a0e8 | /2252/CH19/EX19.3/Ex19_3.sce | bf4c062823c31712a2f014b97fc8150e1805ea42 | [] | 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 | 748 | sce | Ex19_3.sce |
Po=60D+3//full load output of the motor
e=0.905//efficiency of the motor
Pin=Po/e
V=400//applied voltage
I=Pin/V//line current drawn by the motor
Rsh=200//resistance of the shunt field winding
Ish=V/Rsh
Ia=I-Ish
Ra=0.1//armature resistance
Eb=V-Ia*Ra
A=2//no. of parallel paths in armature winding
P=4//no. of poles
phi=45D-3//flux per pole
Z=450//total number of conductors
N=round(60*Eb*A/(P*phi*Z))
mprintf("Full load speed=%d rpm\n",N)
//calculating armature torque
Ta=0.159*P*phi*Ia*Z/A
mprintf("Torque developed by the armature of the DC motor=%f N-m\n",Ta)
//calculating useful torque
Psh=60D+3//shaft power
Tsh=60*Psh/(2*%pi*N)
mprintf("Useful torque=%f N-m",Tsh)
//error in the textbook answer for useful torque
|
c1c5f8fa80c5e6d64904f1e1e3bf00aa5bbb68d3 | 449d555969bfd7befe906877abab098c6e63a0e8 | /1955/CH1/EX1.1/example1.sce | 001c92aa261a4144c026c6c9dfa15409c9323121 | [] | 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 | 749 | sce | example1.sce | clc
clear
//input data
P01=1//initial pressure of a fluid in bar
P02=10//final pressure of a fliud in bar
T01=283//initial total temperature in K
ntt=0.75//total-to-total efficiency
d=1000//density of water in kg/m^3
r=1.4//ratio of specific heats for air
Cp=1.005//specific at heat at constant pressure in kJ/kg.K
//calculations
h0s1=(1/d)*(P02-P01)*10^2//enthalpy in kJ/kg
h01=(h0s1/ntt)//enthalpy in kJ/kg
T02s=T01*(P02/P01)^((r-1)/r)//temperature in K
h0s2=(Cp*(T02s-T01))//enthalpy in kJ/kg
h02=(h0s2/ntt)//enthalpy in kJ/kg
//output
printf('The work of compression for adiabatic steady flow per kg of fliud if \n(a)The fliud is liquid water is %3.1f kJ/kg\n(b)The fliud is air as a perfect gas is %3.2f kJ/kg',h01,h02)
|
39327ec3ea023f78da482e99011ea3d7df27a1f7 | 449d555969bfd7befe906877abab098c6e63a0e8 | /69/CH4/EX4.25/4_25.sce | 1d6e689512e8d62b2f208b67e1cee349fcbc98db | [] | 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 | 382 | sce | 4_25.sce | clear; clc; close;
Vcc = 20;
Vbe = 0.7;
Beta = 100;
Rb = 250*10^(3);
Re = 2*10^(3);
Vrb = 19.85;
Ic = 0;
Irb = Vcc/(Rb+Re);
Ib = (Vcc-Vbe)/(Rb+(Beta+1)*Re);
disp(Irb,'The base current(amperes) obtained is : ');
disp(Ib,'Ideally Ib(Amperes) should be :');
disp('Hence the transistor is in a damaged state,');
disp('with short-circuit between base and emitter.');
|
f694677757dc0ef2aa02dcb39aaf7c7097d9f906 | c6515791fea5828996a3924a74b5358852bc69f0 | /ap6_metodo_gradiente&wolfe/Simulador_f1.sci | fe764c04c98d58458fce2947a196296dd31a87a6 | [] | no_license | fernandascovino/fgv_math_modeling_3 | 366f05faa9fc657473acad8c1061b7c6feed8d4a | 11853e0bf2c05ad2df4fb369dfa922fc50c68ceb | refs/heads/master | 2023-02-24T23:03:18.431724 | 2021-01-31T18:08:16 | 2021-01-31T18:08:16 | 334,722,683 | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 107 | sci | Simulador_f1.sci | function [f,g]=Simulador_f1(x)
n = size(x,1)
f = [1:n]*(x.^2)
g = 2*[1:n]'.*x
endfunction
|
f004af0e9b975974f548145f4a96d0c5a48647da | 449d555969bfd7befe906877abab098c6e63a0e8 | /858/CH1/EX1.15/example_15.sce | e7c7c47c272d57bd04da9ce29fb9b6a77b14c9e7 | [] | 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 | 117 | sce | example_15.sce | printf('example 1.15 page number 46')
disp ("this is a theoritical question, book shall be referred for solution")
|
00911c2790ce25792e356ac629cb4ae24206f6f1 | 449d555969bfd7befe906877abab098c6e63a0e8 | /764/CH5/EX5.11.c/functions5_11.sci | 36f861a3dd44abc5fbce20b614450c6be1a3bb67 | [] | 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,014 | sci | functions5_11.sci |
//Function for plotting S-N Curve
function[a, b, c, d]= SNplot(Sut,Se)
//Initialise e
e = 4
//Initialise all given values
a = log10(0.9 * Sut)
b = log10(Se)
c = log10(Nmin)
d = log10(Nmax)
//Calculate the values of y-coordinate when x = 4 and 5 using linear interpolation
for i = 1:1:4
if(i == 1)
s(i) = c
l(i) = a
elseif(i == 4)
s(i) = d
l(i) = b
else
s(i) = log10(10^e)
l(i) = b + (((a - b)/(c - d))*(s(i) - d))
e = e + 1
end
end
//Plot S-N Curve
y = {l(1), l(2), l(3), l(4)}
x = {s(1), s(2), s(3), s(4)}
plot(x,y,'-*')
plot2d3(x,y)
//Get the handle of current axes
g = gca()
//Give labels and set label properties
g.labels_font_color=5
g.font_size=3
g.grid=[1,1]
g.box="off"
title('S-N Curve (Example 5.11)')
xlabel('log10N')
ylabel('log10Sf')
endfunction |
249e9a7b6d874fc9ac20c3f76ac1c7f631a57ec0 | da5f041febe4b5e738a88500e6b5c0eeea4da116 | /signals (1)/C1.sce | 4fbd7cb7aa5db3da7bde2e29d510557460147592 | [] | no_license | djouani/scilab-project | 283a5d7467957851787288bb0505a6ceac8b0e07 | 01331434dff090bdff27d416c57ee54484cd2c47 | refs/heads/main | 2023-07-25T04:49:09.341708 | 2021-09-08T11:39:39 | 2021-09-08T11:39:39 | null | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 3,821 | sce | C1.sce | global A F Tm Fd T k Signal
//A = evstr(x_dialog("Введи значение Амплитуды от 1-3",''));
//F = evstr(x_dialog("Введи значение Частота сигнала (Гц)",''));
//Tm = evstr(x_dialog("Введи значение Длительность сигнала (с)",''));
//Fd = evstr(x_dialog("Введи значение Частоты дискретизации(8000) (Гц)",''));
k = 0;
A = 10;
Tm = 48; // От 15 иначе кодер не работает // кратное 8 должно быть
F = 400;
Fd = 8000;
T = 1:Tm;
Is = A * sin(2 * %pi * T / (Fd/F));
f1=figure(); clf; // Создаём окно для вывода графиков
set(f1,'figure_name','FIRST WINDOW');
f1.figure_position=[200,200]
f1.figure_size=[1500,700]
subplot(3,1,1);
plot(T,Is); xtitle("Человеческий голос");
a=gca();
a.children //Косметическая часть для графика
poly1= a.children(1).children(1);
poly1.thickness = 2;
poly1.foreground = 2;
a.title.font_size=5;
xgrid();
xlabel("t (c)"); //Задаем название осям
ylabel("Amplitude (dB)")
sleep(3000);
//fs = evstr(x_dialog("Введи значение Fs, чтобы высчитать интервал дискретизации",''));
fs = 4000;
// Расчёт для вывода дискретизированного сигнала
b=Fd/fs; //По этой формуле мы высчитываем интервал дискретизации
samp = zeros(1,Tm);
for p = 1 : b : Tm
samp(p) = Is(p);
end
subplot(3,1,1);
plot2d3(samp); //Вывод Дискретизированного сигнала
title("Дискретный вид сигнала");
a=gca();
a.children //Косметическая часть для графика
poly1= a.children(1).children(1);
poly1.thickness = 2;
a.title.font_size=5;
sleep(3000);
//Ra = evstr(x_dialog("Введи значение Разрядность АЦП (3)",''));
// Рассчёт для вывода квантованого сигнала
Ra=13;
Ru = Ra^2;
Koef = Ru / (2*A);
N = length(T);
for i = 1:N;
Signal(:,i) = round(Is(T(i)) * Koef) / Koef;
end;
subplot(3,1,2);
plot2d2(T, Signal); //Вывод цифрового сигнала
xtitle("Квантованный сигнал","t","Amplitude");
a=gca();
a.children //Косметическая часть для графика
poly1= a.children(1).children(1);
poly1.foreground = 5;
poly1.thickness = 2;
a.title.font_size=5;
xgrid();
xlabel("t"); //Задаем название осям
ylabel("Amplitude")
// Расчёт для вывода FFT аналогового сигнала
T = 1: 1/Fd : Tm; //Не работало FFT потому что не было этой строки
N_T = size(T,'*');
FFT = abs(fft(Is(T)));
FFT_Hz = Fd*(0:(Tm/2))/Tm;
n_Hz = size(FFT_Hz,'*')
subplot(3,1,3);
plot(FFT_Hz,FFT(1:n_Hz))
xtitle("FFT");
a=gca();
a.children //Косметическая часть для графика
poly1= a.children(1).children(1);
poly1.thickness = 1;
poly1.foreground = 2;
a.title.font_size = 5;
xgrid();
xlabel("Гц");
ylabel("dB"),
|
8b05730293b0f6a6eb2a01f516f9932195e41eff | adaa1dc1e9781bebdc15cc0c3a4bfbfa059442fa | /cs506/HW3/High4.tst | 3ee318bebdee38b75f46cda7ffa3e410dc841ed9 | [] | no_license | rodrigo-r-martins/pace_university | e87fbf9d2eb47797f0652af59304bdbe5293f5cc | 7bfc407c2b7ae90e4e9d5cc650c6ae719358b084 | refs/heads/main | 2023-05-27T04:38:33.513928 | 2021-06-17T04:24:22 | 2021-06-17T04:24:22 | 377,698,848 | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 579 | tst | High4.tst | load High4.hdl,
output-file High4.out,
compare-to High4.cmp,
output-list in%B1.4.1 out%B1.2.1;
set in %B0000,
eval,
output;
set in %B0001,
eval,
output;
set in %B0010,
eval,
output;
set in %B0011,
eval,
output;
set in %B0100,
eval,
output;
set in %B0101,
eval,
output;
set in %B0110,
eval,
output;
set in %B0111,
eval,
output;
set in %B1000,
eval,
output;
set in %B1001,
eval,
output;
set in %B1010,
eval,
output;
set in %B1011,
eval,
output;
set in %B1100,
eval,
output;
set in %B1101,
eval,
output;
set in %B1110,
eval,
output;
set in %B1111,
eval,
output;
|
3372e74054374819fdb3392e4e61bb60a4b956d7 | 449d555969bfd7befe906877abab098c6e63a0e8 | /1697/CH6/EX6.8/Exa6_8.sce | 2d293469f0c2c4e8d2b5d684d6039627d8ea16ed | [] | 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 | 282 | sce | Exa6_8.sce | //Exa 6.8
clc;
clear;
close;
//Given Data:
f=5000;//in MHz
f=f*10^6;//in Hz
d=10;//in feet
d=d*0.3048;//in meter
c=3*10^8;//Speed of light in m/s
lambda=c/f;//in meter
r=2*d^2/lambda;//in meter
disp(r,"Minimum distance between primary and secondary antenna in meter :"); |
9822833fc39c6c8e6e0c52ee9ccd99d1211a1c78 | 449d555969bfd7befe906877abab098c6e63a0e8 | /3753/CH1/EX1.13/Ex1_13.sce | c494fdd33c336062082d8c8fdbd22388b2a329cc | [] | 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 | 250 | sce | Ex1_13.sce | //Example number 1.13, Page number 1.38
clc;clear;close
//Variable declaration
a2=1 // amplitude
a1=2*a2 // amplitude
//Calculation
r=a1/a2 // ratio
//Result
printf("r=%.f/1",r) //r = r/1 = r:1
printf("\nHence the ratio of the amplitudes= 2:1")
|
eca2f4063de157415ec9285b9d076b1e58be6486 | 6c7a728e11a427c93b15669517131a79a0703108 | /api/pdb_root/install/scripts/create_clones.tst | 6da16bc6cde0b2629fc9beb757ce5866fd245922 | [] | no_license | ZVlad1980/adm_scripts | 0b9fe4ff166213dc649d555c81e8d65b858074e4 | 9978a098c8140f5722b51e799969b76e2d68b42e | refs/heads/master | 2020-03-31T08:45:49.405822 | 2019-04-30T05:04:03 | 2019-04-30T05:04:03 | 152,071,490 | 1 | 0 | null | null | null | null | WINDOWS-1251 | Scilab | false | false | 1,514 | tst | create_clones.tst | PL/SQL Developer Test script 3.0
35
begin
pdb_pub.clone(
p_creator => 'PDB_ROOT',
p_pdb_name => 'WEEKLY',
p_pdb_parent => 'WEEKLY_CLONE'
);
pdb_pub.clone(
p_creator => 'PDB_ROOT',
p_pdb_name => 'WEEKLY_VBZ',
p_pdb_parent => 'WEEKLY_CLONE'
);
--pdb_pub.clone(p_creator => 'VBZ', p_pdb_name => 'TSTDB_TTS', p_pdb_parent => 'TSTDB');
--pdb_pub.unfreeze_(p_pdb_name => 'TSTDB');
-- pdb_pub.clone(p_creator => 'VBZ', p_pdb_name => 'TSTDB_TTS2', p_pdb_parent => 'TSTDB');
--pdb_pub.open_(p_pdb_name => 'TSTDB');
--pdb_pub.freeze_(p_pdb_name => 'TSTDB');
--pdb_pub.clone(p_creator => 'VBZ', p_pdb_name => 'TSTDB_TTS2_1', p_pdb_parent => 'TSTDB_TTS2');
/*--Размораживаем PDB источник
pdb_pub.unfreeze_(p_pdb_name => 'VBZ_TSTDB');
--создаем клон
pdb_pub.clone(p_creator => 'VBZ', p_pdb_name => 'VBZ_TSTDB_01', p_pdb_parent => 'VBZ_TSTDB');
--открываем и замораживаем PDB-источник
pdb_pub.open_(p_pdb_name => 'VBZ_TSTDB');
pdb_pub.freeze_(p_pdb_name => 'VBZ_TSTDB');
*/
--pdb_pub.open_(p_pdb_name => '');
--pdb_pub.unfreeze_(p_pdb_name => 'VBZ_TSTDB');
--pdb_pub.close_(p_pdb_name => 'VBZ_TSTDB');
--pdb_pub.request_drop(p_pdb_name => 'VBZ_TSTDB_01');
/* pdb_api.action(p_action => pdb_api.GC_ACT_CLONE,
p_pdb_name => 'VBZ_TSTDB2',
p_creator => 'VBZ',
p_planned_at => sysdate + 1
); --*/
end;
0
0
|
de5887219cd9d45f230ef78dbcff477c0e7e2a0c | 449d555969bfd7befe906877abab098c6e63a0e8 | /3137/CH16/EX16.62/Ex16_62.sce | d38080915f7516723cdf143cc5d819fbf70eb1f9 | [] | 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 | Ex16_62.sce | //Initilization of variables
m=7 //kg
g=9.8 //m/s^2
r=0.5 //m
I=0.875 //kg.m^2
//Calculations
//Solving for alpha and T
alpha=(m*g*r)/(I+m*r*0.5) //rad/s^2
T=(I*alpha)/r //N
//Result
clc
printf('The soultion is alpha =%f rad/s^2 and T=%f N',alpha,T)
|
5b863aae046a0db89b1f9c09184801ff2a08f07f | 449d555969bfd7befe906877abab098c6e63a0e8 | /1919/CH9/EX9.13/Ex9_13.sce | 4f14f6c5ba4b81e38274b2204c950e13697fe17a | [] | 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,750 | sce | Ex9_13.sce |
// Theory and Problems of Thermodynamics
// Chapter 9
// Air_water Vapor Mixtures
// Example 13
clear ;clc;
//Given data
mw3 = 1000 // cooling tower supply rate in kg/min
T1 = 303.15 // Temp of air entering cooling tower in K
RH1 = 0.3 // relative humidity of air entering cooler
T2 = 308.15 // Temp of air leaving cooling tower in K
RH2 = 0.8 // relative humidity of air leaving cooler
T3 = 318.15 // Temp of water entering cooling tower in K
T4 = 300.15 // Temp of water leaving cooling tower in K
// subscript 1 and 2 denotes the state of air entering and leaving the cooling tower respectively
// subscript 3 and 4 denotes the state of water entering and leaving the cooling tower respectively
// data from psychometric chart for T = 30 degree C and RH = 0.3
SH1 = 0.0078 // in kg H2O/kg air
h1 = 51 // in kJ/kg air
// data from psychometric chart for T = 35 degree C and RH = 0.8
SH2 = 0.029 // in kg H2O/kg air
h2 = 110 // in kJ/kg air
hw3 = 188.45 // in kJ/kg
hw4 = 113.25 // in kJ/kg
// mass balance for H2O:
//mw3-mw4 = ma*(SH2-SH1)
// energy balance gives:
// mw3*hw3 - mw4*hw4 = ma*(h2-h1)
// x(1) = ma; x(2)= mw4;
function[f] =F(x)
f(1) = mw3-x(2)-x(1)*(SH2-SH1);
f(2) = mw3*hw3 - x(2)*hw4 -x(1)*(h2-h1);
endfunction
x = [10 10];
y = fsolve(x,F)
ma = y(1); // air flow rate in kg/min
mw4 = y(2);
wat_mak = mw3-mw4; // make up water required
// Output Results
mprintf('Make up water required = %4.2f kg/min' , wat_mak);
mprintf('\n Air flow rate = %4.1f kg/min' , ma);
|
190f8efd5ea5138f353213b888eb6c8faad7b1d1 | 449d555969bfd7befe906877abab098c6e63a0e8 | /1460/CH14/EX14.3/14_3.sce | fe68f33810fd50a15ec70452a41bacecea9ef6d2 | [] | 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 | 284 | sce | 14_3.sce | clc
//initialization of variables
L=6.5 //in
thick=1 //in
k=0.06 //B/hr-ft-F
T1=350 //F
T2=110 //F
//calculations
QbyL=2*%pi*k*(T1-T2)/log(1+2/L)
//results
printf("heat flow = %d B/hr-ft",QbyL)
//The answer given in textbook is wrong. Please calculate using a calculator
|
cdec234fd325548be8aab3caa63ce3185c878350 | 449d555969bfd7befe906877abab098c6e63a0e8 | /2318/CH2/EX2.32/ex_2_32.sce | 43b7cf695d8851f6cb5ebb454415922a652f7a23 | [] | 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 | 267 | sce | ex_2_32.sce | //Example 2.32: error
clc;
clear;
close;
//given data :
V=20*10^3;// in V
v1=2*10^3;// in V
R=10*10^3;// in ohm
r=R*v1/V;
f=50;// in Hz
w=2*%pi*f;
C=0.60*10^-6;// in F
v=V/((R/r)*sqrt(1+((w^2*C^2*r^2*(R-r)^2)/R^2)));
Error=((v1-v)/v1)*100;
disp(Error,"Error,(%) = ")
|
1597f00d04a1de6a8967c87c71c893dc9806513d | 449d555969bfd7befe906877abab098c6e63a0e8 | /446/CH4/EX4.2/4_2.sce | 78679d0c05fa82c8c6da7143e77f778be4657013 | [] | 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 | 4_2.sce | clear
clc
disp('Ex-4.2');
// w=wavelength; consider k=2*(pi/w);
// differentiate k w.r.t w and replace del(k)/del(w) = 1 for equation.4.3
// which gives del(w)= w^2 /(2*pi*del(x)), hence
w=20; delx=200; // delx=200cm and w=20cm
delw=(w^2)/(delx*2*%pi);
printf('Hence uncertainity in length is %1.2f cm',delw); |
e72f9ac2b49321ed55ca1340db1e08c66e69f0d5 | c28130b62911f5891f14826350089c73c907d3b5 | /exo18_cout.sci | 51659fb3533ed1056bda4fff3a24a85ad029c652 | [
"MIT"
] | permissive | zyron92/Simulation_of_Cardiac_Excitation | f1709d032613f49427a72716b4e258c3b578b739 | 66813dc24128d9cb171e77d4f780b6bf54011d15 | refs/heads/master | 2021-01-19T10:25:43.810588 | 2017-02-16T12:58:38 | 2017-02-16T12:58:38 | 82,180,177 | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 2,227 | sci | exo18_cout.sci | //appeler les scripts nécessaires pour pouvoir utiliser toutes les méthodes
exec('exo5_initialise_grille.sci',-1)
exec('exo9_modele_complet.sci',-1)
exec('exo10_correctif.sci',-1)
exec('exo12_splitting.sci',-1)
exec('exo16_splitting_problem.sci',-1)
//Cout exo5(initialisation de grille)
val=0
T=100 //T
t0=0 //Temps initial
dt=0.01 //Pas de temps
e0=1.0 //e initial
r0=0.0 //r initial
for n=2:2:4
timer()
main_initialise(T,t0,dt,e0,r0,n)
time1=timer()
//--tableau de temps de calcul selon n (n = 0,2,4,6)
val= [val, time1]
end
//Cout exo9(problème modèle complet)
val=0
D=1 //Constant conductivité
T=50 //T
t0=0 //Temps initial
dt=0.01 //Pas de temps
for n=2:2:4
//--les vecteurs (condition) initiaux de taille n*n
e0=ones(n*n,1)
r0=zeros(n*n,1)
timer()
main_modele_complet(t0,dt,T,e0,r0,D,n)
time1=timer()
//--tableau de temps de calcul selon n (n = 0,2,4,6)
val= [val, time1]
end
//Cout exo10(problème modèle complet avec fonctions correctives)
val=0
D=1 //Constant conductivité
T=50 //T
t0=0 //Temps initial
dt=0.01 //Pas de temps
for n=2:2:4
//--les vecteurs (condition) initiaux de taille n*n :
//--Ici, c'est de la solution corrigé au t0 pour tester
[x,y]=genere_xy(n)
[e0,r0]=grille_solution(x,y,t0)
timer()
main_correctif(t0,dt,T,e0,r0,D,n)
time1=timer()
//--tableau de temps de calcul selon n (n = 0,2,4,6)
val= [val, time1]
end
//Cout exo12(problème modèle complet avec splitting façon 1)
val=0
D=1 //Constant conductivité
T=50 //T
t0=0 //Temps initial
dt=0.01 //Pas de temps
for n=2:2:4
//--les vecteurs (condition) initiaux de taille n*n
e0=ones(n*n,1)
r0=zeros(n*n,1)
timer()
main_splitting(t0,dt,T,e0,r0,D,n)
time1=timer()
//--tableau de temps de calcul selon n (n = 0,2,4,6)
val= [val, time1]
end
//Cout exo16(problème modèle complet avec splitting façon 2 avec rk2,cn2)
val=0
D=1 //Constant conductivité
T=50 //T
t0=0 //Temps initial
dt=0.01 //Pas de temps
for n=2:2:4
//--les vecteurs (condition) initiaux de taille n*n
e0=ones(n*n,1)
r0=zeros(n*n,1)
timer()
main_splitting_problem(t0,dt,T,e0,r0,D,n)
time1=timer()
//--tableau de temps de calcul selon n (n = 0,2,4,6)
val= [val, time1]
end
|
ce4e514f5e5f07ced146a5d85679510a2ec89d8a | 449d555969bfd7befe906877abab098c6e63a0e8 | /2048/DEPENDENCIES/polyno.sci | e54960cdb038534206e91a7a20948f97cdd97df9 | [] | 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 | 735 | sci | polyno.sci | // Updated(1-8-07)
// Operations:
// Polynomial definition
// Flipping of coefficients
// Variables ------- passed as input argument (either 's' or 'z')
// Both num and den are used mostly used in scicos files,
// to get rid of negative powers of z
// Polynomials with powers of s need to
// be flipped only
function [polynu,polyde] = polyno(zc,a)
zc = clean(zc);
polynu = poly(zc(length(zc):-1:1),a,'coeff');
if a == 'z'
polyde = %z^(length(zc) - 1);
else
polyde = 1;
end
// Scicos(4.1) Filter block shouldn't have constant/constant
if type(polynu)==1 & type(polyde)==1
if a == 'z'
polynu = %z; polyde = %z;
else
polynu = %s; polyde = %s;
end;
end;
endfunction
|
ffb16be60f907810137b439ded212a5e41290758 | 449d555969bfd7befe906877abab098c6e63a0e8 | /1172/CH1/EX1.1/Example1_1.sce | 83e063133a8ae0bba84c1c7f0a52c5bb42100753 | [] | 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 | 370 | sce | Example1_1.sce | clc //Given that
Beta=0.10//fringe width in cm
D=200// separation between source and screen in cm
lambda=0.00055// wavelength of incident light in cm
//Sample Problem 1 Page No. 46
printf ("\n # Problem 1 # \n")
d= (D*lambda)/ (10*Beta)
printf (" \n Standard formula used \n beta= lambda*D/d \n")
printf ("\n Separation between sources is %f cm. \n",d)
|
8b1e953c14553486b681ab50a7c6277d8441e068 | d465fcea94a1198464d7f8a912244e8a6dcf41f9 | /siminfo/kiks_siminfo_robotdist.sci | e323cb7906b2218d5bc1f4ef70a64e4531624b57 | [] | 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 | 886 | sci | kiks_siminfo_robotdist.sci | function [res] = kiks_siminfo_robotdist()
// Ouput variables initialisation (not found in input variables)
res=[];
// Display mode
mode(0);
// Display warning for floating point exception
ieee(1);
// function res=kiks_siminfo_robotdist
// returns the distance the simulated robot has travelled:
// [FWD BWD STRAIGHT]
// FWD: total distance moved forwards
// BWK: total distance moved backwards
// STRAIGHT: the distance, in a straight line, from
// the starting position (when kiks_kopen was called)
// to the current position of the Khepera.
// -----------------------------------------------------
// (c) 2000-2004 Theodor Storm <theodor@tstorm.se>
// http://www.tstorm.se
// -----------------------------------------------------
global("KIKS_DIST_FWD");
global("KIKS_DIST_BWD");
global("KIKS_DIST_STRAIGHT");
res = [KIKS_DIST_FWD,KIKS_DIST_BWD,KIKS_DIST_STRAIGHT];
endfunction
|
7d71253f90476e7c693e94540337cd2a4aa7f43b | 449d555969bfd7befe906877abab098c6e63a0e8 | /3651/CH8/EX8.2/2.sce | 8eaab51ed692d949233de3d0500d565a1ff5cfb7 | [] | 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 | 371 | sce | 2.sce | //variable declaration
d=50 //diameter
N_a=0.2 //Numerical aperture
lamda=1 //wavelength
//Calculations
N=4.9*(((d*10**-6*N_a)/(lamda*10**-6))**2)
//Result
printf('N =%0.3f \n',N)
printf('Fiber can support%0.3f guided modes \n',N)
printf('In graded index fiber, No.of modes propogated inside the fiber =%0.3f only',N/2) |
0d90eb8deff356d2f9910c118adcf9a0d9979a4e | 449d555969bfd7befe906877abab098c6e63a0e8 | /2021/CH9/EX9.4/Ex9_4.sce | 014783dce380c6f580c76cf36cc256548639038d | [] | 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 | Ex9_4.sce | //Finding of discharge through Trapezoidal Notch
//Given
H=0.3;
Cd1=0.62;
Cd2=0.6;
d=0.4;
w1=1.2;
w2=0.5;
h=0.4;
g=9.81;
//To Find
theta=((w1-w2)/2)/h;disp(theta);
q1=((2/3)*Cd1*sqrt(2*g)*H^(3/2));
q2=((8/15)*Cd2*sqrt(2*g)*theta*H^(5/2));
q=q1+q2;disp(q1);disp(q2);
disp("discharge through Trapezoidal Notch ="+string(q)+" m^3/sec");
|
f093b734b0d064be11c260d1022b4459e65c7c35 | 449d555969bfd7befe906877abab098c6e63a0e8 | /3755/CH2/EX2.22/Ex2_22.sce | c3c7a711ac41d1b6f43ebf0cc3b5bdd7b54f61ae | [] | 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 | 325 | sce | Ex2_22.sce | clear
//
//
//
//Variable declaration
rho=6250; //density(kg/m^3)
M=60.2; //molecular weight
N=6.02*10^26; //avagadro number
n=4; //number of atoms
//Calculations
a=(n*M/(rho*N))^(1/3); //lattice constant(m)
//Result
printf("\n lattice constant is %0.0f angstrom",a*10^10)
|
600cdb36a7fb70935e760f2f2b9286120435194b | 449d555969bfd7befe906877abab098c6e63a0e8 | /2021/CH13/EX13.2/EX13_2.sce | 2523477a8bbd9497a356f1ba7d28699aff2bcf3c | [] | 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 | 390 | sce | EX13_2.sce | //Finding of Boundary layer thickness , Drag Force
//Given
x=1;
L=1.5;
b=1.2;
vs=0.25;
mu=0.001;
rho=1000;
x2=1.2;
L2=1.2;
//To Find
A=L*b;
R=(rho*vs*x)/mu;
t=(5.477*x)/sqrt(R);
tau=(0.365*mu*vs*sqrt(R))/x;
R1=(rho*vs*L)/mu;
Cd=1.46/sqrt(R1);
Fd=(1/2)*Cd*rho*(vs)^2*A;
disp("Boundary Layer Thickness ="+string(t)+" meter");
disp("Drag Force ="+string(Fd)+" Newtons");
|
b2ac94856b7b99a0459e17b0e537d7d3cea3f97e | 63c8bbe209f7a437f8bcc25dc1b7b1e9a100defa | /test/0039.tst | 2e8045ea314c71140e84040851246379b34ed98f | [] | no_license | fmeci/nfql-testing | e9e7edb03a7222cd4c5f17b9b4d2a8dd58ea547c | 6b7d465b32fa50468e3694f63c803e3630c5187d | refs/heads/master | 2021-01-11T04:09:48.579127 | 2013-05-02T13:30:17 | 2013-05-02T13:30:17 | 71,239,280 | 0 | 0 | null | 2016-10-18T11:01:57 | 2016-10-18T11:01:55 | Python | UTF-8 | Scilab | false | false | 170 | tst | 0039.tst | sPLittEr c {}
FILTEr D { }
FILTeR w {h Sfu OR Ibx }
S -> YdxG
GrOuper lC {aGGreGaTE BItOr(i) As fBTh }
UnGROupeR m { }
GRouPFILTeR c {}
MErGeR o { EXpoRT QY } |
5d09cfefe6215a85299cfa0be2a1eaf8af550d46 | 9f9364e082d4bc2f7ee5cbd7a489642615821873 | /src/testCases/test1-19.tst | f07f0d35435fabf0392ec4b375d00981a1457a86 | [] | no_license | abrageddon/DLX-Opt | 4602617f83ddf8cb0fea83fecd2faa362849dfcd | 20038078f11a7ae67e7ab336e551e23966551290 | refs/heads/master | 2021-01-01T05:49:33.218016 | 2013-03-14T06:08:45 | 2013-03-14T06:08:45 | null | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 320 | tst | test1-19.tst | main
var a, b, c, d;
{
let a <- 424;
let b <- 4920;
let c <- 9302;
let d <- 2391;
if a != b then
if b != c then
if c != d then
call outputnum(a)
else
call outputnum(a)
fi
else
call outputnum(a)
fi
else
call outputnum(a)
fi;
call outputnewline()
}.
|
aa6068967b786b76de22d09cb79e65cb3b731a7e | 1bb72df9a084fe4f8c0ec39f778282eb52750801 | /test/TE340.prev.tst | 093bd8596af5f7a401702b969b6b6c4e0b9bb24b | [
"Apache-2.0",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | gfis/ramath | 498adfc7a6d353d4775b33020fdf992628e3fbff | b09b48639ddd4709ffb1c729e33f6a4b9ef676b5 | refs/heads/master | 2023-08-17T00:10:37.092379 | 2023-08-04T07:48:00 | 2023-08-04T07:48:00 | 30,116,803 | 2 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 4,996 | tst | TE340.prev.tst | TranspositionSet={[0,2,1,3],[1,0,2,3],[1,2,0,3],[2,1,0,3],[2,0,1,3]}
considerNonPrimitive
Expanding for base=4, level=1, reasons+features=base,transpose,primitive,same,similiar
Refined variables=a,b,c,d
[0+1a,0+1b,0+1c,0+1d]: unknown -> [1] [0,0,0,0] a³+b³+c³-d³
-> solution [0,0,0,0],trivial(3) [1,0,0,1],trivial(3) [0,1,0,1],trivial(3) [0,0,1,1],trivial(3)
---------------- level 0
expanding queue[0]^-1,meter=[4,4,4,4]: a³+b³+c³-d³
[0+4a,0+4b,0+4c,0+4d]: non-primitive
-> solution [0,0,0,0],trivial(3) [4,0,0,4],trivial(3) [0,4,0,4],trivial(3) [0,0,4,4],trivial(3)
[3+4a,1+4b,0+4c,0+4d]: unknown -> [1] [3,1,0,0] 108a+144a²+64a³+12b+48b²+64b³+64c³-64d³+28
[2+4a,2+4b,0+4c,0+4d]: non-primitive
[1+4a,3+4b,0+4c,0+4d]: transposed [1] by [1,0,2,3]
[3+4a,0+4b,1+4c,0+4d]: transposed [1] by [0,2,1,3]
[3+4a,2+4b,1+4c,0+4d]: unknown -> [2] [3,2,1,0] 108a+144a²+64a³+48b+96b²+64b³+12c+48c²+64c³-64d³+36
[0+4a,3+4b,1+4c,0+4d]: transposed [1] by [2,0,1,3]
[2+4a,3+4b,1+4c,0+4d]: transposed [2] by [1,0,2,3]
[2+4a,0+4b,2+4c,0+4d]: non-primitive
[3+4a,1+4b,2+4c,0+4d]: transposed [2] by [0,2,1,3]
[0+4a,2+4b,2+4c,0+4d]: non-primitive
[1+4a,3+4b,2+4c,0+4d]: transposed [2] by [2,0,1,3]
[1+4a,0+4b,3+4c,0+4d]: transposed [1] by [1,2,0,3]
[0+4a,1+4b,3+4c,0+4d]: transposed [1] by [2,1,0,3]
[2+4a,1+4b,3+4c,0+4d]: transposed [2] by [1,2,0,3]
[1+4a,2+4b,3+4c,0+4d]: transposed [2] by [2,1,0,3]
[1+4a,0+4b,0+4c,1+4d]: unknown -> [3] [1,0,0,1] 12a+48a²+64a³+64b³+64c³-12d-48d²-64d³
-> solution [1,0,0,1],trivial(3) [5,0,0,5],trivial(3)
[0+4a,1+4b,0+4c,1+4d]: transposed [3] by [2,0,1,3]
[2+4a,1+4b,0+4c,1+4d]: unknown -> [4] [2,1,0,1] 48a+96a²+64a³+12b+48b²+64b³+64c³-12d-48d²-64d³+8
[1+4a,2+4b,0+4c,1+4d]: transposed [4] by [1,0,2,3]
[0+4a,0+4b,1+4c,1+4d]: transposed [3] by [2,1,0,3]
[2+4a,0+4b,1+4c,1+4d]: transposed [4] by [0,2,1,3]
[3+4a,1+4b,1+4c,1+4d]: unknown -> [5] [3,1,1,1] 108a+144a²+64a³+12b+48b²+64b³+12c+48c²+64c³-12d-48d²-64d³+28
[0+4a,2+4b,1+4c,1+4d]: transposed [4] by [2,0,1,3]
[2+4a,2+4b,1+4c,1+4d]: unknown -> [6] [2,2,1,1] 48a+96a²+64a³+48b+96b²+64b³+12c+48c²+64c³-12d-48d²-64d³+16
[1+4a,3+4b,1+4c,1+4d]: transposed [5] by [2,0,1,3]
[1+4a,0+4b,2+4c,1+4d]: transposed [4] by [1,2,0,3]
[0+4a,1+4b,2+4c,1+4d]: transposed [4] by [2,1,0,3]
[2+4a,1+4b,2+4c,1+4d]: transposed [6] by [1,2,0,3]
[1+4a,2+4b,2+4c,1+4d]: transposed [6] by [2,0,1,3]
[1+4a,1+4b,3+4c,1+4d]: transposed [5] by [2,1,0,3]
[3+4a,3+4b,3+4c,1+4d]: unknown -> [7] [3,3,3,1] 108a+144a²+64a³+108b+144b²+64b³+108c+144c²+64c³-12d-48d²-64d³+80
[2+4a,0+4b,0+4c,2+4d]: non-primitive
-> solution [2,0,0,2],trivial(3) [6,0,0,6],trivial(3)
[3+4a,1+4b,0+4c,2+4d]: unknown -> [8] [3,1,0,2] 108a+144a²+64a³+12b+48b²+64b³+64c³-48d-96d²-64d³+20
-> solution [3,5,4,6],NONTRIVIAL
[0+4a,2+4b,0+4c,2+4d]: non-primitive
-> solution [0,2,0,2],trivial(3) [0,6,0,6],trivial(3)
[1+4a,3+4b,0+4c,2+4d]: transposed [8] by [1,0,2,3]
[3+4a,0+4b,1+4c,2+4d]: transposed [8] by [0,2,1,3]
[3+4a,2+4b,1+4c,2+4d]: unknown -> [9] [3,2,1,2] 108a+144a²+64a³+48b+96b²+64b³+12c+48c²+64c³-48d-96d²-64d³+28
[0+4a,3+4b,1+4c,2+4d]: transposed [8] by [2,0,1,3]
[2+4a,3+4b,1+4c,2+4d]: transposed [9] by [1,0,2,3]
[0+4a,0+4b,2+4c,2+4d]: non-primitive
-> solution [0,0,2,2],trivial(3) [0,0,6,6],trivial(3)
[3+4a,1+4b,2+4c,2+4d]: transposed [9] by [0,2,1,3]
[2+4a,2+4b,2+4c,2+4d]: non-primitive
[1+4a,3+4b,2+4c,2+4d]: transposed [9] by [2,0,1,3]
[1+4a,0+4b,3+4c,2+4d]: transposed [8] by [1,2,0,3]
[0+4a,1+4b,3+4c,2+4d]: transposed [8] by [2,1,0,3]
[2+4a,1+4b,3+4c,2+4d]: transposed [9] by [1,2,0,3]
[1+4a,2+4b,3+4c,2+4d]: transposed [9] by [2,1,0,3]
[3+4a,0+4b,0+4c,3+4d]: unknown -> [10] [3,0,0,3] 108a+144a²+64a³+64b³+64c³-108d-144d²-64d³
-> solution [3,0,0,3],trivial(3) [7,0,0,7],trivial(3)
[3+4a,2+4b,0+4c,3+4d]: unknown -> [11] [3,2,0,3] 108a+144a²+64a³+48b+96b²+64b³+64c³-108d-144d²-64d³+8
[0+4a,3+4b,0+4c,3+4d]: transposed [10] by [2,0,1,3]
[2+4a,3+4b,0+4c,3+4d]: transposed [11] by [1,0,2,3]
[1+4a,1+4b,1+4c,3+4d]: unknown -> [12] [1,1,1,3] 12a+48a²+64a³+12b+48b²+64b³+12c+48c²+64c³-108d-144d²-64d³-24
[3+4a,3+4b,1+4c,3+4d]: unknown -> [13] [3,3,1,3] 108a+144a²+64a³+108b+144b²+64b³+12c+48c²+64c³-108d-144d²-64d³+28
[3+4a,0+4b,2+4c,3+4d]: transposed [11] by [0,2,1,3]
[3+4a,2+4b,2+4c,3+4d]: unknown -> [14] [3,2,2,3] 108a+144a²+64a³+48b+96b²+64b³+48c+96c²+64c³-108d-144d²-64d³+16
[0+4a,3+4b,2+4c,3+4d]: transposed [11] by [2,0,1,3]
[2+4a,3+4b,2+4c,3+4d]: transposed [14] by [2,0,1,3]
[0+4a,0+4b,3+4c,3+4d]: transposed [10] by [2,1,0,3]
[2+4a,0+4b,3+4c,3+4d]: transposed [11] by [1,2,0,3]
[3+4a,1+4b,3+4c,3+4d]: transposed [13] by [1,2,0,3]
[0+4a,2+4b,3+4c,3+4d]: transposed [11] by [2,1,0,3]
[2+4a,2+4b,3+4c,3+4d]: transposed [14] by [2,1,0,3]
[1+4a,3+4b,3+4c,3+4d]: transposed [13] by [2,0,1,3]
endexp[0]
---------------- level 1
Maximum level 1 [15] mod 4: a³+b³+c³-d³
|
4f56a9cc05f55bcaa5de7ec29d898f1f888e5a29 | 449d555969bfd7befe906877abab098c6e63a0e8 | /3557/CH9/EX9.4/Ex9_4.sce | 7eae46ddabfb7dbdec9c00e07bc0da6723564b6c | [] | 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 | 400 | sce | Ex9_4.sce | //Example 9.4//
xfe3c=6.69;//wt % //Fe3C composition
x=0.77;//wt % //x is the overall composition
xa=0;//wt % //composition of two phases
a=1;//kg
ma=((xfe3c-x)/(xfe3c-xa))*a
mprintf("ma = %f kg ",ma)
b=10^3;//g //As 1kg = 10^3grams
ma1=ma*b
mprintf("\nma1 = %i g ",ma1)
mfe3c=((x-xa)/(xfe3c-xa))*a
mprintf("\nmfe3c = %f kg ",mfe3c)
mfe3c1=mfe3c*b
mprintf("\nmfe3c1 = %i g",mfe3c1)
|
a822df12ed611830eccb156547657dd8a22bc4b2 | 449d555969bfd7befe906877abab098c6e63a0e8 | /1970/CH4/EX4.14/Ch04Exa14.sce | 282c5eaddb065c0fefac86255ea5ade0803ae0bf | [] | 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 | Ch04Exa14.sce | // Scilab code Exa4.14 : : Page 181 (2011)
clc; clear;
m_p = 0.938; // Mass of the proton, GeV
E = 1.4; // Total energy of proton, GeV
gama = E/m_p; // Boost parameter
bta = sqrt(1-1/gama^2); // Relativistic factor
d = 10; // Distance between two counters,m
C = 3e+08; // Velocity of light ,m/s
t_p = d/(bta*C); // Time of flight of proton ,sec
T_e = d/C; // Time of flight of electron, sec
printf("\nTime of flight of proton: %4.2f ns \nTime of flight of electron : %4.2f ns ", t_p/1e-009, T_e/1e-009);
// Result
// Time of flight of proton: 44.90 ns
// Time of flight of electron : 33.33 ns |
b667b2a6a1e01e5d2699309fa863c877a077f787 | 449d555969bfd7befe906877abab098c6e63a0e8 | /1004/CH1/EX1.24/Ch01Ex24.sci | 417996ad90f9c42e8f26f8f3d14db805f3346497 | [] | 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 | 538 | sci | Ch01Ex24.sci | // Scilab Code Ex1.24 Relativistic speed form relativistic mass: Pg: 30 (2008)
c = 3e+08; // Speed of light, m/s
m0 = 1/2; // Rest mass of the particle, MeV/c^2
m = 1/sqrt(2); // Relativistic mass of the particle, MeV/c^2
// As m = m0/sqrt(1 - (v/c)^2), Relativistic mass of electron, kg, solving for v, we have
v = sqrt(1 - (m0/m)^2)*c; // Relativistic velocity of particle, m/s
printf("\nThe relativistic velocity of particle = %4.2e m/s", v);
// Result
// The relativistic velocity of particle = 2.12e+008 m/s |
c4bcdf461fcc8c5071ddc39fc652b39a249e6fae | 449d555969bfd7befe906877abab098c6e63a0e8 | /199/CH4/EX4.10.b/Example_4_10_b.sce | 2c49b05ef9d4916b8bba05fa8a5cc660b824067c | [] | 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 | 779 | sce | Example_4_10_b.sce | // Chapter4
// Page.No-141, Figure.No-4.26
// Example_4_10_b
// Error voltage and output voltage
// Given
clear;clc;
delta_Vio=(30*10^-6); // Change in input offset voltage
delta_T=1; // Unit change in temperature
delta_Iio=(300*10^-12); // Change in input offset current
Vs=15;
R1=1*10^3;Rf=100*10^3;Rl=10*10^3;
Vin=10*10^-3; // Input voltage
k=25; // Amplifier is nulled at 25 deg
T=35-k; // Change in temperature
Ev=(1+Rf/R1)*(delta_Vio/delta_T)*T + Rf*(delta_Iio/delta_T)*T; // Error voltage
printf("\n Error voltage is = %.4f V dc \n",Ev) // Result
Vo=(1+Rf/R1)*Vin+Ev; // Output voltage
printf("\n Output voltage is = %.4f V dc \n",Vo) // Result
// (OR)
Vo=(1+Rf/R1)*Vin-Ev; // Output voltage
printf("\n Output voltage is = %.4f V dc \n",Vo) // Result |
585b856297cb07ac568265123ba9459fc011facb | 449d555969bfd7befe906877abab098c6e63a0e8 | /3472/CH17/EX17.14/Example17_14.sce | 8881564e67501e84900668577606379e9e5cb027 | [] | 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,042 | sce | Example17_14.sce | // A Texbook on POWER SYSTEM ENGINEERING
// A.Chakrabarti, M.L.Soni, P.V.Gupta, U.S.Bhatnagar
// DHANPAT RAI & Co.
// SECOND EDITION
// PART II : TRANSMISSION AND DISTRIBUTION
// CHAPTER 10: POWER SYSTEM STABILITY
// EXAMPLE : 10.14 :
// Page number 304
clear ; clc ; close ; // Clear the work space and console
// Given data
Power = 20.0*10**3 // Rating of generator(kVA)
PF = 0.8 // Lagging power factor
fault = 0.5 // Reduction in output under fault
P = 4.0 // Number of poles
f = 50.0 // Frequency(Hz)
// Calculations
P_m = Power*PF // Output power before fault(kW)
P_e = fault*P_m // Output after fault(kW)
P_a = P_m-P_e // Accelerating power(kW)
w_s = 4.0*%pi*f/P // Speed
T_a = P_a*10**3/w_s // Accelerating torque at the time the fault occurs(N-m)
// Results
disp("PART II - EXAMPLE : 10.14 : SOLUTION :-")
printf("\nAccelerating torque at the time the fault occurs, T_a = %.2f N-m", T_a)
|
988c81e2fab16bf3dadc7495e8012f0213123b64 | 449d555969bfd7befe906877abab098c6e63a0e8 | /3012/CH7/EX7.9/Ex7_9.sce | 5dcf9b32e7d2dc8f64e3cb22d4c278c87058ccbf | [] | 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,309 | sce | Ex7_9.sce | // Given:-
T0 = 273.00 // in kelvin
pricerate = 0.08 // exergy value at $0.08 per kw.h
// From example 6.8
sigmadotComp = 17.5e-4 // in kw/k
sigmadotValve = 9.94e-4 // in kw/k
sigmadotcond = 7.95e-4 // in kw/k
// Calculations
// The rates of exergy destruction
EddotComp = T0*sigmadotComp // in kw
EddotValve = T0*sigmadotValve // in kw
Eddotcond = T0*sigmadotcond // in kw
mCP = 3.11 // From the solution to Example 6.14, the magnitude of the compressor power in kW
// Results
printf( ' Daily cost in dollars of exergy destruction due to compressor irreversibilities = %.3f',EddotComp*pricerate*24)
printf( ' Daily cost in dollars of exergy destruction due to irreversibilities in the throttling valve = %.3f',EddotValve*pricerate*24)
printf( ' Daily cost in dollars of exergy destruction due to irreversibilities in the condenser = %.3f ',Eddotcond*pricerate*24)
printf( ' Daily cost in dollars of electricity to operate compressor = %.3f',mCP*pricerate*24)
|
96b8bbce01449eb78782654c4c5d2e07140cf875 | 449d555969bfd7befe906877abab098c6e63a0e8 | /3875/CH1/EX1.3/Ex1_3.sce | 55cb9d52ef3498e8bb071e6a8e9284edef33ed7a | [] | 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 | 591 | sce | Ex1_3.sce | clc ;
clear ;
m=0.1 // mass in kg
K=100 //spring constant in N/m
c=1 //resistive force in Nsm^-1
F0=2 //force in N
omega=50 //frequency in rad/s
//calculation
omega_n=sqrt(K/m) //in rad/s
r=omega/omega_n
delta_st=F0/K //in m
damp_ratio=c/(2*m*omega_n)
A=delta_st/(sqrt((1-r^2)^2+(2*r*damp_ratio)^2))
tan_phi=(2*r*damp_ratio)/(1-r^2) //in degree
phi=180+atand(tan_phi) //converting degree to postive form
mprintf("Amplitude of oscillation = %1.2e m\n",A)
mprintf("Phase relative to the applied force is = %1.1f degree",phi)
//The answers vary due to round of errors
|
70b3f7fedcf3895b6477cc0d4356399f52e3f600 | 449d555969bfd7befe906877abab098c6e63a0e8 | /122/CH7/EX7.a.23/exaA_7_23.sce | f5692f47c77ef5fb5c7f8da685e66e6c8951b285 | [] | 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 | 204 | sce | exaA_7_23.sce | // Example A-7-23
// Nichols plot
clear; clc;
xdel(winsid()); //close all windows
s = %s;
G = syslin('c',9 , s*(s+0.5)*(s^2 + 0.6*s + 10) );
black(G);
chart([8 -4],[],list(1,0));
xgrid(color('gray'));
|
1484155be579b85b26c5e4f0c3ab1cb5d16960f5 | 449d555969bfd7befe906877abab098c6e63a0e8 | /2939/CH1/EX1.2/Ex1_2.sce | 692c4b47dbeccce4506a689f29ae60345b008096 | [] | 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 | 157 | sce | Ex1_2.sce | //Ex1_2
clc;
//Given:
energy=2*10^-6;
c=2.5*10^-8;// velocity of light
//solution:
v=energy/c;// potential
printf("The potential in V is = %f ",v)
|
2d45f8b1ba6ba2583a31a5daa64621474f4b4d20 | d465fcea94a1198464d7f8a912244e8a6dcf41f9 | /system/kiks_server_request.sci | c34279776cd03087769f77ef2e14e0bcb8e27556 | [] | 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 | 2,822 | sci | kiks_server_request.sci | function [res] = kiks_server_request(id)
// Ouput variables initialisation (not found in input variables)
res=[];
// Display mode
mode(0);
// Display warning for floating point exception
ieee(1);
// -----------------------------------------------------
// (c) 2000-2003 Theodor Storm (Theodor.Storm@home.se)
// http://www.kiks.net
// -----------------------------------------------------
global("KIKS_SPDC","KIKS_GUI_HDL","KIKS_KIKSNET_PING","KIKS_KIKSNET_PING_COUNT","KIKS_NET_BUFSIZ","KIKS_FID","KIKS_ROBOT_MATRIX","KIKS_MMPERPIXEL","KIKS_KIKSNET_COMMAND","KIKS_KIKSNET_REPLY");
res = "";
KIKS_KIKSNET_REPLY = "";
if ~isempty(KIKS_KIKSNET_COMMAND) then KIKS_KIKSNET_COMMAND = "CMD:"+KIKS_KIKSNET_COMMAND;end;
if mtlb_logic(mtlb_double(KIKS_FID),">",-1) then
tic;
// !! L.14: Matlab function sprintf not yet converted, original calling sequence used
req = sprintf("R 1 %.3f %.3f %.3f %.3f %.3f %.3f %.3f %s",KIKS_ROBOT_MATRIX(id,1,1),KIKS_ROBOT_MATRIX(id,1,2),KIKS_ROBOT_MATRIX(id,1,3),mtlb_double(KIKS_ROBOT_MATRIX(id,6,7))*mtlb_double(KIKS_SPDC),mtlb_double(KIKS_ROBOT_MATRIX(id,6,8))*mtlb_double(KIKS_SPDC),KIKS_ROBOT_MATRIX(id,2,2),KIKS_ROBOT_MATRIX(id,2,1),KIKS_KIKSNET_COMMAND);
// !! L.15: Unknown function kiks_transmit_string not converted, original calling sequence used
kiks_transmit_string(KIKS_FID,req);
res = kiks_recieve_string(KIKS_FID);
if ~isempty(KIKS_KIKSNET_COMMAND) then
// !! L.18: Matlab function deblank not yet converted, original calling sequence used
KIKS_KIKSNET_REPLY = deblank(kiks_recieve_string(KIKS_FID));
end;
KIKS_KIKSNET_PING = mtlb_a(mtlb_double(KIKS_KIKSNET_PING),toc()); KIKS_KIKSNET_PING_COUNT = mtlb_a(mtlb_double(KIKS_KIKSNET_PING_COUNT),1);
if bool2s(isempty(KIKS_KIKSNET_PING_COUNT))|bool2s(mtlb_logic(KIKS_KIKSNET_PING_COUNT,">",10)) then
// !! L.22: Matlab function findobj not yet converted, original calling sequence used
// L.22: Name conflict: function name changed from findobj to %findobj
h = findobj("tag","t_kiksnet_text_ping");
if ~isempty(KIKS_KIKSNET_PING_COUNT) then
t = floor((KIKS_KIKSNET_PING*1000)/KIKS_KIKSNET_PING_COUNT);
else
t = floor(KIKS_KIKSNET_PING*1000);
end;
if mtlb_logic(t,">=",10) then // !! L.28: Matlab function sprintf not yet converted, original calling sequence used
// !! L.28: Matlab function set not yet converted, original calling sequence used
// L.28: Name conflict: function name changed from set to %set
set(h,"String",sprintf("%d ms",t));else // !! L.28: Matlab function set not yet converted, original calling sequence used
// L.28: Name conflict: function name changed from set to %set
set(h,"String","<10 ms");end;
KIKS_KIKSNET_PING = 0;
KIKS_KIKSNET_PING_COUNT = 0;
end;
end;
KIKS_KIKSNET_COMMAND = "";
endfunction
|
f1a1339c176f856031b1d35317eeb741542cc6a0 | 717ddeb7e700373742c617a95e25a2376565112c | /278/CH3/EX3.4/ex_3_4.sce | a401781bdd422bf1364f9098a6ebae232d27cf05 | [] | 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 | 593 | sce | ex_3_4.sce | //find limits of shaft and bearing and maximum and minimum clearance
clc
//solution
//given
//75 mm basic size
//since 75 lies betweenn 50 and 80
D=sqrt(50*80)//mm
i=0.45*(D)^0.33+0.001*D//standard tolerance unit
IT8=25*i*0.001//mm
IT7=16*i*0.001//mm
es=-2.5*(D)^0.34//mm//upper deviation of shaft
ei=es-IT7//mm//lower deviation fot hole
bs=75//mm//basic size
uh=75+IT8//upper limit of hole
us=75-0.01//mm//upper limit of shft
ls=us-0.03//mm
MxC=uh-ls//mm//maximum clearance
miC=75-us//mm
printf("maximum clearance is,%f mm\n",MxC)
printf("minimum clearance is,%f mm",miC) |
c7b1d0aa0b10ac14a7f1ba9d9d4ee7b4f1d4c65b | 449d555969bfd7befe906877abab098c6e63a0e8 | /45/DEPENDENCIES/noof1.sci | 85008cfcc503d880b10e0f6152bde3b557321e73 | [] | 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 | 281 | sci | noof1.sci | function res=noof1(a,z) //this function returns both the no of zeros and ones in given matrix
res=0;
for i=1:max(size(a(:,1)))
for j=1:max(size(a(1,:)))
if(a(i,j)==z)
res=res+1;
end
end
end
endfunction |
c011bdc8ef059eaec5dc911c777ad29d1a635e1a | 449d555969bfd7befe906877abab098c6e63a0e8 | /1946/CH10/EX10.4.b/Ex_10_4_b.sce | ba32895c05a2710c79aa2f9abe1525cdc15fccf1 | [] | 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 | 599 | sce | Ex_10_4_b.sce | // Example 10.4.b;//Thermal noise
clc;
clear;
close;
T=293;//TEMPRATURE IN KELVIN
K=1.38*10^-23;//boltzman constt
C=3*10^8;//SPEED of light in meter per second
e=1.6*10^-19;//elecronic charge
ht=6.62*10^-34;//plank constt.
Id=3;//dark current in nano ampere
n=0.60;//efficiency
Rl=4;//load resistance in killo ohms
h=0.9;//wavelength in micro meter
Po=200;// ouput power in nano wat
B=5;// bandwidth in mega hertz
it=(((4*K*T*B*10^6)/(Rl*10^3)));//thermal noise
itr=sqrt(it);//rms thermal noise
disp(it,"total thermal noise is")
disp(itr,"RMS thermal noise current in ampere is")
|
6d6f033aa9d9989d95f6772d095524af0e418c69 | 4a1effb7ec08302914dbd9c5e560c61936c1bb99 | /Project 2/Experiments/FURIA-C/results/FURIA-C.flare-10-1tra/result6s0.tst | ad884f51167b6132ce46258b46c81772ce9629d3 | [] | no_license | nickgreenquist/Intro_To_Intelligent_Systems | 964cad20de7099b8e5808ddee199e3e3343cf7d5 | 7ad43577b3cbbc0b620740205a14c406d96a2517 | refs/heads/master | 2021-01-20T13:23:23.931062 | 2017-05-04T20:08:05 | 2017-05-04T20:08:05 | 90,484,366 | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 946 | tst | result6s0.tst | @relation flare
@attribute LargestSpotSize{A,R,S,X,K,H}
@attribute SpotDistribution{X,O,I,C}
@attribute Activity{1,2}
@attribute Evolution{1,2,3}
@attribute Prev24Hour{1,2,3}
@attribute HistComplex{1,2}
@attribute BecomeHist{1,2}
@attribute Area{1,2}
@attribute C-class{0,1,2,3,4,5,6,7,8}
@attribute M-class{0,1,2,3,4,5}
@attribute X-class{0,1,2}
@attribute Class{H,D,C,B,E,F}
@inputs LargestSpotSize,SpotDistribution,Activity,Evolution,Prev24Hour,HistComplex,BecomeHist,Area,C-class,M-class,X-class
@outputs Class
@data
B B
B B
C D
H H
E D
B B
C C
D E
B B
D D
E C
H H
C C
E C
H H
E E
H H
C C
H H
D D
B B
D D
C C
D D
H H
C D
D C
C D
D C
B B
B B
D C
D D
H H
H H
D D
B B
H H
H H
D D
B B
D C
D C
C D
H H
H H
C C
H H
B B
D C
D D
C D
D D
B B
H H
F D
B B
H H
H H
F D
H H
H H
H H
H H
H H
H H
H H
C C
D D
H H
C C
E D
H H
C C
D D
E D
E D
H H
H H
E E
F D
E E
D D
H H
H H
H H
B B
D D
C C
C C
H H
D C
C C
B B
C D
C D
C C
F D
D D
C C
B B
C D
D C
H H
D C
H H
|
d1391a628dea036f7f99f78a85f3e1b34ed05d1d | 449d555969bfd7befe906877abab098c6e63a0e8 | /3515/CH2/EX2.20/Ex2_20.sce | 4aff13a796780546b28fcf506b5fcf8a9cb118ba | [] | 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 | 777 | sce | Ex2_20.sce | // Exa 2.20
format('v',4);
clc;
clear;
close;
// Given data
unCox= 20*10^-6;//in A/V^2
upCox= unCox/2.5;// in A/V^2
V_DD= 3;//in V
Vt= 1;// in V
W= 30;// in µm
L= 10;// in µm
// V_GS1= V_GS2
// Formula V_DD= V_GS1+V_GS2
V_GS1= V_DD/2;//in V
V_GS2= V_GS1;// in V
V2= V_GS1;// inV
I1= 1/2*unCox*W/L*(V_GS1-Vt)^2;// in A
// Both transistor have V_D = V_G and therefore they are operating in saturation
//1/2*unCox*W/L*(V4-Vt)^2 = 1/2*upCox*W/L*(V_DD-V4-Vt)
V4= (V_DD-Vt+sqrt(unCox/upCox))/(1+sqrt(unCox/upCox));
I3= 1/2*unCox*W/L*(1.39-Vt)^2
disp(V2,"The value of V2 in volt is : ")
I1= I1*10^6;// in µA
disp(I1,"The value of I1 in µAis : ")
disp(V4,"The value of V4 in volt is : ")
I3= I3*10^6;// in µA
disp(I3,"The value of I3 in µAis : ")
|
ef66fe6cfe8b97d8bf91b43e03e8b18d17e3113e | 449d555969bfd7befe906877abab098c6e63a0e8 | /1199/CH4/EX4.3/4_3.sci | b2eaa161cdf627f3f8d0337c687570a8abc6a5ec | [] | 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 | 89 | sci | 4_3.sci | // 4.3
clc;
Pc=50;
m=0.85;
Pt=Pc*(1+(m^2/2))
printf("Radiation Power =%.2f kW",Pt)
|
b6b56d682d3603dc868e058178af6bc1285b7ee0 | be6c437e65374d9f058b6a13ec704e0ebddeda4b | /ChoreStorefront/Typewriter/definitions/Interfaces.tst | 45c56a2e229b1b8159c211a32019f7188948d9c8 | [] | no_license | dlswimmer/ChoreStorefront | 9bab0b6fc183ac69f754c66db3a0bf1fe290fbf6 | 37c03fee7a5216bc093722d5d0d3be01b7b024c6 | refs/heads/master | 2023-01-16T06:26:34.679767 | 2020-11-29T22:05:29 | 2020-11-29T22:05:29 | 317,050,361 | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 10,489 | tst | Interfaces.tst | import * as enums from '../enums';
declare global {
namespace models {
${
private const string IncludeClassAttribute = "TsClassModule";
private static readonly string[] IgnorePropertyAttribute = {"IgnoreDataMember", "TsIgnore"};
private const string OptionalMemberPropertyAttribute = "TsOptionalMember";
private const string CanBeNullPropertyAttribute = "CanBeNull";
private const string IncludeEnumAttribute = "TsEnumModule";
Template(Settings settings)
{
settings.IncludeProject("ChoreStorefront")
.IncludeProject("ChoreStorefront.Core")
.IncludeProject("ChoreStorefront.Model")
.IncludeProject("ChoreStorefront.Api");
settings.OutputExtension = ".d.ts";
}
IEnumerable<Property> GetProperties(Class c) {
var result = c.Properties.Where(m=>!m.Attributes.Any(a=>IgnorePropertyAttribute.Contains(a.Name)));
if (c.BaseClass!=null && !c.BaseClass.Attributes.Any(a=>a.Name==IncludeClassAttribute)) {
result = result.Concat(GetProperties(c.BaseClass));
}
return result;
}
IEnumerable<Property> GetProperties(Interface c) {
var result = c.Properties.Where(m=>!m.Attributes.Any(a=>IgnorePropertyAttribute.Contains(a.Name)));
return result;
}
bool IncludeClass(Class c) {
return c.Attributes.Any(a => a.Name==IncludeClassAttribute);
//var c2 = c;
//while (c2!=null) {
// if (c2.Attributes.Any(a => a.Name==IncludeClassAttribute)) {
// return true;
// }
// c2 = c2.BaseClass;
// if (c2 !=null && c2.Name=="DefaultCommandResult") {
// return false;
// }
//}
//return false;
}
string ClassNameWithExtends(Class c) {
var name = c.Name;
if (c.TypeParameters.Any()) {
name += c.TypeParameters.ToString();
}
var extends = new List<string>();
if (c.BaseClass!=null && c.BaseClass.Attributes.Any(a=>a.Name==IncludeClassAttribute)) {
var s = c.BaseClass.Name;
if (c.BaseClass.TypeParameters.Any()) {
s += c.BaseClass.TypeArguments.ToString();
}
extends.Add(s);
}
foreach (var i in c.Interfaces.Where(m=>m.Attributes.Any(a=>a.Name==IncludeClassAttribute))) {
if (!i.TypeParameters.Any()) {
var s = i.Name;
extends.Add(s);
//s += i.TypeParameters.ToString();
}
}
if (extends.Any()) {
name += " extends " + string.Join(", ", extends);
}
return name;
}
string ClassNameWithExtends(Interface c) {
var name = c.Name;
if (c.TypeParameters.Any()) {
name += c.TypeParameters.ToString();
}
var extends = new List<string>();
foreach (var i in c.Interfaces.Where(m=>m.Attributes.Any(a=>a.Name==IncludeClassAttribute))) {
if (!i.TypeParameters.Any()) {
var s = i.Name;
//s += i.TypeParameters.ToString();
extends.Add(s);
}
}
if (extends.Any()) {
name += " extends " + string.Join(", ", extends);
}
return name;
}
string BaseClassNotIncludedWarning(Class c) {
if (c.BaseClass!=null && !c.BaseClass.Attributes.Any(a=>a.Name==IncludeClassAttribute)) {
return "// WARNING: Base Class " + c.BaseClass.Name + " not marked with " + IncludeClassAttribute + " - so including base class properties inline instead of extending base class.\n// You should really decorate the " + c.BaseClass.Name + " class with the " + IncludeClassAttribute + " attribute.";
}
return "";
}
string PropertyName(Property p) {
var name = p.name;
//var cls = p.Parent as Class;
//if (cls!=null && cls.Attributes.Any(m=>m.Name=="JsonObject" && m.Value.Contains("CamelCaseNamingStrategy"))) {
//name = p.name;
//}
var isOptional = p.Type.IsNullable || p.Attributes.Any(a => a.Name==OptionalMemberPropertyAttribute || a.Name==CanBeNullPropertyAttribute);
if (isOptional) {
return name + '?';
}
if (p.Parent is Class c) {
var baseClass = c.BaseClass;
if (baseClass!=null) {
var baseProperty = baseClass.Properties.FirstOrDefault(m=>m.Name==p.Name);
if (baseProperty!=null) {
return PropertyName(baseProperty);
}
}
}
return name;
}
string EnumType(Property p) {
var constAttribute = p.Attributes.FirstOrDefault(m=>m.Name=="TsConstant");
if (constAttribute!=null) {
return "enums." + constAttribute.Value;
}
if (!p.Type.Attributes.Any(a=>a.Name=="JsonConverter" && a.Value.Contains("StringEnumConverter")))
{
var parentClass = p.Parent as Class;
var baseClass = parentClass?.BaseClass;
if (baseClass!=null) {
var baseProperty = baseClass.Properties.FirstOrDefault(m=>m.Name==p.Name);
if (baseProperty!=null) {
return EnumType(baseProperty);
}
}
}
if (p.Type.IsEnumerable) {
return "readonly enums." + p.Type.ToString();
}
return "enums." + p.Type.ToString();
}
string PropertyType(Property p) {
var type = p.Attributes.FirstOrDefault(m=>m.Name=="TsType");
if (type!=null) {
return GetType(type.Arguments[0].TypeValue);
}
if (p.Type.IsEnum && p.Type.Attributes.Any(a => a.Name ==IncludeEnumAttribute)) {
return EnumType(p);
}
if (p.Type.IsEnumerable && p.Type.TypeArguments.Count==1) {
var t = p.Type.TypeArguments[0];
if (t.IsEnum && t.Attributes.Any(a => a.Name ==IncludeEnumAttribute)) {
return EnumType(p);
//return "enums." + type.ToString();
}
}
return GetType(p.Type);
}
string GetType(Type type) {
if ((type.OriginalName.StartsWith("Dictionary") || type.OriginalName.StartsWith("IReadOnlyDictionary")) && type.TypeArguments.Count==2) {
var keyType = type.TypeArguments[0];
var valueType = type.TypeArguments[1];
var keyTypeStr = keyType.IsEnum ? "number" : keyType.ToString();
return "{ [key: " + keyTypeStr +"]: " + valueType.ToString() +"; }";
}
if (type.ToString()=="Date") {
return "string";
}
if (type.ToString()=="Date[]") {
return "readonly string[]";
}
if (type.OriginalName.StartsWith("IReadOnlyCollection") && type.TypeArguments.Count==1) {
var keyType = type.TypeArguments[0];
return "readonly " + keyType + "[]";
}
if ((type.IsEnumerable) && !type.OriginalName.StartsWith("Dictionary") && (type.BaseClass==null || !type.BaseClass.Name.StartsWith("Dictionary"))) {
return "readonly " + type.ToString();
}
//var isOptional = p.Type.IsNullable || p.Attributes.Any(a => a.Name==OptionalMemberPropertyAttribute || a.Name==CanBeNullPropertyAttribute);
//if (isOptional) {
//return p.Type.ToString() + " | null";
//}
//return "Test: " + type.OriginalName;
return type.ToString();
}
string DisplayValuePropertyType(Property p) {
if (p.Type.Name=="string") {
return "{ display: string }";
}
if (p.Type.IsPrimitive) {
return "{ display: string; value: " + PropertyType(p) + "; }";
}
return p.Type.ToString();
}
string DocCommentFormatted(Item i) {
var dc = (i as Class)?.DocComment ?? (i as Interface)?.DocComment ?? (i as Property)?.DocComment ?? (i as Constant)?.DocComment;
var summary = string.Empty;
if (dc != null) {
summary = dc.Summary;
}
if (i is Property p && p.Type.IsDate) {
var kindAttrib = p.Attributes.FirstOrDefault(a=>a.Name=="DateTimeKind");
if (kindAttrib!=null) {
if (!string.IsNullOrEmpty(summary)) {
summary+="\n";
}
if (kindAttrib.Value=="System.DateTimeKind.Utc") {
summary += "DateTime in UTC";
}
else if (kindAttrib.Value=="System.DateTimeKind.Local") {
summary += "DateTime in PST";
}
}
}
if (!string.IsNullOrEmpty(summary)) {
return @"/**
* " + summary + @"
*/";
}
return null;
}
}
$Classes(c => IncludeClass(c) && !c.Attributes.Any(a=>a.Name=="SerializeDisplayValue") && c.Name!="DefaultCommandResult")[
$DocCommentFormatted
export interface $ClassNameWithExtends {
$GetProperties()[
$DocCommentFormatted
$PropertyName: $PropertyType;
]
}
$NestedClasses(c => c.Attributes.Any(a => a.Name==IncludeClassAttribute))[
$DocCommentFormatted
export interface $ClassNameWithExtends {
$GetProperties()[
$DocCommentFormatted
$PropertyName: $PropertyType;
]
}
]
]
$Classes(c => c.Attributes.Any(a => a.Name==IncludeClassAttribute) && c.Attributes.Any(a=>a.Name=="SerializeDisplayValue"))[
$DocCommentFormatted
export interface $ClassNameWithExtends {
$GetProperties()[
$DocCommentFormatted
$PropertyName: $DisplayValuePropertyType
]
}
]
$Interfaces(c => c.Attributes.Any(a => a.Name==IncludeClassAttribute) )[
$DocCommentFormatted
export interface $ClassNameWithExtends {
$GetProperties()[
$DocCommentFormatted
$PropertyName: $PropertyType;
]
}
]
}
} |
9cedafc6e3ac2027b54aa59f6dc5862beb38a9ff | 449d555969bfd7befe906877abab098c6e63a0e8 | /3843/CH9/EX9.14/Ex9_14.sce | 6ce8e5d68071b99699a900eb5cf8d912eecfbc0d | [] | 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,089 | sce | Ex9_14.sce | // Example 9_14
clc;funcprot(0);
// Given data
P_1=10;// kPa
P_3=4;// MPa
P_5=100;// kPa
W_ST=100;// The power output from the turbine in MW
T_5=25+273;// K
r_p=5;// The pressure ratio
T_7=850+273;// K
T_9=350;// K
c_p=1.00// kJ/kg.K
k=1.4;// The specific heat ratio
// Calculation
h_1=192;// kJ/kg
h_2=h_1;// kJ/kg
// At 400°C and 4 MPa
h_3=3214;// kJ/kg
s_3=6.7698;// kJ/kg.K
s_4=s_3;// kJ/kg.K
s_f4=0.6491;// kJ/kg.K
s_fg4=7.5019;// kJ/kg.K
x=(s_4-s_f4)/s_fg4;// The quality of steam
h_f4=192;// kJ/kg
h_fg4=2393;// kJ/kg
h_4=h_f4+(x*h_fg4);// kJ/kg
h_3=3214;// kJ/kg
m_s=(W_ST*10^3)/(h_3-h_4);// kg/s
T_6=T_5*(r_p)^((k-1)/k);// K
T_8=T_7*(1/r_p)^((k-1)/k);// K
h_2=192;// kJ/kg
m_a=(m_s*(h_3-h_2))/(c_p*(T_8-T_9));// kg/s
W_turb=m_a*c_p*(T_7-T_8);// kJ/kg
W_comp=m_a*c_p*(T_6-T_5);// kJ/kg
W_GT=(W_turb-W_comp)/10^3;// The net gas turbine output in MW
Q_in=(m_a*c_p*(T_7-T_6))/10^3;// MW
n=(W_ST+W_GT)/Q_in;// The combined cycle efficiency
printf("\nThe efficiency of the combined Brayton-Rankine cycle,n=%0.3f or %2.1f percentage.",n,n*100);
|
75f9adbefbf2ba51ab9187fb006627a0e6bed87f | 0812f3bb6f3cc038b570df68ccee4275da04b11f | /models/complexity_1000/Applied_Thermodynamics_and_Engineering/CH7/EX7.10/7_10.sce | ebe25f470f2ef3534797e10d71b2af88b681c868 | [] | no_license | apelttom/20-semester_PhD_thesis | edc0b55580bae9d364599932cd73cf32509f4b7a | ff28b115fcf5e121525e08021fa0c02b54a8e143 | refs/heads/master | 2018-12-26T22:03:38.510422 | 2018-12-14T20:04:11 | 2018-12-14T20:04:11 | 106,552,276 | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 249 | sce | 7_10.sce | clc;
b=0.228;
a=1-b;
c=[1+(2*0.455)-b-2*a]/2
n2=a+b+c+1.709;
p1=8.28;
T2=555;
n1=1+0.455+1.709;
T1=2968;
p2=p1*(n2/n1)*(T1/T2);
p=1;
K=a/b*[n2*p/(c*p2)]^0.5;
disp(log(K),"log(K) is:");
disp("2968","from tables it is proved that temperatur is:")
|
145277fefcdc029de2c320d2593c65e17bc3a10a | 76b8c4ba0a69d3281b658f0fcf0ec56a96e27581 | /Scripts/filtreMoyenneur.sci | 1a484ae052997eb731da3ef5f761e336c56f1a7e | [] | no_license | RomainJunca/ExoLife | 0824fa566b38c5061f77592df6c38c3614dd8619 | 8da1524432d0ef1137d5e73e80cec339e6ec1c33 | refs/heads/master | 2020-05-25T14:08:07.353617 | 2017-03-20T08:31:32 | 2017-03-20T08:31:32 | 84,937,995 | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 707 | sci | filtreMoyenneur.sci | // Convolution spatiale : Filtre Moyenneur 3*3
function image_out = filtreMoyenneur(image)
SizeX = size(image, 1); //On récupère la longueur de l'image à modifier.
SizeY = size(image, 2); //On récupère la largeur de l'image à modifier.
image_out = zeros(SizeX, SizeY); //On crée une matrice nulle qui va contenir l'image modifiée.
for X = 2 : SizeX-1 //On parcourt la matrice en évitant les extrémités.
for Y = 2 : SizeY-1
image_out(X, Y) = round((image(X-1, Y-1)+image(X, Y-1)+image(X+1, Y-1)+image(X-1, Y)+image(X, Y)+image(X+1, Y)+image(X-1, Y+1)+image(X, Y+1)+image(X+1, Y+1))/9); //On arrondit les coefficients.
end
end
endfunction
|
319d967dbee9ac46cd081c676e83acb744bd914e | 449d555969bfd7befe906877abab098c6e63a0e8 | /2084/CH2/EX2.4w/2_4w.sce | 4de4edf5b84ccb0a595fbc6c489486de12a992ac | [] | 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 | 635 | sce | 2_4w.sce | //developed in windows XP operating system 32bit
//platform Scilab 5.4.1
clc;clear;
//example 2.4w
//calculation of direction of resultant vector
//given data
//OA=OB=OC=F all the three vectors have same magnitude
//xcompOA=F*cos30=(F*(sqrt(3)))/2
//xcompOB=F*cos360=F/2
//xcompOC=F*cos135=-F/(sqrt(2))
//xcompr=xcompOA + xcompOB + xcompOC
//ycompOA=F*cos60=F/2
//ycompOB=F*cos360=-(F*(sqrt(3)))/2
//ycompOC=F*cos135=F/(sqrt(2))
//ycompr=ycompOA + ycompOB + ycompOC
//calculation
theta=atand((1-sqrt(3)-sqrt(2))/(1+sqrt(3)+sqrt(2)));
disp(theta,'the angle(in degree) made by OA+OB-OC vector with X axis is');
|
35ee1d553958355d5ae8073c165c058ecce6d61e | 449d555969bfd7befe906877abab098c6e63a0e8 | /2951/CH6/EX6.5/ex6_5.sce | 5e5bf047bc85cd95335b0ea46882aead69c84577 | [] | 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 | 664 | sce | ex6_5.sce | clc;
clear;
Np1=60; // Noise-Power ratio of first system in dB
Np2=40; // Noise-Power ratio of second system in dB
Np3=30; // Noise-Power ratio of third system in dB
Np4=50; // Noise-Power ratio of fourth system in dB
P1=10^(-6); //power ratio of first system
P2=10^(-4); //power ratio of second system
P3=10^(-3); //power ratio of third system
P4=10^(-5);//power ratio of fourth system
SNR=(P1+P2+P3+P4); // Overall Signal to Noise ratio
disp("SNR ratio is");
disp(SNR);
N_final=30; //since SNR is 10^(-3)
disp("overall SNR (in dB)is");
disp(N_final);
disp("the overall SNR is equal to that of the worst system")
|
a4195a7d28eea696295f0ab72cddddfc6f1b2671 | 449d555969bfd7befe906877abab098c6e63a0e8 | /1736/CH3/EX3.17/Ch03Ex17.sce | ec38a303ac20b32872fc42d8559ccd9f3daa0974 | [] | 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 | 603 | sce | Ch03Ex17.sce | // Scilab Code Ex3.17: Page-103 (2006)
clc; clear;
h = 6.624e-034; // Planck's constant, Js
k = 1.38e-023; // Boltzmann constant, J/mol/K
q = 1.486e+011; // Young's modulus of diamond, N/metre-square
rho = 3500; // Density of diamond, kg/metre-cube
c = sqrt(q/rho); // Speed of transverse wave through diamond, m/s
m = 12*1.66e-027; // Atomic weight of carbon, kg
theta_D = (h/k)*c*(3*rho/(4*%pi*m))^(1/3); // Debye temperature for diamond, K
printf("\nThe Debye temperature for diamond = %4d K", theta_D);
// Result
// The Debye temperature for diamond = 1086 K
|
96bf7eee789bd8583746e9b0745a35f310969352 | 449d555969bfd7befe906877abab098c6e63a0e8 | /1427/CH1/EX1.2/1_2.sce | c6bc0b47afd29217cc51c58087ae6aa13ec4814d | [] | 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 | 624 | sce | 1_2.sce | //ques-1.2
//Calculating hardness in three samples
clc
A=168;//mass of MgCO3/L (in mg)
B1=820;//mass of Calcium Nitrate (in mg)
B2=2;//mass of Si/L (in mg)
C1=20;//mass of Potassium nitrate/500mL (in g)
C2=2;//mass of CaCO3/500mL (in g)
m1=(A/84)*100;//CaCO3 equivalent of A (in mg/L)
m2=(B1/164)*100;//CaCO3 equivalent of B1 (in mg/L)
m3=2*(1000/500)*1000*(100/100);//CaCO3 equivalent of C1 (in mg/L)
printf("The hardness of sample A, B and C in ppm are %d, %d and %d\n",m1,m2,m3);
//1 ppm = 0.07 grains/gallon
printf(" and hardness in grains/gallon are %d, %d and %d respectively.",m1*0.07,m2*0.07,m3*0.07);
|
e80111647e72f330ebb2ba4899d2a3f4ef7c4f32 | 449d555969bfd7befe906877abab098c6e63a0e8 | /851/CH9/EX9.1/Example9_1.sce | 0b3faa1a7a467c57c22a41b10d196a19cc40adc6 | [] | 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,291 | sce | Example9_1.sce | //clear//
//Caption:PN sequence generation
//Example9.1 and Figure9.1: Maximum-length sequence generator
//Program to generate Maximum Length Pseudo Noise Sequence
//Period of PN Sequence N = 7
clc;
//Assign Initial value for PN generator
x0= 1;
x1= 0;
x2 =0;
x3 =0;
N = input('Enter the period of the signal')
for i =1:N
x3 =x2;
x2 =x1;
x1 = x0;
x0 =xor(x1,x3);
disp(i,'The PN sequence at step')
x = [x1 x2 x3];
disp(x,'x=')
end
m = [7,8,9,10,11,12,13,17,19];
N = 2^m-1;
disp('Table 9.1 Range of PN Sequence lengths')
disp('_________________________________________________________')
disp('Length of shift register (m)')
disp(m)
disp('PN sequence Length (N)')
disp(N)
disp('_________________________________________________________')
//RESULTEnter the period of the signal 7
// The PN sequence at step 1.
// x= 1. 0. 0.
// The PN sequence at step 2.
// x= 1. 1. 0.
// The PN sequence at step 3.
// x= 1. 1. 1.
// The PN sequence at step 4.
// x= 0. 1. 1.
// The PN sequence at step 5.
// x= 1. 0. 1.
// The PN sequence at step 6.
// x= 0. 1. 0.
// The PN sequence at step 7.
// x= 0. 0. 1.
|
862fd2fb1b04632e5d5bad4f349b0ea82d292823 | 1bb72df9a084fe4f8c0ec39f778282eb52750801 | /test/SIC.prev.tst | 3d96d3ef16d4d2cc9016beca17ce03bd59623d92 | [
"Apache-2.0",
"LicenseRef-scancode-unknown-license-reference"
] | permissive | gfis/ramath | 498adfc7a6d353d4775b33020fdf992628e3fbff | b09b48639ddd4709ffb1c729e33f6a4b9ef676b5 | refs/heads/master | 2023-08-17T00:10:37.092379 | 2023-08-04T07:48:00 | 2023-08-04T07:48:00 | 30,116,803 | 2 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 968 | tst | SIC.prev.tst | a^3 + b^3 + c^3 - d^3; a - m^4 + 2*m*n^3; b - m^3*n - n^4; c - 2*m^3*n + n^4; d - m^4 - m*n^3
isolated Signature: /d.01
isolated variable: d with Coefficient 1
remaining RelationSet: a^3 + b^3 + c^3 - d^3; a - m^4 + 2*m*n^3; b - m^3*n - n^4; c - 2*m^3*n + n^4
substitute by Polynomial: - m^4 - m*n^3
isolated Signature: /c.01
isolated variable: c with Coefficient 1
remaining RelationSet: a^3 + b^3 + c^3 + m^12 + 3*m^9*n^3 + 3*m^6*n^6 + m^3*n^9; a - m^4 + 2*m*n^3; b - m^3*n - n^4
substitute by Polynomial: - 2*m^3*n + n^4
isolated Signature: /b.01
isolated variable: b with Coefficient 1
remaining RelationSet: a^3 + b^3 + m^12 - 5*m^9*n^3 + 15*m^6*n^6 - 5*m^3*n^9 + n^12; a - m^4 + 2*m*n^3
substitute by Polynomial: - m^3*n - n^4
isolated Signature: /a.01
isolated variable: a with Coefficient 1
remaining RelationSet: a^3 + m^12 - 6*m^9*n^3 + 12*m^6*n^6 - 8*m^3*n^9
substitute by Polynomial: - m^4 + 2*m*n^3
simplified and grouped:
+ 1*(0)
|
172cf71488d1b60e1e74021769b2e5773d35392e | 449d555969bfd7befe906877abab098c6e63a0e8 | /1583/CH5/EX5.3/HFAAGC_Ex_5_3.sce | 56bc553e4abfeb4ca44121ae1e93c2601865f1ca | [] | 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 | 807 | sce | HFAAGC_Ex_5_3.sce | clc
//Chapter 5:High Frequency Amplifiers and Automatic Gain Control
//example 5.3 page no 153
//given
gm=2*10^-3//transconductance
Cgs=5*10^-12//equivalent Miller's input capacitance
Cgd=1*10^-12//equivalent Miller's output capacitance
Cds=1*10^-12
rd=13*10^3
R=5*10^3//source resistance
RL=(6*10^3*13*10^3)/(6*10^3+13*10^3)//total load resistance
Av=-gm*RL//voltage gain
R_L=RL*rd/(RL+rd)
CT=Cgs+Cgd*(1+gm*R_L)//total capacitance
Co=Cds+(Cgd*(1+gm*R_L)/(gm*R_L))//output capacitance
w1=(R*CT)^-1//pole due to input circuit
w2=(RL*Co)^-1//pole due to output circuit
mprintf('the voltage gain is %f \n the total capacitance is %3.2e pF \n the output capacitance is %3.2e pF \n the pole due to input circuit is %3.2e rad/s \n the pole due to output circuit is %3.2e rad/s ',Av,CT,Co,w1,w2)
|
2ae187698a0196bfd8a9707341de6b80bc15eb6e | 449d555969bfd7befe906877abab098c6e63a0e8 | /1847/CH3/EX3.19/Ch03Ex19.sce | 0b5506c41c6150d5e2413d642d459facfa31f356 | [] | 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 | Ch03Ex19.sce | // Scilab Code Ex3.19:: Page-3.31 (2009)
clc; clear;
f = 150; // Distance between screen and slit, cm
a = 0.005; // Slit width, cm
b = 0.06; // Distance between slits, cm
lambda = 5500e-008; // Wavelength of light used, cm
// As half angular separation, theta1 = x1/f = lambda/(2*(a+b)), solving for x1
x1 = f*lambda/(2*(a+b)); // Distance between central maxima and first minima, cm
delta_theta = lambda/(2*(a+b)); // Angular separation between two consecutive minima, radians
printf("\nThe distance between central maxima and first minima = %4.2e cm", x1);
printf("\nThe angular separation between two consecutive minima = %3.1e radians", delta_theta);
// Result
// The distance between central maxima and first minima = 6.35e-002 cm
// The angular separation between two consecutive minima = 4.2e-004 radians
|
c36fc80455fac47d80a4d13aa7819207640a014a | 449d555969bfd7befe906877abab098c6e63a0e8 | /1445/CH2/EX2.30/Ex2_30.sce | ebe06388babff13100d603f8117058210d2e4d1d | [] | 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,277 | sce | Ex2_30.sce | //CHAPTER 2- STEADY-STATE ANALYSIS OF SINGLE-PHASE A.C. CIRCUIT
//Example 30 // read it as example 29 in the book on page 2.83
clc;
disp("CHAPTER 2");
disp("EXAMPLE 30");
//VARIABLE INITIALIZATION
f=50; //Hz
rms=20; //in Amp
t1=0.0025; //in sec time to find amplitude
t2=0.0125; //in sec, to find amp after passing through +ve maximum
i3=14.14; //in Amps, to find time when will it occur after passing through +ve maxima
//SOLUTION
//i=Isin(wt)
//solution (a)
w=2*%pi*f;
Im=rms*sqrt(2);
disp(sprintf("The equation would be i=%f. sin(%f.t)", Im,w));
t0=(asin(1)/w); //time to reach maxima in +ve direction
i=Im*sin(w*t1);
disp("SOLUTION (a)");
disp(sprintf("The amplitude at time %f sec is %f Amp", t1,i));
//solution (b)
tx=t0+t2;
i2=Im*sin(w*tx);
disp("SOLUTION (b)");
disp(sprintf("The amplitude at time %f sec is %f Amp", t2,i2));
//solution (c)
ty=(asin(i3/Im))/w;
t3=t0-ty; //since ty is the time starting from 0, the origin needs to be shifted to maxima
disp("SOLUTION (c)");
disp(sprintf("The amplitude of %f Amp would be reached in %f Sec", i3,t3));
disp(" ");
//
//END
|
5472f60c4bd5cc756a3e890213c92b2b990a60d6 | d0efa9f4759b46e22ac9687b2871bb3464002002 | /example9.sce | b6c8e90bb2001354dd9eb47f24587eb17fbd0b06 | [] | no_license | Adithya-Shetty100/Scilab--Linear-Algebra | c0198c7dd3a4f599b88904b5d7554589aaa5e995 | ed63e672f56b8b4f1bff7f33e50352db3e8568fe | refs/heads/main | 2023-04-19T12:41:56.959465 | 2021-05-11T08:46:41 | 2021-05-11T08:46:41 | 366,313,853 | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 278 | sce | example9.sce | clear;
close;
clc;
A=[1 0 1;1 0 0; 2 1 0];
disp('A=',A);
[m,n]=size(A);
for k=1:n
V(:,k)=A(:,k);
for j=1:k-1
R(j,k)=V(:,j)'*A(:,k);
V(:,k)=V(:,k)-R(j,k)*V(:,j);
end
R(k,k)=norm(V(:,k));
V(:,k)=V(:,k)/R(k,k);
end
disp('Q=',V);
|
670bd3a443516a202c2e937d77146c2da847a697 | 449d555969bfd7befe906877abab098c6e63a0e8 | /1760/CH4/EX4.9/EX4_9.sce | 13a39e0044ee1b3a50e32ef1c8d779bd15cb1cca | [] | 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 | 549 | sce | EX4_9.sce | //EXAMPLE 4-9 PG NO-232-233
X=[40 -8 -20;-8 18 -6;-20 -6 36];
Y=[24 -8 -20;0 18 -6;0 -6 36];
Z=[40 24 -20;-8 0 -6;-20 0 36];
U=[40 -8 24;-8 18 0;-20 -6 0]
I1=det(Y/X);
disp('CURRENT = '+string((I1))+' A');
I2=det(Z/X);
disp(' CURRENT = '+string(I2)+' A');
I3=det(U/X);
disp(' CURRENT is = '+string(I3)+' A');
IR3=I2;
disp(' CURRENT is = '+string(IR3)+' A');
IR4=0;
disp(' CURRENT is = '+string(IR4)+' A');
IR5=I1-I3;
disp(' CURRENT is = '+string(IR5)+' A');
IR6=I3;
disp(' CURRENT is = '+string(IR6)+' A');
|
1ecdb86e6c3619ea5425a497c35ab00b0397f923 | 449d555969bfd7befe906877abab098c6e63a0e8 | /284/CH7/EX7.7/ex_7.sce | cd53c30dee75229680dcdd99af7e730ef1672934 | [] | 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 | 579 | sce | ex_7.sce | // Chapter 7_The pn junction Diode
//Caption_Generation Recombination currents
//Ex_7//page 277
T=300
tau_o=5*10^-7
tau_po=5*10^-7
tau_no=5*10^-7
Na=10^16 //acceptor impurity
Nd=10^16 // donor impurity
ni=1.5*10^10 //intrinsic concentration
epsr=11.7
eps=epsr*8.85*10^-14
V=5 //V=Vbi+VR
e=1.6*10^-19
W=((2*eps/e)*((Na+Nd)/(Na*Nd))*(V))^0.5
Jgen=e*ni*10^9*W/(2*tau_o)
printf('The ideal reverse saturation current density was calculated in example 2 and it was 4.15810^-11 A/cm^2 and the generation current density calculated here is %f nA/cm^2',Jgen) |
78e74215cab6c06770014acbcb081346247d65f2 | 449d555969bfd7befe906877abab098c6e63a0e8 | /14/CH10/EX10.1/example_10_1.sce | 92bc760377178d406bba6de827f1e6aa85e4c7a7 | [] | 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,327 | sce | example_10_1.sce | //Chapter 10
//Example 10.1
//Page 253
//unloadedfault
//run clear command then execute dependancy file and then the source file
//dependency file is pucalc.sci
clc;
//Given
P_g1 = 50e6;
V_g1 = 13.8e3;
P_g2 = 25e6;
V_g2 = 13.8e3;
P_t = 75e6;
V_t_lt = 13.8e3;
V_t_ht = 69e3;
X11_g = 0.25;
X11_t = 0.10;
Vbase = 69e3;
Pbase = 75e6;
Vbase_lt = 13.8e3;
V_ht = 66e3;
X11_d_g1 = pucalc(X11_g,V_t_lt,Vbase_lt,Pbase,P_g1);
X11_d_g2 = pucalc(X11_g,V_t_lt,Vbase_lt,Pbase,P_g2);
E_g1 = V_ht / Vbase;
E_g2 = V_ht / Vbase;
disp('For Generator 1')
printf("Xd11 = %.3f per unit \n Eg1 = %.3f per unit \n",X11_d_g1,E_g1)
disp('For Generator 2')
printf("Xd11 = %.3f per unit \n Eg2 = %.3f per unit \n",X11_d_g2,E_g2)
X_g12 = (X11_d_g1 * X11_d_g2) / (X11_d_g1 + X11_d_g2);
I11 = E_g1 / (%i*(X_g12 + X11_t));
disp(I11,'Subtransient current in the short circuit in per unit is')
Vdt = I11 * (%i*X11_t);
disp(Vdt,'Voltage on the delta side of the transformer in per unit is')
I11_g1 = (E_g1 - Vdt) / (%i*X11_d_g1);
I11_g2 = (E_g2 - Vdt) / (%i*X11_d_g2);
disp('Subtransient current in generator 1 and 2 in per unit respectively')
disp(I11_g1)
disp(I11_g2)
Ibase = Pbase / (sqrt(3) * Vbase_lt);
I11_1 = abs(I11_g1) * Ibase;
I11_2 = abs(I11_g2) * Ibase;
disp('Subtransient current in generator 1 and 2 in Amperes respectively')
disp(I11_1)
disp(I11_2) |
d310c0f18a0d0ad5dee33fd2f514a12f72fd8e12 | 6e78a995dab5320eb292ea26847c9c890caee313 | /build/lexan.tst | 10328495fd8e65572cf57d83c1b82610b8d9add8 | [] | no_license | DanielJosefKrueger/Compiler2 | b414bbdf85643371b42ef5800f4921407724eb11 | d99dcd2c56e760ea0f79019173af17d8f0c5144e | refs/heads/master | 2020-03-18T22:41:37.102701 | 2018-06-06T14:10:50 | 2018-06-06T14:10:50 | 135,359,562 | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 130 | tst | lexan.tst | const
var
procedure
call
begin
end
if
fi
then
while
do
:=
=
!=
<
<=
>
>=
+
-
*
/
(
)
,
;
$
identifiertest
1233444
234.56
50000.23
|
1b30cf20700501384bcc540e415014891ce1aa57 | 449d555969bfd7befe906877abab098c6e63a0e8 | /2318/CH3/EX3.73/ex_3_73.sce | 97225632a0e67582099cca43be50f5e61a891f28 | [] | 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 | 161 | sce | ex_3_73.sce | //Example 3.73: inductance
clc;
clear;
close;
l1=4;//H
r1=1;//ohm
r2=1;//ohm
r3=2;//ohm
l4=2;//H
r4=2;//ohm
M=((r3*l1)-(r2*l4))/(r2+r3);//H
disp(M,"M is ,(H)=")
|
a6ec2772b5093970fec90c851c0b9faa62c1672e | 449d555969bfd7befe906877abab098c6e63a0e8 | /1760/CH2/EX2.32/EX2_32.sce | 813c0bfaa3cf9ac239366c97a239d73b4d0ba893 | [] | 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 | 371 | sce | EX2_32.sce | //EXAMPLE 2-32 PG NO-83
cos30=0.866;
sin30=0.5;
E1=141.42+%i*0;
E2=144.566+%i*11.976;
V=E1+141.42*(cos30 * sin30 );
disp('1) Voltage is in rectangular form = '+string(V)+' W');
Z=8+%i*6; //IMPEDANCE
I=V/Z;
disp('1) Current is in rectangular form = '+string(I)+' A');
P=I*V*0.743;
disp(' POWER is in rectangular form = '+string(P)+' W');
|
e0d50dca8c6ed8d5985c576a887b8174c3f9e1c2 | 449d555969bfd7befe906877abab098c6e63a0e8 | /1850/CH6/EX6.15/exa_6_15.sce | b1c07501e125829aba1c33708f26befd2f209077 | [] | 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 | exa_6_15.sce | // Exa 6.15
clc;
clear;
close;
// Given Data
format('v',7)
f= 2;// in kHz
f=f*10^3;// in Hz
C= 0.01;// in micro F
C=C*10^-6;// in F
R= 15;// in kohm
R=R*10^3;// in ohm
fie= -2*atand(2*%pi*f*R*C);
fie= ceil(fie);
disp(fie,"Phase shift in °");
disp("i.e. "+string(abs(fie))+"° (lagging)")
|
539d5efe4fe12f21a1538539972527c5633c78e6 | 449d555969bfd7befe906877abab098c6e63a0e8 | /1943/CH2/EX2.8/Ex2_8.sce | 2786b5b6bef9c07823da8a555fc2e26d059d50ab | [] | 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,514 | sce | Ex2_8.sce |
clc
clear
//Input data
Pl=5.6//Power load in MW
Hl=1.163//Heat load in MW
p1=40//Pressure in bar
T1=500+273//Temperature in K
p2=0.06//Pressure in bar
p3=2//Pressure in bar
CV=25//Calorific value in MJ/kg
n=88//Boiler efficiency in percent
T=6//Temperature rise in degree C
//Calculations
h1=3445.3//Enthalpy in kJ/kg
s1=7.0901//Entropy in kJ/kg.K
s2=s1//Entropy in kJ/kg.K
s3=s1//Entropy in kJ/kg.K
x2=(s2-1.5301)/5.5970//Dryness fraction
h2=2706.7//Enthalpy in kJ/kg
h26=2201.9//Difference in enthalpy in kJ/kg
w=(Hl*10^3)/h26//Rate of steam extraction in kg/h
x3=(s1-0.52)/7.815//Dryness fraction
h3=(149.79+x3*2416)//Enthalpy in kJ/kg
h4=149.79//Enthalpy in kJ/kg
ws=((Pl*10^3+(w*(h2-h3)))/((h1-h2)+(h2-h3)))//Steam generation capacity in kg/s
ws1=(ws*3600)/1000//Steam generation capacity in t/h
h7=(504.7+(1.061*10^-3*(p1-p3)*100))//Enthalpy in kJ/kg
h5=(149.79+(1.006*100*p1*10^-3))//Enthalpy in kJ/kg
Q1=(((ws-w)*(h1-h5))+(w*(h1-h7)))//Heat input in kW
wf=((Q1/1000)/((n/100)*CV))*(3600/1000)//Fuel burning rate in t/h
Q2=((ws-w)*(h3-h4))//Heat rejected to the condensor in kW
wc=(Q2/(4.187*T))/1000//Rate of flow of cooling water in m^3/s
//Output
printf('(a) the steam generation capacity of the bolier is %3.2f t/h \n (b) the heat input to the boiler is %3.1f kW \n (c) the fuel burning rate of the bolier is %3.3f t/h \n (d) the heat rejected to the condensor is %3.0f kW \n (e) the rate of flow of cooling water in the condensor is %3.3f m^3/s',ws1,Q1,wf,Q2,wc)
|
88fc1aba4302f7c783f7e9e7d84454211f4d9026 | 449d555969bfd7befe906877abab098c6e63a0e8 | /1226/CH3/EX3.7/EX3_7.sce | 5145aae0298c1ea5a895057e7cc7d5ed1d5fd00f | [] | 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 | EX3_7.sce | clc;funcprot(0);//EXAMPLE 3.7
// Initialisation of Variables
etaotto=0.6;............//Efficiency of otto engine
ga=1.5;.................//Ratio of specific heats
//Calculations
r=(1/(1-etaotto))^(1/(ga-1));................//Compression ratio
disp(r,"The compression ratio of the engine is:")
|
12bfe13d278198733fb714b1cc5161a54fc445af | 449d555969bfd7befe906877abab098c6e63a0e8 | /1358/CH3/EX3.6/Example36.sce | 455eae350b2bf5da8efa5fb8e46b37c23adf5555 | [] | 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,189 | sce | Example36.sce | // Display mode
mode(0);
// Display warning for floating point exception
ieee(1);
clear;
clc;
disp("Turbomachinery Design and Theory,Rama S. R. Gorla and Aijaz A. Khan, Chapter 3, Example 6")
disp("Refering Figure")
disp("Hydraulic Efficiency etah = Power output/Energy available in the jet = P/(0.5mC1^2)")
disp("At entry to nozzle")
H = 610-46//in m
Cv = 0.98;
g = 9.81;
disp("Using nozzle velocity coefficient C1")
C1 = Cv * (2*g*H)^0.5
disp("Now W/m = U1Cw1 - U2Cw2 =U {(U + V1)-[U-V2cos(180 -alpha)]}= U[(C1 - U)(1 - k cos (alpha))] where V2 = kV1")
disp("Therefore W/m")
Wm = 0.46*C1*(C1-0.46*C1)*(1-0.99*cos(165*%pi/180))
etah = Wm/(0.5*103*103)
disp("Actual hydraulic efficiency")
etaha = 0.91*etah
disp("Wheel bucket speed")
s = 0.46*C1
disp("Wheel rotational speed N")
N = s*60/(0.445*2*%pi)
disp("Actual hydraulic efficiency")
disp("¼ Actual power/energy in the jet = (1260 * 10^3)/(0.5mC1^2)")
disp("Therefore")
m = 1260*1000/(0.882*0.5*103*103)
disp("For one nozzle,m")
mone = m/2
disp("For nozzle diameter, using continuity equation, m")
disp("m = rho*C1*A = rho*C1*pi*d^2/4")
disp("Hence, d in mm")
d = (mone*4/(%pi*103*1000))^0.5 *1000
|
ad4a8dbbd7263fbe5192ddb13816b615e23b1403 | 449d555969bfd7befe906877abab098c6e63a0e8 | /1226/CH3/EX3.24/EX3_24.sce | 82d7eb9aedaad437a8610d3f6abb8964b34bea89 | [] | 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 | 489 | sce | EX3_24.sce | clc;funcprot(0);//EXAMPLE 3.24
// Initialisation of Variables
r=14;......................//Compression ratio
Beta=1.4;................//Explosion ratio
co=6;..................//Cut off percentage
ga=1.4;.................//Ratio of specific heats
//Calculation
rho=((co/100)*(r-1))+1;...............//Cut off ratio
etadual=1-[(1/(r^(ga-1)))*((Beta*(rho^ga))-1)*(1/((Beta-1)+(Beta*ga*(rho-1))))];............//Efficiency of dual cycle
disp(etadual*100,"Efficiency of dual cycle:")
|
dc69a7d8a0e42d5abf3200e2bc25d6c7d83c7a62 | 449d555969bfd7befe906877abab098c6e63a0e8 | /409/CH25/EX25.1/Example25_1.sce | dac0fae14161d1334d66a65d09e533a036c5099a | [] | 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 | 834 | sce | Example25_1.sce | clear ;
clc;
// Example 25.1
printf('Example 25.1\n\n');
//page no. 766
// Solution Fig. E25.1
// Given
// C(s) + O2(g) --> CO2(g) (A)
// CO(g) + (1/2)(O2)(g) --> CO2 (g) (B)
Qa = -393.51 ;// Heat of reaction of reaction (a) - [kJ/g mol C]
Qb = -282.99 ;// Heat of reaction of reaction (b) - [kJ/g mol CO]
del_Ha = Qa ;// Change in enthalpy of reaction A - [kJ/g mol C]
del_Hb = Qb ;// Change in enthalpy of reaction B - [kJ/g mol CO]
// According to Hess's Law , subtract reaction (B) from reaction (A) , subtract corresponding del_H's to get enthalpy of formation of reaction (C)- C(s) + (1/2)*O2 --> CO(g) , therefore
del_Hfc = del_Ha - del_Hb ;// Standard heat of formation of CO - [kJ/g mol C]
printf('Standard heat of formation of CO is %.2f kJ/g mol C.',del_Hfc) ; |
784506de65ddc5bd3bdc72dcdbaf21b3d2185934 | 07bf6db3fade722ce6caf9bb9044a8de97fdec55 | /scripts/dag/tsort.sce | 2538a6f9382eae4a2944562e95e7f7f58fc1fcd8 | [
"BSD-2-Clause"
] | permissive | rfabbri/minus | 8cce65a53e4afe617843aa8a8e31ee5dcee28cb2 | 21a847fd66c0d1ecb40962bce9c9b2c1a6df02fa | refs/heads/master | 2023-07-19T15:49:05.920669 | 2023-06-23T00:13:53 | 2023-06-23T00:13:53 | 172,530,430 | 39 | 8 | NOASSERTION | 2022-04-26T14:13:13 | 2019-02-25T15:19:04 | C++ | UTF-8 | Scilab | false | false | 269 | sce | tsort.sce | // traverses the SLP gate graph constructed in dag.sce
// outputs vectorized form of the operations.
// 1- traverse graph and build all leaf nodes / without any incoming edges
// insert these nodes in Q+ and Q- stacks
exec tsort_ini.sce;
// exec tsort_queue.sce;
|
883f585512fb920a6f64c7f388cecc6f7bbf7988 | 4a1effb7ec08302914dbd9c5e560c61936c1bb99 | /Project 2/Experiments/C45-C/results/C45-C.abalone-10-1tra/result9.tst | d4ae0f7f2d6e6058457fdb4c6846d382e27f596b | [] | no_license | nickgreenquist/Intro_To_Intelligent_Systems | 964cad20de7099b8e5808ddee199e3e3343cf7d5 | 7ad43577b3cbbc0b620740205a14c406d96a2517 | refs/heads/master | 2021-01-20T13:23:23.931062 | 2017-05-04T20:08:05 | 2017-05-04T20:08:05 | 90,484,366 | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 2,598 | tst | result9.tst | @relation abalone
@attribute Sex{M,F,I}
@attribute Length real[0.075,0.815]
@attribute Diameter real[0.055,0.65]
@attribute Height real[0.0,1.13]
@attribute Whole_weight real[0.002,2.8255]
@attribute Shucked_weight real[0.001,1.488]
@attribute Viscera_weight real[5.0E-4,0.76]
@attribute Shell_weight real[0.0015,1.005]
@attribute Rings{15,7,9,10,8,20,16,19,14,11,12,18,13,5,4,6,21,17,22,1,3,26,23,29,2,27,25,24}
@inputs Sex,Length,Diameter,Height,Whole_weight,Shucked_weight,Viscera_weight,Shell_weight
@outputs Rings
@data
10 8
7 7
19 10
16 10
4 5
10 11
14 12
10 9
15 10
7 8
7 7
7 6
10 13
10 11
10 12
15 11
7 8
8 10
5 4
13 13
10 16
9 8
18 19
8 7
16 13
15 12
14 13
16 11
16 10
10 10
8 12
19 16
13 8
14 8
9 12
13 20
16 16
11 9
9 7
6 5
5 6
5 4
17 11
13 10
11 11
15 20
12 10
16 8
3 5
13 8
17 15
13 10
13 9
11 9
20 11
14 8
14 10
9 7
12 10
12 8
9 7
7 7
9 7
11 8
6 7
13 19
22 17
11 9
11 13
15 17
14 19
10 8
9 15
13 12
9 6
9 8
15 12
8 12
9 9
9 17
11 11
10 9
17 15
9 11
7 7
8 7
9 9
8 12
8 14
7 6
7 9
8 11
11 8
11 7
9 11
10 10
6 9
8 11
4 5
7 4
6 7
7 7
6 15
7 9
7 8
8 8
9 9
8 7
8 9
9 8
9 9
10 9
12 20
9 11
12 9
6 7
6 7
5 7
7 7
9 7
8 7
8 7
8 8
8 7
8 8
7 7
9 8
10 14
10 10
10 9
11 9
12 10
10 10
11 9
9 9
11 10
10 9
10 9
13 11
8 8
6 8
9 8
9 8
8 8
9 10
9 10
10 9
8 10
10 12
12 9
11 11
13 12
6 6
7 7
7 7
9 10
8 15
7 8
9 9
9 9
10 10
9 11
9 9
8 11
10 12
9 9
8 9
10 10
10 11
11 11
11 15
11 10
9 10
11 9
14 9
12 10
11 9
10 11
11 11
11 11
12 11
12 11
6 7
10 9
11 14
9 10
10 11
11 10
7 10
11 11
9 11
12 10
12 9
6 5
7 6
7 6
10 8
9 10
9 8
9 9
8 10
7 14
12 11
10 13
10 6
13 9
7 7
10 11
7 10
6 7
8 13
12 9
10 12
10 7
5 7
27 13
7 11
11 11
14 10
14 15
11 9
15 16
9 8
17 11
20 13
13 12
8 9
11 8
12 7
11 8
10 7
17 9
12 10
18 8
6 6
14 19
23 13
14 12
9 9
13 13
11 11
6 7
7 8
9 8
10 8
6 8
8 8
8 10
6 7
7 11
9 10
9 9
13 13
10 11
9 8
11 11
9 8
11 9
13 10
8 7
7 10
8 10
10 9
9 10
10 9
9 9
10 10
11 10
5 5
5 6
9 8
9 9
10 8
9 9
8 10
11 12
7 8
9 9
8 9
8 8
8 7
10 10
9 12
13 10
11 11
12 10
13 11
9 12
12 10
8 15
7 8
8 11
11 10
7 7
8 6
9 7
8 8
10 11
10 9
11 15
9 11
10 6
11 9
8 11
5 5
5 9
10 9
11 10
10 12
21 11
13 14
18 17
8 8
19 13
11 8
14 7
12 7
11 17
15 10
12 11
17 11
10 6
12 8
8 7
12 12
13 12
11 8
12 8
16 13
18 9
9 7
4 4
7 9
7 6
10 12
10 12
9 10
4 4
4 6
6 7
8 8
9 8
9 9
9 9
9 10
10 9
8 9
9 9
12 9
5 6
8 8
8 6
7 10
6 6
9 11
8 9
10 9
10 8
10 10
11 9
11 9
10 13
9 8
10 11
6 7
8 8
9 9
10 10
7 6
6 13
8 6
8 8
9 10
10 10
10 9
11 11
6 7
14 10
9 9
15 15
15 11
7 6
12 14
13 10
12 15
5 7
11 11
10 13
6 6
8 11
8 10
6 16
6 6
8 9
11 10
8 8
7 7
11 10
10 9
9 10
10 9
8 8
6 6
7 7
7 8
8 10
9 11
9 9
11 13
4 5
10 14
11 10
10 17
11 10
6 6
8 10
8 6
|
4e18cdcb50cea89874d5a6e98b1dfbf601a68a5c | b829a470efb851fdd8700559c2092711adaa42e0 | /Data/OVI-CV-03-Facenet/CV-Groups/cv-group-114528472700/OVI-Test/cv-group-114528472700-run-04.tst | 825beb3caa5ed835622f8ca160312a7338358609 | [] | no_license | achbogga/FaceRecognition | 6f9d50bd1f32f2eb7f23c7ae56f9e7b225d32325 | 165ebc7658228d2cceaee4619e129e248665c49a | refs/heads/master | 2021-07-04T21:47:57.252016 | 2017-08-01T18:53:12 | 2017-08-01T18:53:12 | 96,568,452 | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 504 | tst | cv-group-114528472700-run-04.tst | Ahmad\Ahmad_012.jpg
Ahmad\Ahmad_001.jpg
Sima\Sima_001.jpg
Sima\Sima_004.jpg
SungChun\SungChun_011.jpg
SungChun\SungChun_007.jpg
Kiran\Kiran_010.jpg
Kiran\Kiran_013.jpg
Allison\Allison_005.jpg
Allison\Allison_013.jpg
Amit\Amit_001.jpg
Amit\Amit_007.jpg
Gang\Gang_009.jpg
Gang\Gang_010.jpg
Ethan\Ethan_004.jpg
Ethan\Ethan_008.jpg
Rob\Rob_006.jpg
Rob\Rob_002.jpg
Nara\Nara_011.jpg
Nara\Nara_005.jpg
Weihong\Weihong_006.jpg
Weihong\Weihong_003.jpg
Dave\Dave_007.jpg
Dave\Dave_003.jpg
|
25f50d88bc06a452d0d6375a700277b7d94b20c6 | 449d555969bfd7befe906877abab098c6e63a0e8 | /2150/CH6/EX6.12/ex6_12.sce | fe450d0544974a588dd01ef8df96063299d688c0 | [] | 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 | 925 | sce | ex6_12.sce | // Exa 6.12
clc;
clear;
close;
// Given data
V_DD= 20;// in V
I_DSS= 9;// in mA
V_BB= -10;// in V
R_S= 1.5;// in kΩ
R_D= 1.8;// in kΩ
V_P= -3;// in V
V_G=0;
// V_S= I_D*R_S+V_BB;
// V_GS= V_G-V_S or
// V_GS= V_G-(I_D*R_S+V_BB)
// I_D= I_DSS*(1-V_GS/V_P)^2 or
// I_D^2*R_S^2 + I_D*[2*R_S*V_BB+2*V_P*R_S-V_P^2/I_DSS]+[V_P^2+V_BB^2+2*V_BB*V_P]
root= [R_S^2 2*R_S*V_BB+2*V_P*R_S-V_P^2/I_DSS V_P^2+V_BB^2+2*V_BB*V_P]
I_D= roots(root);// in mA
I_D= I_D(2);// discarding maximum value as it will be less than I_DSS
I_DQ= I_D;// in mA
disp(I_DQ,"The value of I_DQ in mA is : ")
V_GS= V_G-(I_D*R_S+V_BB);// in V
V_GSQ= V_GS;// in V
disp(V_GSQ,"The value of V_GSQ in volts is : ")
V_DS= V_DD-I_D*(R_D+R_S)-V_BB;// in V
disp(V_DS,"The value of V_DS in volts is : ")
V_S= I_D*R_S+V_BB;// in V
disp(V_S,"The value of V_S in volts is : ");
V_D= V_S+V_DS;// in V
disp(V_D,"The value of V_D in volts is : ")
|
504e4e7ee2ffc580d1a1d33384529b778e614ec7 | 449d555969bfd7befe906877abab098c6e63a0e8 | /1910/CH7/EX7.4/Chapter74.sce | 67932d93f737365536ff215c34e6e41be38e089d | [] | 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,553 | sce | Chapter74.sce | // Display mode
mode(0);
// Display warning for floating point exception
ieee(1);
clear;
clc;
disp("Introduction to heat transfer by S.K.Som, Chapter 7, Example 4")
//Castor oil at temprature,Tinf=36°C flows over a heated plate of length,L=6m and breadth,B=1m at velocity,Uinf=0.06m/s
Tinf=36;
L=6;
B=1;
Uinf=0.06;
//For a surface temprature at Tw=96°C
Tw=96;
//The properties at film temprature 66°C conductivity(k=0.21W/(m*K)),kinematic viscosity(nu=6*10^-5m^2/s),Thermal diffusivity(alpha=7.22*10^-8 m^2/s)
nu=6*10^-5;
k=0.21;
alpha=7.22*10^-8;
//ReL is reynolds number
disp("(a)Reynolds number is")
ReL=(Uinf*L)/nu
//Therefore the boundary layer is laminar over the entire plate.
//delta is the boundary layer thickness
disp("The boundary layer thickness in m is")
delta=(5*L)/(ReL)^0.5
//Pr is prandtl number.
disp("Prandtl no. is")
Pr=nu/alpha
//deltaT is thermal boundary layer thickness
disp("The thermal boundary layer thickness in m is")
deltaT=delta/(Pr^(1/3))//NOTE:Answer in the book is incorrect(calculation mistake)
//NuL is the nusselt number
disp("(b)Since the prandtl number is high So Nusselt no. is")
NuL=0.339*(ReL)^0.5*Pr^(1/3)
//Heat flux is given by hL=(k/L)*NuL
disp("Heat flux in W/(m^2*K) is")
hL=(k/L)*NuL
//hbarL is the average heat flux over length L
disp("hbarL in W/(m^2*K) is")
hbarL=2*hL
//The rate of heat transfer is Q=h*A*(Tinf-Tw)
//Area(A)=L*B
A=L*B;
disp("(c)The rate of heat transfer in W is")
Q=hbarL*A*(Tw-Tinf)
|
c1aa807c291adeb37f87023d89c7bd98aef925de | 08c90caa29269a38d527abf8c7c89fd4a525b668 | /lab1.sce | 5ade3b4206d0d4caafe24f903d16297ed496cada | [] | no_license | aksini/scilab_labs | fcd2e363159303298c674c58e3f750f6bff6c51a | aa0bc9181f452c7c011c466a5934a709d1f00bf4 | refs/heads/master | 2021-04-24T00:30:31.056852 | 2020-06-14T15:26:07 | 2020-06-14T15:26:07 | 250,044,576 | 0 | 0 | null | null | null | null | UTF-8 | Scilab | false | false | 4,479 | sce | lab1.sce | not_pas = 0;
l_1 = [];
l_2 = [];
l_3 = [];
max_l_1 = 0;
max_l_2 = 0;
max_l_3 = 0;
min_l_1 = 0;
min_l_2 = 0;
min_l_3 = 0;
max_flag = 0;
min_flag = 0;
mod_flag = 0;
mod_l_1 = [];
mod_l_2 = [];
mod_l_3 = [];
n = 20;
min_xopt = [];
max_xopt = [];
for lambd_1 = 0:1:n
for lambd_2 = 0:1:n
for lambd_3 = 0:1:n
c = [38; -60; -1; -4; -8];
A = [lambd_1 4 2 0 -12
0.4 3 -4.2 2 -lambd_3];
Aeq = [0 lambd_2 19 -7 10
2.1 13 -20 6 0];
b = [86; 34];
beq = [130; 18];
lb = [0; 0; 0; 0; 0];
[xopt,fopt, exitflag, iter, yopt] = karmarkar(Aeq, beq, c, [], [], [], [],[], A, b, lb);
if (lambd_1 == 0)
if (lambd_2 == 0)
if (lambd_3 == 0)
max_flag = fopt;
max_l_1 = lambd_1;
max_l_2 = lambd_2;
max_l_3 = lambd_3;
max_xopt = xopt;
min_flag = fopt;
min_l_1 = lambd_1;
min_l_2 = lambd_2;
min_l_3 = lambd_3;
min_xopt = xopt;
end
end
end
if exitflag <> 1
not_pas = not_pas + 1;
l_1(not_pas) = lambd_1;
l_2(not_pas) = lambd_2;
l_3(not_pas) = lambd_3;
end
if exitflag == 1
if max_flag < fopt
then
max_flag = fopt;
max_l_1 = lambd_1;
max_l_2 = lambd_2;
max_l_3 = lambd_3;
max_xopt = xopt;
end
if min_flag > fopt
then
min_flag = fopt;
min_l_1 = lambd_1;
min_l_2 = lambd_2;
min_l_3 = lambd_3;
min_xopt = xopt;
end
end
if pmodulo(fopt, 1) == 0
then
mod_flag = mod_flag +1;
mod_l_1(mod_flag) = lambd_1;
mod_l_2(mod_flag) = lambd_2;
mod_l_3(mod_flag) = lambd_3;
end
end
end
end
printf('Набор параметров, при которых функция не имеет решения:\n');
if not_pas > 0
then
for i = 1:1:not_pas
printf(' ----------------------------------------\n');
printf(' %f\t', l_1(i));
printf('%f\t', l_2(i));
printf('%f\t', l_3(i));
printf('\n');
end
printf(' ----------------------------------------\n');
else
printf('not search.\n');
end
printf('\nПри минимальном значении функции %f ', min_flag);
printf('значения параметров:\n');
printf('lambda_1 = %f, ', min_l_1);
printf('lambda_2 = %f, ', min_l_2);
printf('lambda_3 = %f.\n', min_l_3);
for i = 1:1:5
printf('Значения X_%f = %f.\n', i, min_xopt(i));
end
printf('\nПри максимальном значении функции %f ', max_flag);
printf('значения параметров:\n');
printf('lambda_1 = %f, ', max_l_1);
printf('lambda_2 = %f, ', max_l_2);
printf('lambda_3 = %f.\n', max_l_3);
for i = 1:1:5
printf('Значения X_%f = %f.\n', i, max_xopt(i));
end
if mod_flag > 0
then
if mod_flag == 1
then
printf('lambda_1 = %f,\n', mod_l_1(1));
printf('lambda_1 = %f,\n', mod_l_2(1));
printf('lambda_1 = %f.\n', mod_l_3(1));
printf('\n');
else
printf('\nПараметры, при которых функция возвращает целочисленные значения: ');
printf('\n');
for i = 1:1:mod_flag
printf(' -------------------------------------------------------\n');
printf('\t%f\t', mod_l_1(i));
printf('%f\t', mod_l_2(i));
printf('%f\t', mod_l_3(i));
printf('\n');
end
printf(' -------------------------------------------------------\n');
end
else
printf('\nЦелочисленных решений нет');
end
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.