English
Source / code snippets

Bitmuster-Generator / Test-Enumerator

 

p.specht

wants one for Tests logischer Schaltungen with Computerhilfe only any useful vorkommende Signalvarianten run through, remaining in the rule nothing other spare, as all possible Kombinationen hereon abzuklopfen, whether The jeweilige combination vorkommt or not. there The amount fundamentally möglicher Konfigurationen known with the number the Freiheitsgrade explode, prod such Approaches right quick on your border. there's one then glad, The Number of Opportunities from the Vorgaben on whom Testgenerator since already explicit retrenching to. moreover the following Demoprogramm - How always without Gewähr!

In XProfan11 shine Whileloop-Scheifen only up to of/ one limited Verschachtelungstiefe without Error To works. Überschreitet is a censorial number, forget the system whom stood äusserer Schleifenwerte (what me but very of verwendeten Betriebssystem and of disengaged Auslagerungsspeicher abzuhängen shining). circa this behaviour To bypass, afford itself Arrayvariablen as downstairs and upper Limits on, and these Limits serve then too same to values-Einschränkung, How supra demand, because one z.B. under- and ceiling einengt or gleichsetzt.

Window Title "Aufsteigender From-To-Enumerator without Stack-Overflow"
'(CL) CopyLeft 2016-07f by P.woodpecker, Vienna/Austria; OHNE JEGLICHE GEWÄHR!
declare of$,To$,n&,anz&,tmp$[],u&[],o&[],x&[],v&,nr&
CLS
Goto "Test3"' which Test should displayed go?
' THE ENUMERATOR MIT INDEX v&= ... ZÄHLT ...
' v&= 20__19____16__15_____12__11_____8____7____...___2_1_0"
von$=" 0,  0,0,0,0,   0,0,0,0,   4,0,0,0,   8,6,2,0, 3,1,0,9"
bis$=" 1,  9,0,0,0,   0,0,0,0,   4,0,0,0,   9,7,4,1, 5,2,1,9"
Goto "Init"
Test2:
' THE ENUMERATOR MIT INDEX v&=... ZÄHLT ...
' v&=_2_1_0"
von$="0,1,0"
bis$="2,2,0"
Goto "Init"
Test3:
' THE ENUMERATOR MIT INDEX v&= ... ZÄHLT ...
' v&= 20__19____16__15_____12__11_____8____7____...___2_1_0"
von$=" 0,  0,0,0,0,   0,0,0,0,   4,0,0,0,   8,6,2,5, 6,7,8,9"
bis$=" 1,  9,0,0,0,   0,0,0,0,   4,0,0,0,   9,7,4,5, 6,7,8,9"
Goto "Init"
'==========================================================
Init:
tmp$[]=explode(of$,","):n&=sizeof(tmp$[]):setsize u&[],n&:u&[]=val(tmp$[n&-1-&index])
clear tmp$[]:tmp$[]=explode(To$,","):setsize o&[],n&:o&[]=val(tmp$[n&-1-&index])
clear tmp$[],of$,To$:setsize x&[],n&
anz&=1:whileloop 0,n&-1:anz&=anz&*(o&[&loop]-u&[&loop]+1):endwhile
:print "\n it go ";anz&;" Konfigurationen created:\n":waitinput 1500
Start:
x&[]=u&[&index]

Whileloop anz&:Nr&=&Loop

    :print " ";Nr&;":  ";:whileloop n&-1,0,-1:print x&[&Loop];:endwhile :print
    ' ... or something Nützliches so make.

    Repeat

        if x&[v&]<o&[v&]

            x&[v&]=x&[v&]+1
            break

        else

            x&[v&]=u&[v&]
            inc v&

        endif

    until v&>=n&

    v&=0

endwhile

Beep
waitinput 30000
END
 
XProfan 11
Computer: Gerät, daß es in Mikrosekunden erlaubt, 50.000 Fehler zu machen, zB 'daß' statt 'das'...
05/22/21  
 



Zum Quelltext


Topictitle, max. 100 characters.
 

Systemprofile:

no Systemprofil laid out. [anlegen]

XProfan:

 Posting  Font  Smilies  ▼ 

Please register circa a Posting To verfassen.
 

Topic-Options

1.420 Views

Themeninformationen

this Topic has 1 subscriber:

p.specht (1x)


Admins  |  AGB  |  Applications  |  Authors  |  Chat  |  Privacy Policy  |  Download  |  Entrance  |  Help  |  Merchantportal  |  Imprint  |  Mart  |  Interfaces  |  SDK  |  Services  |  Games  |  Search  |  Support

One proposition all XProfan, The there's!


My XProfan
Private Messages
Own Storage Forum
Topics-Remember-List
Own Posts
Own Topics
Clipboard
Log off
 Deutsch English Français Español Italia
Translations

Privacy Policy


we use Cookies only as Session-Cookies because of the technical necessity and with us there no Cookies of Drittanbietern.

If you here on our Website click or navigate, stimmst You ours registration of Information in our Cookies on XProfan.Net To.

further Information To our Cookies and moreover, How You The control above keep, find You in ours nachfolgenden Datenschutzerklärung.


all rightDatenschutzerklärung
i want none Cookie