-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adicionado o interface para a tabela de Ar.
- Loading branch information
Showing
10 changed files
with
131 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
Define LibPub o2n_get(i1,i2,j1,j2,baseprop) | ||
Func | ||
|
||
Local prop,i,a,b,lin1,col1,lin2,col2,inicio,fim,meio,val1,val2,val3,dj2,way | ||
|
||
0=:a | ||
0=:b | ||
|
||
i1=:inicio | ||
i2=:fim | ||
asstermod.tabar[inicio,j1]=:val1 | ||
asstermod.tabar[fim,j1]=:val3 | ||
1=:way | ||
If j1=6 | ||
-1=:way | ||
|
||
Loop | ||
|
||
ceiling((inicio+fim)/2)=:meio | ||
|
||
tabar[meio,j1]=:val2 | ||
|
||
If way*baseprop<way*val1 or way*baseprop>way*val3 Then | ||
Exit | ||
ElseIf baseprop=val1 Then | ||
inicio=:a | ||
Exit | ||
ElseIf baseprop=val2 Then | ||
meio=:a | ||
Exit | ||
ElseIf baseprop=val3 Then | ||
fim=:a | ||
Exit | ||
ElseIf fim-inicio=1 Then | ||
inicio=:a | ||
Exit | ||
ElseIf way*val1<=way*baseprop and way*baseprop<=way*val2 Then | ||
meio=:fim | ||
val2=:val3 | ||
ElseIf way*val2<=way*baseprop and way*baseprop<=way*val3 Then | ||
meio=:inicio | ||
val2=:val1 | ||
EndIf | ||
|
||
EndLoop | ||
|
||
If a/=0 Then | ||
For i,a,i2 | ||
If baseprop*way<=way*tabar[i,j1] Then | ||
i=:b | ||
Exit | ||
EndIf | ||
EndFor | ||
EndIf | ||
|
||
dim(j2)=:dj2 | ||
If a=0 or b=0 Then | ||
undef+0*j2=:prop | ||
ElseIf a=b Then | ||
For i,1,dj2 | ||
If j2[i]/=0 Then | ||
asstermod.tabar[a,j2[i]]=:prop[i] | ||
Else | ||
undef=:prop[i] | ||
EndIf | ||
EndFor | ||
Else | ||
asstermod.tabar[a,j1]=:lin1 | ||
asstermod.tabar[b,j1]=:lin2 | ||
For i,1,dj2 | ||
If j2[i]/=0 Then | ||
asstermod.tabar[a,j2[i]]=:col1 | ||
asstermod.tabar[b,j2[i]]=:col2 | ||
asstermod.interpol(lin1,col1,lin2,col2,baseprop)=:prop[i] | ||
Else | ||
undef=:prop[i] | ||
EndIf | ||
EndFor | ||
EndIf | ||
|
||
Return prop | ||
EndFunc |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
Define LibPub o2n_prop(baseprop,tibsprop,tipo) | ||
Func | ||
© tabela A-22, TabAr | ||
© exemplos: O2N_Prop(32,"T",{"h","u"}) | ||
© O2N_Prop(valor,"T"\"h"\"u"\"s0"\"pr"\"vr",{"T","h","u","s0","pr","vr"}) | ||
|
||
Local prop,propcol,basecol,lin1,lin2,dtipo,i | ||
|
||
dim(tipo)=:dtipo | ||
|
||
If tibsprop="T" Then | ||
1=:basecol | ||
ElseIf tibsprop="h" Then | ||
2=:basecol | ||
ElseIf tibsprop="u" Then | ||
3=:basecol | ||
ElseIf tibsprop="s0" Then | ||
4=:basecol | ||
ElseIf tibsprop="pr" Then | ||
5=:basecol | ||
ElseIf tibsprop="vr" Then | ||
6=:basecol | ||
EndIf | ||
|
||
For i,1,dtipo | ||
If tipo[i]="T" Then | ||
1=:propcol[i] | ||
ElseIf tipo[i]="h" Then | ||
2=:propcol[i] | ||
ElseIf tipo[i]="u" Then | ||
3=:propcol[i] | ||
ElseIf tipo[i]="s0" Then | ||
4=:propcol[i] | ||
ElseIf tipo[i]="pr" Then | ||
5=:propcol[i] | ||
ElseIf tipo[i]="vr" Then | ||
6=:propcol[i] | ||
EndIf | ||
EndFor | ||
|
||
asstermod.tabar[1,2]=:lin1 | ||
asstermod.tabar[1,4]=:lin2 | ||
|
||
asstermod.o2n_get(lin1,lin2,basecol,propcol,baseprop)=:prop | ||
|
||
Return prop | ||
EndFunc |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.