395
428
procedure SpinEdit01pourcentClick(Sender: TObject; Button: TUDBtnType);
397
430
procedure SpinEdit1pourcentClick(Sender: TObject; Button: TUDBtnType);
431
procedure StringGridanionssimplesCompareCells(Sender: TObject; ACol, ARow,
432
BCol, BRow: Integer; var Result: integer);
398
433
procedure StringGridanionssimplesmousedown(Sender: TObject;
399
434
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
435
procedure StringGridanionssimples_CompareCells(Sender: TObject; ACol, ARow,
436
BCol, BRow: Integer; var Result: integer);
400
437
procedure StringGridanionssimples_mousedown(Sender: TObject;
401
438
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
439
procedure StringGridaqueuxabCompareCells(Sender: TObject; ACol, ARow, BCol,
440
BRow: Integer; var Result: integer);
402
442
procedure StringGridaqueuxabmousedown(Sender: TObject; Button: TMouseButton;
403
443
Shift: TShiftState; X, Y: Integer);
444
procedure StringGridaqueuxab_CompareCells(Sender: TObject; ACol, ARow,
445
BCol, BRow: Integer; var Result: integer);
404
446
procedure StringGridaqueuxab_mousedown(Sender: TObject; Button: TMouseButton;
405
447
Shift: TShiftState; X, Y: Integer);
448
procedure StringGridaqueuxcomplexesCompareCells(Sender: TObject; ACol,
449
ARow, BCol, BRow: Integer; var Result: integer);
406
450
procedure StringGridaqueuxcomplexesmousedown(Sender: TObject;
407
451
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
452
procedure StringGridaqueuxcomplexes_CompareCells(Sender: TObject; ACol,
453
ARow, BCol, BRow: Integer; var Result: integer);
408
454
procedure StringGridaqueuxcomplexes_mousedown(Sender: TObject;
409
455
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
456
procedure StringGridcationssimplesCompareCells(Sender: TObject; ACol, ARow,
457
BCol, BRow: Integer; var Result: integer);
410
458
procedure StringGridcationssimplesmousedown(Sender: TObject;
411
459
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
460
procedure StringGridcationssimples_CompareCells(Sender: TObject; ACol,
461
ARow, BCol, BRow: Integer; var Result: integer);
412
462
procedure StringGridcationssimples_mousedown(Sender: TObject;
413
463
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
414
464
procedure stringgridgazeuxmousedown(Sender: TObject; Button: TMouseButton;
415
465
Shift: TShiftState; X, Y: Integer);
416
466
procedure stringgridgazeux_mousedown(Sender: TObject; Button: TMouseButton;
417
467
Shift: TShiftState; X, Y: Integer);
468
procedure StringGridIonsCompareCells(Sender: TObject; ACol, ARow, BCol,
469
BRow: Integer; var Result: integer);
418
470
procedure StringGridIonsmousedown(Sender: TObject; Button: TMouseButton;
419
471
Shift: TShiftState; X, Y: Integer);
472
procedure StringGridIons_CompareCells(Sender: TObject; ACol, ARow, BCol,
473
BRow: Integer; var Result: integer);
420
474
procedure StringGridIons_mousedown(Sender: TObject; Button: TMouseButton;
421
475
Shift: TShiftState; X, Y: Integer);
476
procedure stringgridminerauxCompareCells(Sender: TObject; ACol, ARow, BCol,
477
BRow: Integer; var Result: integer);
422
478
procedure stringgridminerauxmousedown(Sender: TObject; Button: TMouseButton;
423
479
Shift: TShiftState; X, Y: Integer);
480
procedure stringgridmineraux_CompareCells(Sender: TObject; ACol, ARow,
481
BCol, BRow: Integer; var Result: integer);
424
482
procedure stringgridmineraux_mousedown(Sender: TObject; Button: TMouseButton;
425
483
Shift: TShiftState; X, Y: Integer);
484
procedure StringGridMoleculesCompareCells(Sender: TObject; ACol, ARow,
485
BCol, BRow: Integer; var Result: integer);
426
486
procedure StringGridMoleculesmousedown(Sender: TObject; Button: TMouseButton;
427
487
Shift: TShiftState; X, Y: Integer);
488
procedure StringGridMolecules_CompareCells(Sender: TObject; ACol, ARow,
489
BCol, BRow: Integer; var Result: integer);
428
490
procedure StringGridMolecules_mousedown(Sender: TObject;
429
491
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
430
492
procedure StringGridordonneesDrawCell(Sender: TObject; aCol, aRow: Integer;
431
493
aRect: TRect; aState: TGridDrawState);
432
494
procedure StringGridordonneesmousedown(Sender: TObject; Button: TMouseButton;
433
495
Shift: TShiftState; X, Y: Integer);
496
procedure StringGridorganiques_acideCompareCells(Sender: TObject; ACol,
497
ARow, BCol, BRow: Integer; var Result: integer);
434
500
procedure StringGridorganiques_acidemousedown(Sender: TObject;
435
501
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
502
procedure StringGridorganiques_acide_CompareCells(Sender: TObject; ACol,
503
ARow, BCol, BRow: Integer; var Result: integer);
436
504
procedure StringGridorganiques_acide_mousedown(Sender: TObject;
437
505
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
506
procedure StringGridorganiques_alcCompareCells(Sender: TObject; ACol, ARow,
507
BCol, BRow: Integer; var Result: integer);
438
508
procedure StringGridorganiques_alcmousedown(Sender: TObject;
439
509
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
510
procedure StringGridorganiques_alcoolCompareCells(Sender: TObject; ACol,
511
ARow, BCol, BRow: Integer; var Result: integer);
440
512
procedure StringGridorganiques_alcoolmousedown(Sender: TObject;
441
513
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
514
procedure StringGridorganiques_alcool_CompareCells(Sender: TObject; ACol,
515
ARow, BCol, BRow: Integer; var Result: integer);
442
516
procedure StringGridorganiques_alcool_mousedown(Sender: TObject;
443
517
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
518
procedure StringGridorganiques_alc_CompareCells(Sender: TObject; ACol,
519
ARow, BCol, BRow: Integer; var Result: integer);
444
520
procedure StringGridorganiques_alc_mousedown(Sender: TObject;
445
521
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
522
procedure StringGridorganiques_aldehyd_cetoneCompareCells(Sender: TObject;
523
ACol, ARow, BCol, BRow: Integer; var Result: integer);
446
524
procedure StringGridorganiques_aldehyd_cetonemousedown(Sender: TObject;
447
525
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
526
procedure StringGridorganiques_aldehyd_cetone_CompareCells(Sender: TObject;
527
ACol, ARow, BCol, BRow: Integer; var Result: integer);
448
528
procedure StringGridorganiques_aldehyd_cetone_mousedown(Sender: TObject;
449
529
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
530
procedure StringGridorganiques_amid_aminCompareCells(Sender: TObject; ACol,
531
ARow, BCol, BRow: Integer; var Result: integer);
450
532
procedure StringGridorganiques_amid_aminmousedown(Sender: TObject;
451
533
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
534
procedure StringGridorganiques_amid_amin_CompareCells(Sender: TObject;
535
ACol, ARow, BCol, BRow: Integer; var Result: integer);
452
536
procedure StringGridorganiques_amid_amin_mousedown(Sender: TObject;
453
537
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
538
procedure StringGridorganiques_aminoacideCompareCells(Sender: TObject;
539
ACol, ARow, BCol, BRow: Integer; var Result: integer);
454
540
procedure StringGridorganiques_aminoacidemousedown(Sender: TObject;
455
541
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
542
procedure StringGridorganiques_aminoacide_CompareCells(Sender: TObject;
543
ACol, ARow, BCol, BRow: Integer; var Result: integer);
456
544
procedure StringGridorganiques_aminoacide_mousedown(Sender: TObject;
457
545
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
546
procedure StringGridorganiques_benzeneCompareCells(Sender: TObject; ACol,
547
ARow, BCol, BRow: Integer; var Result: integer);
458
548
procedure StringGridorganiques_benzenemousedown(Sender: TObject;
459
549
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
550
procedure StringGridorganiques_benzene_CompareCells(Sender: TObject; ACol,
551
ARow, BCol, BRow: Integer; var Result: integer);
460
552
procedure StringGridorganiques_benzene_mousedown(Sender: TObject;
461
553
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
554
procedure StringGridorganiques_complexeCompareCells(Sender: TObject; ACol,
555
ARow, BCol, BRow: Integer; var Result: integer);
462
556
procedure StringGridorganiques_complexemousedown(Sender: TObject;
463
557
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
558
procedure StringGridorganiques_complexe_CompareCells(Sender: TObject; ACol,
559
ARow, BCol, BRow: Integer; var Result: integer);
464
560
procedure StringGridorganiques_complexe_mousedown(Sender: TObject;
465
561
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
466
562
procedure stringgridreactifs_bechermousedown(Sender: TObject;
467
563
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
468
564
procedure stringgridreactifs_burettemousedown(Sender: TObject;
469
565
Button: TMouseButton; Shift: TShiftState; X, Y: Integer);
566
procedure StringGridReactionsKeyPress(Sender: TObject; var Key: char);
470
567
procedure StringGridReactionsSetEditText(Sender: TObject; ACol,
471
568
ARow: Integer; const Value: string);
472
569
procedure TabSheetchoisirResize(Sender: TObject);
644
743
ordonnee_gauche_est_ph, ordonnee_droite_est_ph,abscisse_est_v:boolean;
645
744
largeur_bande_indic,abscisse_centre_bande_indic,ordonnee_centre_bande_indic:extended;
646
745
degrade_vertical,debut_translation,debut_elargissement:boolean;
746
Search:sysutils.TSearchRec;
747
ID_lang,nom_ini_file:string; PODirectory: String;
758
Function MyGetAppConfigDirUTF8: String;
759
{il est necessaire de modifier GetAppConfigDir car sur les systemes
760
windows renvoie local setting\application data au lieu de application data}
763
EnvVars: TStringList;
766
result:=systoutf8(SysUtils.GetAppConfigDir(false));
769
EnvVars := TStringList.Create;
771
for I := 0 to GetEnvironmentVariableCount - 1 do
772
EnvVars.Add(GetEnvironmentString(I));
773
result:=systoutf8(AppendPathDelim(EnvVars.Values['APPDATA'])+'dozzzaqueux\');
782
Function ExpandEnvironmentString(s: String): String;
789
bP := Pos('%', s) > 0;
790
bD := Pos('$', s) > 0;
791
If Not(bP Or bD) Then Exit; // Nichts zu konvertieren
792
sl := TStringList.Create;
794
For i := GetEnvironmentVariableCount - 1 DownTo 0 Do // Alle Variablen in eine Liste merken
796
s2 := GetEnvironmentStringUTF8(i);
797
If Length(s2) >= 2 Then
798
If s2[1] <> '=' Then // Bei Windows kommt sowas auch vor, daher wegoptimieren
803
Repeat // Durchlaufe so oft bis alle Env-Variablen aufgelöst sind
805
For i := sl.Count - 1 DownTo 0 Do
809
Result := StringReplace(Result, '%' + sl.Names[i] + '%', sl.ValueFromIndex[i], [rfReplaceAll, rfIgnoreCase]);
810
If Pos('%', Result) = 0 Then bP := False;
814
Result := StringReplace(Result, '$' + sl.Names[i], sl.ValueFromIndex[i], [rfReplaceAll]);
815
If Pos('$', Result) = 0 Then bD := False;
817
If Not(bP Or bD) Then Break;
819
If Not(bP Or bD) Then Break;
820
If SameText(s2, Result) Then Break; // % $ nicht konvertierbar, da im System nicht vorhanden
822
If k > sl.Count - 2 Then Break; // Max Durchläufe
831
Function MyGetMesDocumentsUTF8: String;
837
Reg := TRegistry.Create;
839
Reg.RootKey := HKEY_CURRENT_USER;
840
Reg.OpenKey('Software\Microsoft\Windows\CurrentVersion\'
841
+ 'Explorer\User Shell Folders\', False);
842
result:=ExpandEnvironmentString(Reg.ReadString('Personal'));
653
850
procedure HSV_RGB( H,S,V:extended; var R,G,B:integer);
654
851
var var_h,var_i,var_r,var_g,var_b,var_1,var_2,var_3:extended;
801
998
application.Terminate;
1001
procedure TForm1.MenuItemRaffineCSVClick(Sender: TObject);
1002
var f:textfile; ns,ligne,dede:string;
1006
savedialog1.FileName:='';
1007
savedialog1.InitialDir:=repertoire_dosage_perso;
1008
SaveDialog1.DefaultExt := rsCsv;
1009
SaveDialog1.Filter := rsTableurTexte2;
1011
if not(savedialog1.Execute) then exit else
1012
ns:=savedialog1.FileName;
1014
assignfile(f,utf8tosys(ns));
1018
application.MessageBox(pchar(rsImpossibleDe),
1019
pchar(rsMaisEuhhhh), mb_ok);
1020
tabsheettracecourbes.Refresh;
1026
{sauvegarde format tableur texte}
1027
if ((lowercase(extractfileext(ns))='.csv') or
1028
(lowercase(extractfileext(ns))='.txt')) then begin
1029
ligne:=expression_abscisse_explicite;
1030
for k:=1 to nombre_ordonnees do
1031
ligne:=ligne+separateur_csv+expression_ordonnees_explicites[k-1];
1033
for i:=1 to nombre_points_calcul+1 do begin
1034
if not(isnanorinfinite(tableau_grandeurs_tracees[i-1,0])) then
1035
ligne:=remplace_point_decimal(floattostr(tableau_grandeurs_tracees[i-1,0]))
1038
for j:=1 to nombre_ordonnees do
1039
if not(isnanorinfinite(tableau_grandeurs_tracees[i-1,j])) then
1040
ligne:=ligne+separateur_csv+remplace_point_decimal(floattostr(tableau_grandeurs_tracees[i-1,j])) else
1041
ligne:=ligne+separateur_csv+'NAN';
1051
procedure TForm1.MenuItemRaffineRW3Click(Sender: TObject);
1052
var f:textfile; ns,ligne,dede:string;
1056
savedialog1.FileName:='';
1057
savedialog1.InitialDir:=repertoire_dosage_perso;
1058
SaveDialog1.DefaultExt := '.rw3';
1059
SaveDialog1.Filter := 'Regressi (*.rw3)|.rw3';
1060
if not(savedialog1.Execute) then exit else
1061
ns:=savedialog1.FileName;
1063
assignfile(f,utf8tosys(ns));
1067
application.MessageBox(pchar(rsImpossibleDe),
1068
pchar(rsMaisEuhhhh), mb_ok);
1069
tabsheettracecourbes.Refresh;
1073
{sauvagarde format regressi}
1074
if (lowercase(extractfileext(ns))='.rw3') then begin
1075
writeln(f,'EVARISTE REGRESSI WINDOWS 1.0');
1076
writeln(f,chr(163)+inttostr(1+nombre_ordonnees)+' NOM VAR');
1077
writeln(f,'abscisse');
1078
for i:=1 to nombre_ordonnees do
1079
writeln(f,'ord'+inttostr(i));
1080
writeln(f,chr(163)+inttostr(1+nombre_ordonnees)+' GENRE VAR');
1081
for i:=1 to nombre_ordonnees+1 do writeln(f,'0');
1082
writeln(f,chr(163)+inttostr(1+nombre_ordonnees)+' UNITE VAR');
1083
for i:=1 to nombre_ordonnees+1 do writeln(f);
1084
writeln(f,chr(163)+inttostr(1+nombre_ordonnees)+' INCERTITUDE');
1085
for i:=1 to nombre_ordonnees+1 do writeln(f);
1086
writeln(f,chr(163)+'1 TRIGO');
1088
writeln(f,chr(163)+'1 LOG');
1090
writeln(f,chr(163)+inttostr(1+nombre_ordonnees)+' MEMO GRANDEURS');
1091
writeln(f,'''abscisse: '+expression_abscisse_explicite);
1092
for i:=1 to nombre_ordonnees do
1093
writeln(f,'''ord'+inttostr(i)+': '+expression_ordonnees_explicites[i-1]);
1094
writeln(f,chr(163)+'2 ACQUISITION');
1095
writeln(f,'CLAVIER');
1097
writeln(f,chr(163)+'0 GRAPHE VAR');
1099
writeln(f,'abscisse');
1110
writeln(f,'&5 MONDE');
1116
writeln(f,'&2 GRADUATION');
1119
writeln(f,'&2 ZERO');
1122
writeln(f,'&5 OPTIONS');
1128
writeln(f,chr(163)+'1 PAGE COMMENT');
1130
writeln(f,'&'+inttostr(nombre_points_calcul+1)+' VALEUR VAR');
1131
for i:=1 to nombre_points_calcul+1 do begin
1133
for j:=0 to nombre_ordonnees do
1134
if not(isnanorinfinite(tableau_grandeurs_tracees[i-1,j])) then
1135
ligne:=ligne+floattostr( tableau_grandeurs_tracees[i-1,j])+' ' else
1139
{sauvegarde format regressi}
1145
tabsheettracecourbes.Refresh;
1151
procedure TForm1.MenuItem_charger_exemplesClick(Sender: TObject);
1153
Form1.Jouerunfilmdesimulation(Sender,repertoire_exemples);
1156
procedure TForm1.MenuItem_charger_personnelClick(Sender: TObject);
1158
Form1.Jouerunfilmdesimulation(Sender,repertoire_dosage_perso);
804
1161
procedure tform1.vire_grandeurs_a_tracer;
1867
procedure TForm1.SpeedButton_dilutionClick(Sender: TObject);
1869
var repmode,i:integer;
1871
666: Form_dilution:=tForm_dilution.create(self);
1874
if screen.width>width then left:=(screen.width-width) div 2 else left:=0;
1875
if screen.height>height then top:=(screen.height-height) div 2 else top:=0;
1877
Form_dilution.Caption:=rsDilutionPour;
1878
repmode:=Form_dilution.ShowModal;
1879
if repmode=mrcancel then exit;
1880
if repmode=mrretry then goto 666;
1881
case action_dilution of
1882
multiplier_concentrations: begin
1883
etape:=choisir_becher;
1884
if stringgridreactifs_becher.RowCount>1 then
1885
for i:=1 to stringgridreactifs_becher.RowCount-1 do
1886
if stringgridreactifs_becher.Cells[2,i]<>'' then
1887
stringgridreactifs_becher.Cells[2,i]:=floattostr(
1888
facteur*strtofloat(stringgridreactifs_becher.Cells[2,i]));
1892
strtofloat(editvolume.text);
1894
application.MessageBox(pchar(rsLAncienVolum),
1895
pchar(rsAttention2), mb_ok);
1898
etape:=choisir_becher;
1899
if stringgridreactifs_becher.RowCount>1 then
1900
for i:=1 to stringgridreactifs_becher.RowCount-1 do
1901
if stringgridreactifs_becher.Cells[2,i]<>'' then
1902
stringgridreactifs_becher.Cells[2,i]:=floattostr(
1903
strtofloat(editvolume.text)/(strtofloat(editvolume.text)+facteur)*strtofloat(stringgridreactifs_becher.Cells[2,i]));
1904
editvolume.text:=floattostr(strtofloat(editvolume.text)+facteur);
1906
imposer_volume_total: begin
1908
strtofloat(editvolume.text);
1910
application.MessageBox(pchar(rsLAncienVolum),
1911
pchar(rsAttention2), mb_ok);
1914
etape:=choisir_becher;
1915
if stringgridreactifs_becher.RowCount>1 then
1916
for i:=1 to stringgridreactifs_becher.RowCount-1 do
1917
if stringgridreactifs_becher.Cells[2,i]<>'' then
1918
stringgridreactifs_becher.Cells[2,i]:=floattostr(
1919
strtofloat(editvolume.text)/(facteur)*strtofloat(stringgridreactifs_becher.Cells[2,i]));
1920
editvolume.text:=floattostr(facteur);
1926
procedure TForm1.SpeedButton_dilution_Click(Sender: TObject);
1928
var repmode,i:integer;
1930
666: Form_dilution:=tForm_dilution.create(self);
1933
if screen.width>width then left:=(screen.width-width) div 2 else left:=0;
1934
if screen.height>height then top:=(screen.height-height) div 2 else top:=0;
1936
Form_dilution.Caption:=rsDilutionPour2;
1937
repmode:=Form_dilution.ShowModal;
1938
if repmode=mrcancel then exit;
1939
if repmode=mrretry then goto 666;
1940
case action_dilution of
1941
multiplier_concentrations: begin
1942
etape:=choisir_burette;
1943
if stringgridreactifs_burette.RowCount>1 then
1944
for i:=1 to stringgridreactifs_burette.RowCount-1 do
1945
if stringgridreactifs_burette.Cells[2,i]<>'' then
1946
stringgridreactifs_burette.Cells[2,i]:=floattostr(
1947
facteur*strtofloat(stringgridreactifs_burette.Cells[2,i]));
1951
strtofloat(editvolume_burette.text);
1953
application.MessageBox(pchar(rsLAncienVolum),
1954
pchar(rsAttention2), mb_ok);
1957
etape:=choisir_burette;
1958
if stringgridreactifs_burette.RowCount>1 then
1959
for i:=1 to stringgridreactifs_burette.RowCount-1 do
1960
if stringgridreactifs_burette.Cells[2,i]<>'' then
1961
stringgridreactifs_burette.Cells[2,i]:=floattostr(
1962
strtofloat(editvolume_burette.text)/(strtofloat(editvolume_burette.text)+facteur)*strtofloat(stringgridreactifs_burette.Cells[2,i]));
1963
editvolume_burette.text:=floattostr(strtofloat(editvolume_burette.text)+facteur);
1965
imposer_volume_total: begin
1967
strtofloat(editvolume_burette.text);
1969
application.MessageBox(pchar(rsLAncienVolum),
1970
pchar(rsAttention2), mb_ok);
1973
etape:=choisir_burette;
1974
if stringgridreactifs_burette.RowCount>1 then
1975
for i:=1 to stringgridreactifs_burette.RowCount-1 do
1976
if stringgridreactifs_burette.Cells[2,i]<>'' then
1977
stringgridreactifs_burette.Cells[2,i]:=floattostr(
1978
strtofloat(editvolume_burette.text)/(facteur)*strtofloat(stringgridreactifs_burette.Cells[2,i]));
1979
editvolume_burette.text:=floattostr(facteur);
1509
1988
procedure TForm1.SpinEdit0001pourcentClick(Sender: TObject;
8148
9198
procedure TForm1.BitBtn5Click(Sender: TObject);
8149
var f:textfile; ns,ligne:string;
8152
if not(savedialog1.Execute) then exit else
8153
ns:=savedialog1.FileName;
8158
application.MessageBox(pchar(rsImpossibleDe),
8159
pchar(rsMaisEuhhhh), mb_ok);
8163
{sauvagarde format regressi}
8164
if (lowercase(extractfileext(ns))='.rw3') then begin
8165
writeln(f,'EVARISTE REGRESSI WINDOWS 1.0');
8166
{<ajout version 1.10}
8167
if not(calcul_derivees) then
8168
if not(debye_0) then
8169
writeln(f,chr(163)+inttostr(1+nombre_solutes_0+nombre_precipites_0)+' NOM VAR') else
8170
writeln(f,chr(163)+inttostr(1+nombre_solutes_0+nombre_precipites_0+nombre_solutes_0)+' NOM VAR')
8172
if not(debye_0) then
8173
writeln(f,chr(163)+inttostr(1+2*nombre_solutes_0+2*nombre_precipites_0)+' NOM VAR') else
8174
writeln(f,chr(163)+inttostr(1+4*nombre_solutes_0+2*nombre_precipites_0)+' NOM VAR');
8175
{ajout version 1.10>}
8178
for i:=1 to nombre_solutes_0 do
8179
writeln(f,'conc'+inttostr(i));
8180
for i:=1 to nombre_precipites_0 do
8181
writeln(f,'nmoles'+inttostr(i));
8183
for i:=1 to nombre_solutes_0 do
8184
writeln(f,'activ'+inttostr(i));
8186
{<ajout version 1.10}
8187
if calcul_derivees then begin
8188
for i:=1 to nombre_solutes_0 do
8189
writeln(f,'dc'+inttostr(i)+'dV');
8190
for i:=1 to nombre_precipites_0 do
8191
writeln(f,'dn'+inttostr(i)+'dV');
8193
for i:=1 to nombre_solutes_0 do
8194
writeln(f,'da'+inttostr(i)+'dV');
8196
{ajout version 1.10>}
8198
{<ajout version 1.10}
8199
if not(calcul_derivees) then
8200
if not(debye_0) then
8201
writeln(f,chr(163)+inttostr(1+nombre_solutes_0+nombre_precipites_0)+' GENRE VAR') else
8202
writeln(f,chr(163)+inttostr(1+nombre_solutes_0+nombre_precipites_0+nombre_solutes_0)+' GENRE VAR')
8204
if not(debye_0) then
8205
writeln(f,chr(163)+inttostr(1+2*nombre_solutes_0+2*nombre_precipites_0)+' GENRE VAR') else
8206
writeln(f,chr(163)+inttostr(1+4*nombre_solutes_0+2*nombre_precipites_0)+' GENRE VAR');
8207
{ajout version 1.10>}
8209
{<ajout version 1.10}
8210
if not(calcul_derivees) then
8211
if not(debye_0) then
8212
for i:=1 to 1+nombre_solutes_0+nombre_precipites_0 do writeln(f,'0')
8214
for i:=1 to 1+nombre_solutes_0+nombre_precipites_0+nombre_solutes_0 do writeln(f,'0')
8216
if not(debye_0) then
8217
for i:=1 to 1+2*nombre_solutes_0+2*nombre_precipites_0 do writeln(f,'0')
8219
for i:=1 to 1+4*nombre_solutes_0+2*nombre_precipites_0 do writeln(f,'0');
8220
{ajout version 1.10>}
8223
{<ajout version 1.10}
8224
if not(calcul_derivees) then
8225
if not(debye_0) then
8226
writeln(f,chr(163)+inttostr(1+nombre_solutes_0+nombre_precipites_0)+' UNITE VAR') else
8227
writeln(f,chr(163)+inttostr(1+nombre_solutes_0+nombre_precipites_0+nombre_solutes_0)+' UNITE VAR')
8229
if not(debye_0) then
8230
writeln(f,chr(163)+inttostr(1+2*nombre_solutes_0+2*nombre_precipites_0)+' UNITE VAR') else
8231
writeln(f,chr(163)+inttostr(1+4*nombre_solutes_0+2*nombre_precipites_0)+' UNITE VAR');
8232
{ajout version 1.10>}
8235
for i:=1 to nombre_solutes_0 do writeln(f,'mol/L');
8236
for i:=1 to nombre_precipites_0 do writeln(f,'mol');
8238
for i:=1 to nombre_solutes_0 do writeln(f);
8240
{<ajout version 1.10}
8241
if calcul_derivees then begin
8242
for i:=1 to nombre_solutes_0 do writeln(f,'mol/L²');
8243
for i:=1 to nombre_precipites_0 do writeln(f,'mol/L');
8245
for i:=1 to nombre_solutes_0 do writeln(f,'1/L');
8247
{ajout version 1.10>}
8249
{<ajout version 1.10}
8250
if not(calcul_derivees) then
8251
if not(debye_0) then
8252
writeln(f,chr(163)+inttostr(1+nombre_solutes_0+nombre_precipites_0)+' INCERTITUDE') else
8253
writeln(f,chr(163)+inttostr(1+nombre_solutes_0+nombre_precipites_0+nombre_solutes_0)+' INCERTITUDE')
8255
if not(debye_0) then
8256
writeln(f,chr(163)+inttostr(1+2*nombre_solutes_0+2*nombre_precipites_0)+' INCERTITUDE') else
8257
writeln(f,chr(163)+inttostr(1+4*nombre_solutes_0+2*nombre_precipites_0)+' INCERTITUDE');
8258
{ajout version 1.10>}
8260
{<ajout version 1.10}
8261
if not(calcul_derivees) then
8262
if not(debye_0) then
8263
for i:=1 to 1+nombre_solutes_0+nombre_precipites_0 do writeln(f) else
8264
for i:=1 to 1+nombre_solutes_0+nombre_precipites_0+nombre_solutes_0 do writeln(f)
8266
if not(debye_0) then
8267
for i:=1 to 1+2*nombre_solutes_0+2*nombre_precipites_0 do writeln(f) else
8268
for i:=1 to 1+4*nombre_solutes_0+2*nombre_precipites_0 do writeln(f);
8269
{ajout version 1.10>}
8271
writeln(f,chr(163)+'1 TRIGO');
8273
writeln(f,chr(163)+'1 LOG');
8276
{<ajout version 1.10}
8277
if not(calcul_derivees) then
8278
if not(debye_0) then
8279
writeln(f,chr(163)+inttostr(nombre_solutes_0+nombre_precipites_0)+' MEMO GRANDEURS') else
8280
writeln(f,chr(163)+inttostr(nombre_solutes_0+nombre_precipites_0+nombre_solutes_0)+' MEMO GRANDEURS')
8282
if not(debye_0) then
8283
writeln(f,chr(163)+inttostr(2*nombre_solutes_0+2*nombre_precipites_0)+' MEMO GRANDEURS') else
8284
writeln(f,chr(163)+inttostr(4*nombre_solutes_0+2*nombre_precipites_0)+' MEMO GRANDEURS');
8285
{ajout version 1.10>}
8287
for i:=1 to nombre_solutes_0 do
8288
writeln(f,'''conc'+inttostr(i)+': concentration en '+noms_solutes_0[i-1]);
8289
for i:=1 to nombre_precipites_0 do
8290
writeln(f,'''nmoles'+inttostr(i)+': nombre de moles de '+noms_precipites_0[i-1]);
8291
if debye_0 then for i:=1 to nombre_solutes_0 do
8292
writeln(f,'''activ'+inttostr(i)+': activite de: '+noms_solutes_0[i-1]);
8293
{<ajout version 1.10}
8294
if calcul_derivees then begin
8295
for i:=1 to nombre_solutes_0 do
8296
writeln(f,'''dc'+inttostr(i)+'dV: dérivée de la concentration en '+noms_solutes_0[i-1]+'par rapport à V');
8297
for i:=1 to nombre_precipites_0 do
8298
writeln(f,'''dn'+inttostr(i)+'dV: dérivée du nombre de moles de '+noms_precipites_0[i-1]+'par rapport à V');
8299
if debye_0 then for i:=1 to nombre_solutes_0 do
8300
writeln(f,'''da'+inttostr(i)+'dV: dérivée de l''activite de: '+noms_solutes_0[i-1]+'par rapport à V');
8302
{ajout version 1.10>}
8304
writeln(f,chr(163)+'2 ACQUISITION');
8305
writeln(f,'CLAVIER');
8307
writeln(f,chr(163)+'0 GRAPHE VAR');
8320
writeln(f,'&5 MONDE');
8326
writeln(f,'&2 GRADUATION');
8329
writeln(f,'&2 ZERO');
8332
writeln(f,'&5 OPTIONS');
8338
writeln(f,chr(163)+'1 PAGE COMMENT');
8340
writeln(f,'&'+inttostr(nombre_points_calcul+1)+' VALEUR VAR');
8341
for i:=1 to nombre_points_calcul+1 do begin
8342
ligne:=floattostr(tableau_resultats[i-1,0])+' ';
8344
{<ajout version 1.10}
8345
if not(calcul_derivees) then
8346
if not(debye_0) then
8347
for j:=1 to nombre_solutes_0+nombre_precipites_0 do
8348
if not(isnanorinfinite(tableau_resultats[i-1,j])) then
8349
ligne:=ligne+floattostr(tableau_resultats[i-1,j])+' '
8353
for j:=1 to nombre_solutes_0+nombre_precipites_0+nombre_solutes_0 do
8354
if not(isnanorinfinite(tableau_resultats[i-1,j])) then
8355
ligne:=ligne+floattostr(tableau_resultats[i-1,j])+' '
8360
if not(debye_0) then
8361
for j:=1 to nombre_solutes_0+nombre_precipites_0 do
8362
if not(isnanorinfinite(tableau_resultats[i-1,j])) then
8363
ligne:=ligne+floattostr(tableau_resultats[i-1,j])+' '
8366
for j:=1 to nombre_solutes_0+nombre_precipites_0 do
8367
if not(isnanorinfinite(tableau_resultats[i-1,j+2*nombre_solutes_0+nombre_precipites_0])) then
8368
ligne:=ligne+floattostr(tableau_resultats[i-1,j+2*nombre_solutes_0+nombre_precipites_0])+' '
8372
for j:=1 to 4*nombre_solutes_0+2*nombre_precipites_0 do
8373
if not(isnanorinfinite(tableau_resultats[i-1,j])) then
8374
ligne:=ligne+floattostr(tableau_resultats[i-1,j])+' '
8377
{ajout version 1.10>}
8380
{sauvegarde format regressi}
8383
{sauvegarde format tableur texte}
8384
if ((lowercase(extractfileext(ns))='.csv') or
8385
(lowercase(extractfileext(ns))='.txt')) then begin
8387
if nombre_solutes_0>0 then for i:=1 to nombre_solutes_0 do
8388
ligne:=ligne+separateur_csv+noms_solutes_0[i-1];
8389
if nombre_precipites_0>0 then for i:=1 to nombre_precipites_0 do
8390
ligne:=ligne+separateur_csv+noms_precipites_0[i-1];
8392
if nombre_solutes_0>0 then for i:=1 to nombre_solutes_0 do
8393
ligne:=ligne+separateur_csv+noms_solutes_0[i-1];
8394
{<ajout version 1.10}
8395
if calcul_derivees then begin
8396
if nombre_solutes_0>0 then for i:=1 to nombre_solutes_0 do
8397
ligne:=ligne+separateur_csv+noms_solutes_0[i-1];
8398
if nombre_precipites_0>0 then for i:=1 to nombre_precipites_0 do
8399
ligne:=ligne+separateur_csv+noms_precipites_0[i-1];
8401
if nombre_solutes_0>0 then for i:=1 to nombre_solutes_0 do
8402
ligne:=ligne+separateur_csv+noms_solutes_0[i-1];
8404
{ajout version 1.10>}
8407
if nombre_solutes_0>0 then for i:=1 to nombre_solutes_0 do
8408
ligne:=Format(rsConcMolL2, [ligne+separateur_csv]);
8409
if nombre_precipites_0>0 then for i:=1 to nombre_precipites_0 do
8410
ligne:=Format(rsQuantitMol, [ligne+separateur_csv]);
8412
if nombre_solutes_0>0 then for i:=1 to nombre_solutes_0 do
8413
ligne:=Format(rsActivit2, [ligne+separateur_csv]);
8415
{<ajout version 1.10}
8416
if calcul_derivees then begin
8417
if nombre_solutes_0>0 then for i:=1 to nombre_solutes_0 do
8418
ligne:=Format(rsDC_dVMolL, [ligne+separateur_csv]);
8419
if nombre_precipites_0>0 then for i:=1 to nombre_precipites_0 do
8420
ligne:=Format(rsDN_dVMolL, [ligne+separateur_csv]);
8422
if nombre_solutes_0>0 then for i:=1 to nombre_solutes_0 do
8423
ligne:=Format(rsDa_dV1L, [ligne+separateur_csv]);
8425
{ajout version 1.10>}
8430
for i:=1 to nombre_points_calcul+1 do begin
8431
ligne:=remplace_point_decimal(floattostr(tableau_resultats[i-1,0]));
8432
{<ajout version 1.10}
8434
if (not(debye_0) and not(calcul_derivees)) then
8435
for j:=1 to nombre_solutes_0+nombre_precipites_0 do
8436
if not(isnanorinfinite(tableau_resultats[i-1,j])) then
8437
ligne:=ligne+separateur_csv+remplace_point_decimal(floattostr(tableau_resultats[i-1,j]))
8438
else ligne:=ligne+' 0';
8440
if ((debye_0) and not(calcul_derivees)) then
8441
for j:=1 to 2*nombre_solutes_0+nombre_precipites_0 do
8442
if not(isnanorinfinite(tableau_resultats[i-1,j])) then
8443
ligne:=ligne+separateur_csv+remplace_point_decimal(floattostr(tableau_resultats[i-1,j]))
8444
else ligne:=ligne+' 0' ;
8446
if (not(debye_0) and (calcul_derivees)) then
8447
for j:=1 to 2*nombre_solutes_0+2*nombre_precipites_0 do
8448
if not(isnanorinfinite(tableau_resultats[i-1,j])) then
8449
ligne:=ligne+separateur_csv+remplace_point_decimal(floattostr(tableau_resultats[i-1,j]))
8450
else ligne:=ligne+' 0' ;
8452
if ((debye_0) and (calcul_derivees)) then
8453
for j:=1 to 4*nombre_solutes_0+2*nombre_precipites_0 do
8454
if not(isnanorinfinite(tableau_resultats[i-1,j])) then
8455
ligne:=ligne+separateur_csv+remplace_point_decimal(floattostr(tableau_resultats[i-1,j]))
8456
else ligne:=ligne+' 0' ;
8462
{sauvegarde tableur texte}
9200
popupmenubrut.PopUp;
8466
9203
procedure TForm1.BitBtn6Click(Sender: TObject);
13155
procedure TForm1.MenuItem_sauve_brut_csvClick(Sender: TObject);
13156
var f:textfile; ns,ligne:string;
13159
savedialog1.FileName:='';
13160
savedialog1.InitialDir:=repertoire_dosage_perso;
13161
SaveDialog1.DefaultExt := rsCsv;
13162
SaveDialog1.Filter := rsTableurTexte2;
13163
if not(savedialog1.Execute) then exit else
13164
ns:=savedialog1.FileName;
13165
assignfile(f,utf8tosys(ns));
13169
application.MessageBox(pchar(rsImpossibleDe),
13170
pchar(rsMaisEuhhhh), mb_ok);
13175
{sauvegarde format tableur texte}
13176
if ((lowercase(extractfileext(ns))='.csv') or
13177
(lowercase(extractfileext(ns))='.txt')) then begin
13179
if nombre_solutes_0>0 then for i:=1 to nombre_solutes_0 do
13180
ligne:=ligne+separateur_csv+noms_solutes_0[i-1];
13181
if nombre_precipites_0>0 then for i:=1 to nombre_precipites_0 do
13182
ligne:=ligne+separateur_csv+noms_precipites_0[i-1];
13184
if nombre_solutes_0>0 then for i:=1 to nombre_solutes_0 do
13185
ligne:=ligne+separateur_csv+noms_solutes_0[i-1];
13186
{<ajout version 1.10}
13187
if calcul_derivees then begin
13188
if nombre_solutes_0>0 then for i:=1 to nombre_solutes_0 do
13189
ligne:=ligne+separateur_csv+noms_solutes_0[i-1];
13190
if nombre_precipites_0>0 then for i:=1 to nombre_precipites_0 do
13191
ligne:=ligne+separateur_csv+noms_precipites_0[i-1];
13193
if nombre_solutes_0>0 then for i:=1 to nombre_solutes_0 do
13194
ligne:=ligne+separateur_csv+noms_solutes_0[i-1];
13196
{ajout version 1.10>}
13199
if nombre_solutes_0>0 then for i:=1 to nombre_solutes_0 do
13200
ligne:=Format(rsConcMolL2, [ligne+separateur_csv]);
13201
if nombre_precipites_0>0 then for i:=1 to nombre_precipites_0 do
13202
ligne:=Format(rsQuantitMol, [ligne+separateur_csv]);
13204
if nombre_solutes_0>0 then for i:=1 to nombre_solutes_0 do
13205
ligne:=Format(rsActivit2, [ligne+separateur_csv]);
13207
{<ajout version 1.10}
13208
if calcul_derivees then begin
13209
if nombre_solutes_0>0 then for i:=1 to nombre_solutes_0 do
13210
ligne:=Format(rsDC_dVMolL, [ligne+separateur_csv]);
13211
if nombre_precipites_0>0 then for i:=1 to nombre_precipites_0 do
13212
ligne:=Format(rsDN_dVMolL, [ligne+separateur_csv]);
13214
if nombre_solutes_0>0 then for i:=1 to nombre_solutes_0 do
13215
ligne:=Format(rsDa_dV1L, [ligne+separateur_csv]);
13217
{ajout version 1.10>}
13222
for i:=1 to nombre_points_calcul+1 do begin
13223
ligne:=remplace_point_decimal(floattostr(tableau_resultats[i-1,0]));
13224
{<ajout version 1.10}
13226
if (not(debye_0) and not(calcul_derivees)) then
13227
for j:=1 to nombre_solutes_0+nombre_precipites_0 do
13228
if not(isnanorinfinite(tableau_resultats[i-1,j])) then
13229
ligne:=ligne+separateur_csv+remplace_point_decimal(floattostr(tableau_resultats[i-1,j]))
13230
else ligne:=ligne+' 0';
13232
if ((debye_0) and not(calcul_derivees)) then
13233
for j:=1 to 2*nombre_solutes_0+nombre_precipites_0 do
13234
if not(isnanorinfinite(tableau_resultats[i-1,j])) then
13235
ligne:=ligne+separateur_csv+remplace_point_decimal(floattostr(tableau_resultats[i-1,j]))
13236
else ligne:=ligne+' 0' ;
13238
if (not(debye_0) and (calcul_derivees)) then
13239
for j:=1 to 2*nombre_solutes_0+2*nombre_precipites_0 do
13240
if not(isnanorinfinite(tableau_resultats[i-1,j])) then
13241
ligne:=ligne+separateur_csv+remplace_point_decimal(floattostr(tableau_resultats[i-1,j]))
13242
else ligne:=ligne+' 0' ;
13244
if ((debye_0) and (calcul_derivees)) then
13245
for j:=1 to 4*nombre_solutes_0+2*nombre_precipites_0 do
13246
if not(isnanorinfinite(tableau_resultats[i-1,j])) then
13247
ligne:=ligne+separateur_csv+remplace_point_decimal(floattostr(tableau_resultats[i-1,j]))
13248
else ligne:=ligne+' 0' ;
13254
{sauvegarde tableur texte}
13260
procedure TForm1.MenuItem_save_brut_rw3Click(Sender: TObject);
13261
var f:textfile; ns,ligne:string;
13264
savedialog1.FileName:='';
13265
savedialog1.InitialDir:=repertoire_dosage_perso;
13266
SaveDialog1.DefaultExt := '.rw3';
13267
SaveDialog1.Filter := 'Regressi (*.rw3)|.rw3';
13268
if not(savedialog1.Execute) then exit else
13269
ns:=savedialog1.FileName;
13270
assignfile(f,utf8tosys(ns));
13274
application.MessageBox(pchar(rsImpossibleDe),
13275
pchar(rsMaisEuhhhh), mb_ok);
13280
writeln(f,'EVARISTE REGRESSI WINDOWS 1.0');
13281
{<ajout version 1.10}
13282
if not(calcul_derivees) then
13283
if not(debye_0) then
13284
writeln(f,chr(163)+inttostr(1+nombre_solutes_0+nombre_precipites_0)+' NOM VAR') else
13285
writeln(f,chr(163)+inttostr(1+nombre_solutes_0+nombre_precipites_0+nombre_solutes_0)+' NOM VAR')
13287
if not(debye_0) then
13288
writeln(f,chr(163)+inttostr(1+2*nombre_solutes_0+2*nombre_precipites_0)+' NOM VAR') else
13289
writeln(f,chr(163)+inttostr(1+4*nombre_solutes_0+2*nombre_precipites_0)+' NOM VAR');
13290
{ajout version 1.10>}
13293
for i:=1 to nombre_solutes_0 do
13294
writeln(f,'conc'+inttostr(i));
13295
for i:=1 to nombre_precipites_0 do
13296
writeln(f,'nmoles'+inttostr(i));
13298
for i:=1 to nombre_solutes_0 do
13299
writeln(f,'activ'+inttostr(i));
13301
{<ajout version 1.10}
13302
if calcul_derivees then begin
13303
for i:=1 to nombre_solutes_0 do
13304
writeln(f,'dc'+inttostr(i)+'dV');
13305
for i:=1 to nombre_precipites_0 do
13306
writeln(f,'dn'+inttostr(i)+'dV');
13308
for i:=1 to nombre_solutes_0 do
13309
writeln(f,'da'+inttostr(i)+'dV');
13311
{ajout version 1.10>}
13313
{<ajout version 1.10}
13314
if not(calcul_derivees) then
13315
if not(debye_0) then
13316
writeln(f,chr(163)+inttostr(1+nombre_solutes_0+nombre_precipites_0)+' GENRE VAR') else
13317
writeln(f,chr(163)+inttostr(1+nombre_solutes_0+nombre_precipites_0+nombre_solutes_0)+' GENRE VAR')
13319
if not(debye_0) then
13320
writeln(f,chr(163)+inttostr(1+2*nombre_solutes_0+2*nombre_precipites_0)+' GENRE VAR') else
13321
writeln(f,chr(163)+inttostr(1+4*nombre_solutes_0+2*nombre_precipites_0)+' GENRE VAR');
13322
{ajout version 1.10>}
13324
{<ajout version 1.10}
13325
if not(calcul_derivees) then
13326
if not(debye_0) then
13327
for i:=1 to 1+nombre_solutes_0+nombre_precipites_0 do writeln(f,'0')
13329
for i:=1 to 1+nombre_solutes_0+nombre_precipites_0+nombre_solutes_0 do writeln(f,'0')
13331
if not(debye_0) then
13332
for i:=1 to 1+2*nombre_solutes_0+2*nombre_precipites_0 do writeln(f,'0')
13334
for i:=1 to 1+4*nombre_solutes_0+2*nombre_precipites_0 do writeln(f,'0');
13335
{ajout version 1.10>}
13338
{<ajout version 1.10}
13339
if not(calcul_derivees) then
13340
if not(debye_0) then
13341
writeln(f,chr(163)+inttostr(1+nombre_solutes_0+nombre_precipites_0)+' UNITE VAR') else
13342
writeln(f,chr(163)+inttostr(1+nombre_solutes_0+nombre_precipites_0+nombre_solutes_0)+' UNITE VAR')
13344
if not(debye_0) then
13345
writeln(f,chr(163)+inttostr(1+2*nombre_solutes_0+2*nombre_precipites_0)+' UNITE VAR') else
13346
writeln(f,chr(163)+inttostr(1+4*nombre_solutes_0+2*nombre_precipites_0)+' UNITE VAR');
13347
{ajout version 1.10>}
13350
for i:=1 to nombre_solutes_0 do writeln(f,'mol/L');
13351
for i:=1 to nombre_precipites_0 do writeln(f,'mol');
13353
for i:=1 to nombre_solutes_0 do writeln(f);
13355
{<ajout version 1.10}
13356
if calcul_derivees then begin
13357
for i:=1 to nombre_solutes_0 do writeln(f,'mol/L²');
13358
for i:=1 to nombre_precipites_0 do writeln(f,'mol/L');
13360
for i:=1 to nombre_solutes_0 do writeln(f,'1/L');
13362
{ajout version 1.10>}
13364
{<ajout version 1.10}
13365
if not(calcul_derivees) then
13366
if not(debye_0) then
13367
writeln(f,chr(163)+inttostr(1+nombre_solutes_0+nombre_precipites_0)+' INCERTITUDE') else
13368
writeln(f,chr(163)+inttostr(1+nombre_solutes_0+nombre_precipites_0+nombre_solutes_0)+' INCERTITUDE')
13370
if not(debye_0) then
13371
writeln(f,chr(163)+inttostr(1+2*nombre_solutes_0+2*nombre_precipites_0)+' INCERTITUDE') else
13372
writeln(f,chr(163)+inttostr(1+4*nombre_solutes_0+2*nombre_precipites_0)+' INCERTITUDE');
13373
{ajout version 1.10>}
13375
{<ajout version 1.10}
13376
if not(calcul_derivees) then
13377
if not(debye_0) then
13378
for i:=1 to 1+nombre_solutes_0+nombre_precipites_0 do writeln(f) else
13379
for i:=1 to 1+nombre_solutes_0+nombre_precipites_0+nombre_solutes_0 do writeln(f)
13381
if not(debye_0) then
13382
for i:=1 to 1+2*nombre_solutes_0+2*nombre_precipites_0 do writeln(f) else
13383
for i:=1 to 1+4*nombre_solutes_0+2*nombre_precipites_0 do writeln(f);
13384
{ajout version 1.10>}
13386
writeln(f,chr(163)+'1 TRIGO');
13388
writeln(f,chr(163)+'1 LOG');
13391
{<ajout version 1.10}
13392
if not(calcul_derivees) then
13393
if not(debye_0) then
13394
writeln(f,chr(163)+inttostr(nombre_solutes_0+nombre_precipites_0)+' MEMO GRANDEURS') else
13395
writeln(f,chr(163)+inttostr(nombre_solutes_0+nombre_precipites_0+nombre_solutes_0)+' MEMO GRANDEURS')
13397
if not(debye_0) then
13398
writeln(f,chr(163)+inttostr(2*nombre_solutes_0+2*nombre_precipites_0)+' MEMO GRANDEURS') else
13399
writeln(f,chr(163)+inttostr(4*nombre_solutes_0+2*nombre_precipites_0)+' MEMO GRANDEURS');
13400
{ajout version 1.10>}
13402
for i:=1 to nombre_solutes_0 do
13403
writeln(f,'''conc'+inttostr(i)+': concentration en '+noms_solutes_0[i-1]);
13404
for i:=1 to nombre_precipites_0 do
13405
writeln(f,'''nmoles'+inttostr(i)+': nombre de moles de '+noms_precipites_0[i-1]);
13406
if debye_0 then for i:=1 to nombre_solutes_0 do
13407
writeln(f,'''activ'+inttostr(i)+': activite de: '+noms_solutes_0[i-1]);
13408
{<ajout version 1.10}
13409
if calcul_derivees then begin
13410
for i:=1 to nombre_solutes_0 do
13411
writeln(f,'''dc'+inttostr(i)+'dV: dérivée de la concentration en '+noms_solutes_0[i-1]+'par rapport à V');
13412
for i:=1 to nombre_precipites_0 do
13413
writeln(f,'''dn'+inttostr(i)+'dV: dérivée du nombre de moles de '+noms_precipites_0[i-1]+'par rapport à V');
13414
if debye_0 then for i:=1 to nombre_solutes_0 do
13415
writeln(f,'''da'+inttostr(i)+'dV: dérivée de l''activite de: '+noms_solutes_0[i-1]+'par rapport à V');
13417
{ajout version 1.10>}
13419
writeln(f,chr(163)+'2 ACQUISITION');
13420
writeln(f,'CLAVIER');
13422
writeln(f,chr(163)+'0 GRAPHE VAR');
13430
writeln(f,'conc1');
13435
writeln(f,'&5 MONDE');
13441
writeln(f,'&2 GRADUATION');
13444
writeln(f,'&2 ZERO');
13447
writeln(f,'&5 OPTIONS');
13453
writeln(f,chr(163)+'1 PAGE COMMENT');
13455
writeln(f,'&'+inttostr(nombre_points_calcul+1)+' VALEUR VAR');
13456
for i:=1 to nombre_points_calcul+1 do begin
13457
ligne:=floattostr(tableau_resultats[i-1,0])+' ';
13459
{<ajout version 1.10}
13461
if not(calcul_derivees) and not(debye_0) then
13463
for j:=1 to nombre_solutes_0+nombre_precipites_0 do
13464
if not(isnanorinfinite(tableau_resultats[i-1,j])) then
13465
ligne:=ligne+floattostr(tableau_resultats[i-1,j])+' '
13470
if not(calcul_derivees) and debye_0 then begin
13471
for j:=1 to nombre_solutes_0+nombre_precipites_0+nombre_solutes_0 do
13472
if not(isnanorinfinite(tableau_resultats[i-1,j])) then
13473
ligne:=ligne+floattostr(tableau_resultats[i-1,j])+' '
13480
if (calcul_derivees) and not(debye_0) then begin
13481
for j:=1 to nombre_solutes_0+nombre_precipites_0 do
13482
if not(isnanorinfinite(tableau_resultats[i-1,j])) then
13483
ligne:=ligne+floattostr(tableau_resultats[i-1,j])+' '
13487
for j:=1 to nombre_solutes_0+nombre_precipites_0 do
13488
if not(isnanorinfinite(tableau_resultats[i-1,j+2*nombre_solutes_0+nombre_precipites_0])) then
13489
ligne:=ligne+floattostr(tableau_resultats[i-1,j+2*nombre_solutes_0+nombre_precipites_0])+' '
13495
if (calcul_derivees) and debye_0 then begin
13496
for j:=1 to 4*nombre_solutes_0+2*nombre_precipites_0 do
13497
if not(isnanorinfinite(tableau_resultats[i-1,j])) then
13498
ligne:=ligne+floattostr(tableau_resultats[i-1,j])+' '
13502
{ajout version 1.10>}
12334
13513
procedure TForm1.Nombredepointsdecalcul1Click(Sender: TObject);
12501
13683
procedure TForm1.SpeedButton10Click(Sender: TObject);
12502
var f:textfile; ns,ligne,dede:string;
12506
if not(savedialog1.Execute) then exit else
12507
ns:=savedialog1.FileName;
12513
application.MessageBox(pchar(rsImpossibleDe),
12514
pchar(rsMaisEuhhhh), mb_ok);
12515
tabsheettracecourbes.Refresh;
12519
{sauvagarde format regressi}
12520
if (lowercase(extractfileext(ns))='.rw3') then begin
12521
writeln(f,'EVARISTE REGRESSI WINDOWS 1.0');
12522
writeln(f,chr(163)+inttostr(1+nombre_ordonnees)+' NOM VAR');
12523
writeln(f,'abscisse');
12524
for i:=1 to nombre_ordonnees do
12525
writeln(f,'ord'+inttostr(i));
12526
writeln(f,chr(163)+inttostr(1+nombre_ordonnees)+' GENRE VAR');
12527
for i:=1 to nombre_ordonnees+1 do writeln(f,'0');
12528
writeln(f,chr(163)+inttostr(1+nombre_ordonnees)+' UNITE VAR');
12529
for i:=1 to nombre_ordonnees+1 do writeln(f);
12530
writeln(f,chr(163)+inttostr(1+nombre_ordonnees)+' INCERTITUDE');
12531
for i:=1 to nombre_ordonnees+1 do writeln(f);
12532
writeln(f,chr(163)+'1 TRIGO');
12534
writeln(f,chr(163)+'1 LOG');
12536
writeln(f,chr(163)+inttostr(1+nombre_ordonnees)+' MEMO GRANDEURS');
12537
writeln(f,'''abscisse: '+expression_abscisse_explicite);
12538
for i:=1 to nombre_ordonnees do
12539
writeln(f,'''ord'+inttostr(i)+': '+expression_ordonnees_explicites[i-1]);
12540
writeln(f,chr(163)+'2 ACQUISITION');
12541
writeln(f,'CLAVIER');
12543
writeln(f,chr(163)+'0 GRAPHE VAR');
12545
writeln(f,'abscisse');
12556
writeln(f,'&5 MONDE');
12562
writeln(f,'&2 GRADUATION');
12565
writeln(f,'&2 ZERO');
12568
writeln(f,'&5 OPTIONS');
12574
writeln(f,chr(163)+'1 PAGE COMMENT');
12576
writeln(f,'&'+inttostr(nombre_points_calcul+1)+' VALEUR VAR');
12577
for i:=1 to nombre_points_calcul+1 do begin
12579
for j:=0 to nombre_ordonnees do
12580
if not(isnanorinfinite(tableau_grandeurs_tracees[i-1,j])) then
12581
ligne:=ligne+floattostr( tableau_grandeurs_tracees[i-1,j])+' ' else
12585
{sauvegarde format regressi}
12588
{sauvegarde format tableur texte}
12589
if ((lowercase(extractfileext(ns))='.csv') or
12590
(lowercase(extractfileext(ns))='.txt')) then begin
12591
ligne:=expression_abscisse_explicite;
12592
for k:=1 to nombre_ordonnees do
12593
ligne:=ligne+separateur_csv+expression_ordonnees_explicites[k-1];
12595
for i:=1 to nombre_points_calcul+1 do begin
12596
if not(isnanorinfinite(tableau_grandeurs_tracees[i-1,0])) then
12597
ligne:=remplace_point_decimal(floattostr(tableau_grandeurs_tracees[i-1,0]))
12600
for j:=1 to nombre_ordonnees do
12601
if not(isnanorinfinite(tableau_grandeurs_tracees[i-1,j])) then
12602
ligne:=ligne+separateur_csv+remplace_point_decimal(floattostr(tableau_grandeurs_tracees[i-1,j])) else
12603
ligne:=ligne+separateur_csv+'NAN';
13685
popupmenuraffine.PopUp;
12609
13686
tabsheettracecourbes.Refresh;
18088
19250
nombre_points_exp:=0;
18089
19251
mode_experience:=false;
18090
19252
mode_superposition:=false;
18091
repertoire_executable:=extractfilepath(application.ExeName);
19253
repertoire_executable:=AppendPathDelim(extractfilepath(Application.ExeName));
18092
19254
nomexecutable:=extractfilename(Application.ExeName);
18095
repertoire_exemples:=repertoire_executable+'exemples\';
18096
repertoire_aide:=repertoire_executable+'aide\';
18098
repertoire_exemples:=repertoire_executable+'Exemples/';
18099
repertoire_aide:=repertoire_executable+'Aide/';
19255
repertoire_exemples:=AppendPathDelim(repertoire_executable+'Exemples');
19256
repertoire_aide:=AppendPathDelim(repertoire_executable+'Aide');
19257
repertoire_config_perso:=AppendPathDelim(MyGetAppConfigDirUTF8);
19260
repertoire_dosage_perso:=AppendPathDelim(AppendPathDelim(MyGetMesDocumentsUTF8)+'MesDosages');
19263
repertoire_dosage_perso:=AppendPathDelim({repertoire_config_perso}GetUserDir+'MesDosages');
19266
if not(directoryexistsUTF8(repertoire_config_perso)) then try
19267
forcedirectories(UTF8ToSys(repertoire_config_perso));
19269
if not(directoryexistsUTF8(repertoire_dosage_perso)) then try
19270
forcedirectories(UTF8ToSys(repertoire_dosage_perso));
19277
liste_langues:=tstringlist.create;
19278
chemin_po:=AppendPathDelim(repertoire_executable+'languages');
19280
If FindFirstutf8(Chemin_po+'dozzzaqueux.*.po',faAnyFile,Search)=0
19283
if (Search.Name='.') or (Search.Name='..') or (Search.Name='')
19285
{ liste_langues.Add(copy(Search.name,length(Search.name)-4,2)); }
19286
ID_lang:=copy(Search.name,length('dozzzaqueux.')+1,
19287
length(Search.Name)-length('dozzzaqueux..po'));
19288
if (ID_lang<>'') and (Pos('.',ID_lang)<1) and (liste_langues.IndexOf(ID_lang)<0)
19289
then liste_langues.Add(ID_lang);
19290
Until FindNextutf8(Search)<>0;
19291
FindCloseutf8(Search);
19295
lang:=''; FallbackLang:='';
19297
nom_ini_file:=repertoire_config_perso+'dozzzaqueux.ini';
19298
if not(fileexistsutf8(nom_ini_file)) then begin
19299
GetLanguageIDs(lang,FallbackLang);
19300
if ((liste_langues.indexof(uppercase(lang))=-1) and
19301
(liste_langues.indexof(uppercase(FallbackLang))=-1)) then
19303
Lang:='fr_FR'; FallbackLang:='fr';
19307
assignfile(f_ini,UTF8ToSys(nom_ini_file));
19309
readln(f_ini,lang);
19310
readln(f_ini,FallbackLang);
19314
//GetLanguageIDs(Lang, FallbackLang); // dans l'unité gettext
19319
PODirectory:=IncludeTrailingPathDelimiter(
19320
IncludeTrailingPathDelimiter(
19321
ExtractFilePath(Application.ExeName))+'languages');
19322
TranslateUnitResourceStrings('LCLStrConsts', PODirectory + 'lclstrconsts.%s.po', Lang, FallbackLang);
19323
TranslateUnitResourceStrings('UChaines', PODirectory + 'dozzzaqueux.%s.po', Lang, FallbackLang);
18101
19326
nombre_chiffres_constantes:=3;
18102
19327
nombre_chiffres_resultats:=3;