D e s i g n S c r i p t L a n g u a g e S u m m a r y P a g e 1

Size: px
Start display at page:

Download "D e s i g n S c r i p t L a n g u a g e S u m m a r y P a g e 1"

Transcription

1 D e s i g n S c r i p t L a n g u a g e S u m m a r y P a g e 1 This manual is designed fr tw types f readers. First, thse wh want t make an initial fray int text based prgramming and wh may be currently using a visual prgramming envirnment such as Dynam. Secnd, thse users wh have sme scripting r prgramming experience and want harness a visual prgramming envirnment in rder t access the related gemetry and applicatin libraries. DesignScript therefre acts as a tw-way bridge between visual prgramming and text based prgramming. Visual data flw prgramming uses incredibly simple rules fr cnnecting ndes tgether. All ndes fllw this simple graph-nde cnventin allwing the user t easily discver mre functinality even frm unfamiliar ndes. As a result visual prgramming has an intuitive, easy access quality and allws the user with the minimum f training t be immediately prductive and t explre new functinality. Hwever this initial ease f use advantage f visual prgramming can als becme a disadvantage. As mre ndes are added t the graph and as mre f the arcs between the ndes crss the whle visual effect becmes very cmplex and eventually difficult t read. Essentially, the mment has cme fr the user t think abut a mre succinct way t represent his prgram lgic. The next step int text based prgramming necessarily requires the acquisitin f a number f new cncepts, precisely defined terminlgy and unfamiliar syntax. There is mre t learn but much mre t be gained frm text based prgramming than is pssible with visual prgramming. Text based prgramming languages are mre expressive. They use many mre cncepts and allw these t be cmbined in many mre ways. This manual is based n the idea that the path t being a prductive, expressive and accmplished prgrammer is thrugh investing in this barder understanding f the cncepts, terminlgy and rules f prgramming. By learning DesignScript users will acquire familiarity with the well-established prgramming cnventins that are transferrable t ther prgraming languages. In additin DesignScript builds n these established cnventins t ffer additinal and unique ways f prgramming nt supprted by ther languages. We can start by building n the experience f visual prgramming. While visual prgraming appears t be cmpletely intuitive, nly requiring the cnnecting tgether f ndes, it actually intrduces sme imprtant prgramming cncepts: Dependency and autmatic change prpagatin The cncept f type Replicatin Zer based indexing The cncept f an executable prgramming statement, with dependent and independent variables [the Cde Blck nde essentially unifies visual data flw prgramming with text based prgramming using executable prgramming statements [Sectin TBC] While this manual fcusses n the functinality and syntax f the DesignScript language, there is still sme minimal mechanics f use which have t be presented in rder t write and execute a DesignScript prgram. Mst users will access DesignScript thrugh the Dynam user interface either by creating a visual prgram [1]. Dynam uses the DesignScript language, cmpiler and executin prcessr as its cmputatinal engine. When using the Dynam visual data flw prgramming envirnment, the user may nt be aware that each nde is in fact a DesignScript statement. The Nde t Cde functinality [2] can be used t create the equivalent DesignScript prgram in a cde blck nde [3]. Effectively the nde t cde simply expses the underlying DesignScript cde previusly hidden within the Dynam nde and prvides a cnvenient and accessible path fr the nvice prgrammer between visual and text based prgramming [4]. Hwever, we can immediately bserve that the resulting generated DesignScript cde is n mre than a ne-t-ne translatin f the riginal visual prgram. Each line f DesignScript crrespnds t a nde in the graph. Nde t Cde is very useful t create an initial prgram, but it is ften advisable t refine this by editing the generated DesignScript cde, fr example by chsing mre infrmative names fr the variables r by cmbining statements s as the remve the need fr intermediate variables [5]. This ability t write multiple statements t be written within ne nde, further reducing the visual cmplexity f the graph. Rather than creating a visual prgram and cnverting it t DesignScript via the nde-tcde functinality, DesignScript cde can be directly written int an empty cde blck nde.

2 D e s i g n S c r i p t L a n g u a g e S u m m a r y P a g e 2 There are a number f advantage f the Cde Blck nde. As the user writes his DesignScript prgram any variable used in the expressin n the right hand side f the = sign has an input prt autmatically created fr it n the left hand side f the cde blck nde and any variable which exists n the left hand side f the = sign (whse value is being calculated) has an utput prt autmatically created fr it n the right hand side f the Cde Blck nde. This enables the user t cnnect a cde blck nde t the necessary input and utput blcks in the rest f his visual prgram. By cnventin visual data flw prgrams are based n a left-t-right flw, with inputs n the left and utputs n the right. By cnventin prgram statements are based n right t left flw, with the evaluatin f an expressin n the right, whse value is assigned right-t-left [represented by the = ] t a dependent variable n the left. Fitting a cnventinal [right t left] prgram statement int a data flw [left t right] visual cnventin is smewhat cnvluted. The user can edit the DesignScript cde, and when Dynam is running in autmatic mde, simply clicking utside the nde (fr example n the canvas ) autmatically executes DesignScript. All the examples in this manual can be cpied int a Dynam Cde Blck nde and run. It is imprtant t nte that the DesignScript language is independent f Dynam. Fr example, Dynam als implements a number f useful gemetric and dmain specific functins which can be prgrammed using DesignScript. We will use examples f these gemetric classes and methds t illustrate the features f the DesignScript language. Hwever, it shuld be nted that these classes and methds are nt part f the DesignScript language. Other libraries, including gemetry libraries can be built using C# develpment tls perating within the Zer Tuch cnventins, and the resulting DLL s can be laded int Dynam using the file/imprt cmmand and accessed via the Dynam UI and DesignScript. There are sme aspects f DesignScript which are currently nt supprted thrugh the Dynam User Interface, but these can be accessed by using a regular text editr t create a DesignScript surce file [with the.ds extensin]. These files can als be laded using the Dynam file/imprt cmmand.

3 D e s i g n S c r i p t L a n g u a g e S u m m a r y P a g e 3 DesignScript supprt tw styles f prgramming: Imperative and Data Flw [smetimes referred as Assciative prgramming] and has functinality which is cmmn t bth styles. Data Flw prgramming is essentially a text based versin f a visual prgraming using a graph r ndes and arcs (as in Dynam). Data flw prgraming whether visual r text based uses the cncept f graph dependencies t establish 'flw cntrl and is useful fr mdeling cmplex peratins (such as gemetric prcesses) applied t cllectin f bjects, in a very succinct prgramming style with autmatic change prpagatin. Data Flw prgramming is particularly relevant t users wh are currently using visual prgramming and wh are new the text based prgraming. Imperative prgramming is characterized by explicit 'flw cntrl' using fr lps (fr iteratin) and if statements (fr cnditinals) as fund in familiar scripting and prgramming languages such as Pythn, C# r Java. Imperative prgramming is useful t perfrm iteratin, either stepping thrugh a cllectin r t perfrm sme iterative feedback r ptimisatin lp. Imperative prgramming can als be used fr cmplex cnditinal lgic. Imperative prgramming is particularly relevant t users wh have experience with existing scripting and prgramming languages. The tw styles f prgramming address different cmputatinal tasks and essentially cmplement each ther. The different styles f prgramming share a cmmn ntatin which means that in sme case the same cde can be executed either as data flw r imperatively. In additin there are certain cmputatinal tasks that benefit frm a cmbinatin f prgramming styles within the same prgram r indeed within the same functin r methd Aspects f DesignScript that are cmmn t bth Assciative and Imperative prgramming: Types: In DesignScript the explicit typing f variables during declaratin is ptinal. Hwever there are certain peratins where a particular type f variable is expected. Als different functins and methds may expect arguments f a defined type. S while variables d nt have t be explicitly typed, the type they have at runtime may affect the behaviur f the prgram. At the start f writing a prgram it may be a helpful strategy t use untyped variables, particularly when the prgrammer is in an explratry mde and when flexibility is required t explre the ptin fr variables t have different types f values. Predefining the type f a variable reduces this flexibility and may inhibit explratin. Hwever as the prgram matures, the prgrammer may want t be mre explicit abut the type f different variables and t use explicit typing as part f the errr checking prcess in his prgram. Built-in types: DesignScript supprts the fllwing built-in types: int, duble, bl, string a : int = 10; // whle numbers, typically used fr cunters, indices, etc b : duble = 5.1; // with a decimal flating pint c : bl = true; // r false d : string = "hell wrld"; e = null; // undefined Optinal use f type : DesignScript supprt bth typed and un-typed variables The type f a variable can be defined using the syntax variablename : type; variablename : type = expressin; // initialize a variable with a value In the absence f the type f a variable being explicitly defined, the type f a variable takes the type f the value assigned t it a = 10; // variable 'a' has n predefined type, // but assumes the 'int' type by having an int (the value 10) assigned t it Default type: DesignScript has a default type called var. a : var; // the variable a is declared, but f an undefined type

4 D e s i g n S c r i p t L a n g u a g e S u m m a r y P a g e 4 Declaring variables: DesignScript gives cmplete freedm t the prgrammer, as fllws: a; // the variable is untyped and can have any value assigned t it b = null; // the variable is untyped and can have any value assigned t it c : var; // the variable is untyped and can have any value assigned t it d : int; // the variable is declared as a single int e : int[]; // the variable is declared as a 1D cllectin f int's: all member must be int's f : int[][]; // the variable is declared as a 2D cllectin f int's: all member must be int's g : int[]..[]; // the variable can be a single int r a cllectin f int's f any dimensin h = ; // the variable is an empty cllectin f any type and can als be a single value [Nte: the use f the int type (abve) is purely illustrative. Any type can be used, as apprpriate.] In summary: A variable can be untyped and therefre can be a single value f any type r a cllectin f any dimensin f any type. Or a variable can be declared as a single value r as a cllectin f a specified dimensin, r as a cllectin f any dimensin; and the variable can be typed r untyped. If it is imprtant t declare the type f the variable and it is anticipated that a variable may be a single value r a cllectin f values, then the declaratin variable : type[]..[]; shuld be used. If it is imprtant t declare the type f the variable and it is anticipated that a variable culd be f mre than ne type, then the type declared shuld be the mst specialised cmmn super type f the anticipated values fr this variable. Fr example, if a variable culd be a Line r an Arc, then it shuld be declared as variable : Curve; [as the cmmn super type] Similarly, if it is imprtant t declare the type f a cllectin variable and, if it is anticipated that the variable will be a hetergeneus cllectin, then the type f the cllectin shuld the mst specialised cmmn super type f the anticipated members. Fr example, if a variable cllectin culd cntain members that are Line r Arc, then the cllectin shuld be declared as variable : Curve[]; [as the cmmn super type] r variable : Curve[]..[]; if it is anticipated that the dimensin f the cllectin may change. Therefre (mre generally) the users shuld check the class hierarchy f the libraries he is using t ensure that he has selected the apprpriate cmmn super type. Cllectins: can be defined with the ntatin and evaluated by the Cunt() and Rank() functins a = 1, 2, 3, 4; // a 1D cllectin defined using the ntatin, with a list f values b = Rank(a); // b = 1 c = Cunt(a); // c = 4 d = 1, 2, 3, 4 ; e = Rank(d); // d = 4 f = Cunt(d); // f = 4 Range Expressin: range expressin can be used t generate numeric cllectins, in the frm start..end..inc a = 1..5; // a = 1,2,3,4,5 start..end [using 1 as the default increment] Dynam 'Range' nde b = ; // b = 1,3,5,7,9 start..end..increment Dynam 'Range' nde c = ~3; // c = 1.0, , , 9.0 start..end..~apprximateincrement d = #3; // d = 1, 5, 9 start..end..#nofcases e = 1..#3..9; // e = 1, 10, 19 start..#nofcases..increment Dynam 'Sequence' nde Indexing: the members f a cllectin can be accessed using indices and the [] ntatin a = 1..9; // a = 1,2,3,...7, 8, 9.. using the default increment f '1' b = a[0]; // b = 1 in DesignScript as with ther languages, indexing starts frm zer c = a[-1] ; // c = 9 negative indexing cunts back frm the end f the cllectin d = a[ ]; // d = 2, 4, 6 a cllectin f int s can be used t select a sub cllectin, // via a range expressin e = a[ 2, 3, 0 ]; // d = 3,4,1 a cllectin f int s can be used t select a sub cllectin, // via sme arbitrary cllectin f = Cunt(a); // f = 9 using the Cunt() functin Nte: the fllwing cde will fail g = a[cunt(a)]; // because indexing starts at zer, the last member f a cllectin is at [Cunt(a)-1].. This prvides the mtivatin fr negative indexing where: a[cunt(a)-1] is equivalent t a[-1] (the cunt f a is applied autmatically)

5 D e s i g n S c r i p t L a n g u a g e S u m m a r y P a g e 5 Rectangular Cllectin: is a cllectin where all sub cllectins are the same dimensin and length a = 1, 2, 3, 4 ; // a rectangular 2D cllectin b = Cunt(a[0]); // b = 2 bth the a[0] and a[1] subcllectins and have the same length c = Cunt(a[1]); // c = 2 Ragged Cllectin: is a cllectin where sub cllectins may have different dimensins and lengths a = 1, 2, 3, 4, 5, 6 ; // a ragged 2D cllectin b = Cunt(a[0]); // b = 2 a[0], a[1] and a[2] are subcllectins f different lengths c = Cunt(a[1]); // c = 3 d = Cunt(a[2]); // d = 1 Flexible cllectin building: DesignScript supprts flexible and direct ways t build cllectins h = ; h[2] = 5; // h = null, null, 5 here, a variable can be defied as a member f a cllectin, // prvided that cllectin has been previus defined. The values f the // members f the cllectin prir t member which is explicitly defined will be null h[1] = 4,5,6; // h = null 4, 5, 6, 5 here, a member f cllectin that was riginally a single value // (r a sub cllectin f a particular dimensin) can be directly replaced by a different // single value r by a cllectin f a different dimensin In additin there are a number f functins available t build and manipulate cllectins, including t Insert, Remve and test fr the presence f members in a cllectin [see the Language Functin tab in the DesignScript class library dcumentatin] TBC dcumentatin f the fllwing functins: IsHmgeneus, IsRectangular, InUnifrmDepth, NrmalizeDepth, Flatten, Insert, Cntains, IndexOf, Equals, User defined types: these are types defined as classes within DesignScript r via imprted DLL s. DesignScript is an bjectriented language and uses the standard terminlgy f class, subclass, superclass, cnstructr, methd, arguments and instance, as in: instance = Class.Cnstructr(arg1, arg2, argn); A variable is an instance f a class using a particular named cnstructr r methd with varius input arguments. Optinal typing and the ability f a variable t change type: We have seen that variables need nt be explicitly typed and that they can take n the type f the value assigned t them. It is therefre pssible fr a variable t change its type, and this may affect the validity f hw it is referenced in subsequent language statements, as illustrated by this example: WCS = CrdinateSystem.Identity(); // define the wrld crdinate system; a = Line.ByStartPintEndPint(Pint.ByCartesianCrdinates(WCS, 5, 5, 0), Pint.ByCartesianCrdinates(WCS, 10, 5,0)); // create variable a as instance f the Line class b = a.pintatparameter(0.5); // referencing variable linea t make the variable pint1 // [pint at parameter n the line]; a = Arc.ByThreePints(Pint.ByCartesianCrdinates(WCS, 5, 5, 0), Pint.ByCartesianCrdinates(WCS, 5, 7, 0), Pint.ByCartesianCrdinates(WCS, 10, 10, 0)); // variable a is an instance f the Arc class // the methd PintAtParameter is still valid because this is // defined n the Curve class f which Line and Arc are subclasses In this example, variable b is still valid because the.pintatparameter() methd is defined in the Curve class and Line and Arc are bth subclasses f Curve. These issues, particularly with reference t gemetry are discussed in mre detail in the subsequent sectin in this manual n Gemetry [pages 20-22]. Mre generally, it is pssible fr a variable t be defined withut a type r t change its type. Hwever, when it is referenced (either as an instance used with a methd r as an argument) then it may be required t be f specific type. Therefre the users shuld check the class hierarchy f the libraries he is using t ensure that such type changes are valid.

6 D e s i g n S c r i p t L a n g u a g e S u m m a r y P a g e 6 Prperties: user defined types (r classes) can have prperties which are accessed via the. peratr [the dt peratr] Prperties may have a defined type. a = Pint.ByCrdinates(5,5,0); b = a.x; // b = 5.. access the X crdinate prperty f the Pint variable 'a' Nte: mst prperties f the gemetry bjects in PrtGemetry are read nly and cannt be assigned t. A cnstructr [such as Pint.ByCrdinates(5,5,0);] is effectively setting a set f related (and sufficient) prperties in ne g. DesignScript intentinally restricts the change f a single prperty [such as the X crdinate f a pint] in islatin, utside the knwn cntext prvided by such methd. a.x = 10; // nt allwed, instead a methd shuld be used t define a.x in the cntext f ther prperties Imperative Prgramming: accessed via the [Imperative]directive applied t a blck: Imperative prgramming is useful t perfrm iteratin, either stepping thrugh a cllectin r t perfrm sme iterative feedback r ptimisatin lp. Imperative prgramming uses cnventinal fr and while lps and if.. else statements t explicitly define flw cntrl. Prgram executin: In the absence f such flw cntrl the next statement in the prgram is executed, fr example: 1 a; b; // define the variables t be utput at the tp r uter scpe 2 [Imperative] 3 4 a = 10; // riginal value f 'a' 5 b = a * 2; // calculating b based n the current value f a.. b = 20 6 a = 15; // changing the value f 'a' will NOT cause the value f 'b' t change 7 If this cde fragment is executed in single step debug, the fllwing sequence f statements will be executed: 4, 5, 6. Iteratin: defined by a fr lp, as: fr (variable in cllectin) defined by a while lp, as: while(cnditin_is_true).. An example f a fr lp: a= ; // declare an empty cllectin at the glbal scpe [Imperative] fr(i in 0..5) // fr lp a[i] = i; b = a; // b = 0, 1, 2, 3, 4, 5 An example f a while lp: a= ; // declare an empty cllectin at the glbal scpe i = 0; // define the initial value fr i [Imperative] while(i <=5) // test if I satisfies the defined cnditin a[i] = i; i = i+1; // increment i b = a; // b = 0, 1, 2, 3, 4, 5

7 D e s i g n S c r i p t L a n g u a g e S u m m a r y P a g e 7 Cnditinal: defined by an if..else statement as: if (cnditin_is_true) single_statement_if_true if (cnditin_is_true) statements_if_true if (cnditin_is_true) statements_if_true else statements_if_false An example f a if..else cnditinal embedded in a duble fr lp icunt = 4; jcunt = 5; resultpints = ; // define an empty cllectin [Imperative] fr(i in 0..iCunt) fr(j in 0..jCunt) if ((i == 0) (i == icunt) (j == 0) (j == jcunt)) // pints are the periphery f the array t mve dwn resultpints[i][j] = Pint.ByCrdinates(i, j, -1); else // pints are the periphery f the array t mve up resultpints[i][j] = Pint.ByCrdinates(i, j, 1);

8 D e s i g n S c r i p t L a n g u a g e S u m m a r y P a g e 8 A mre cmplex example f iteratin: surfacepints_2d_array : Pint[][]; // define a 2D array f Pints surface : NurbsSurface; // define a surface [Imperative] xsize = 10; ysize = 15; xheight = 2; yheight = 4; numclsx = 8; numclsy = 6; fr(i in 0..numClsX) fr(j in 0..numClsY) surfacepints_2d_array[i][j] = Pint.ByCrdinates( i * (xsize / numclsx), // x crdinates j * (ysize / numclsy), // y crdinates (Math.Sin(i * (180 / numclsx)) * xheight) + (Math.Sin(j * (180 / numclsy)) * yheight) ); // z crdinates surface = NurbsSurface.ByPints(surfacePints_2D_array).SetClr(Clr.Cyan); // create a surface Cmpare this script with the same gemetry created Assciatively n Page 10.

9 D e s i g n S c r i p t L a n g u a g e S u m m a r y P a g e 9 Assciative Prgramming: accessed via the [Assciative]directive: Assciative prgramming uses the cncept f graph dependencies t establish 'flw cntrl.' Changes t 'upstream' variables are autmatically prpagated t dwnstream variables. Assciative prgramming in DesignScript als implements tw additinal cncepts: replicatin and mdifiers. With replicatin, anywhere a single value is expected a cllectin may be used instead and the executin is autmatically replicated ver each element. The cmbined result f dependencies and replicatin is that is easy t prgram cmplex data flws (including gemetric peratins) invlving cllectins. An upstream variable may change frm being a single value t a cllectin r frm a cllectin t anther cllectin f different dimensins r size, s the dwnstream dependent variables will autmatically fllw suit and als becme cllectins f the apprpriate dimensin and size. This makes Assciative prgramming incredibly pwerful, particularly in the cntext f generating and cntrlling design gemetry. With mdifiers, each variable can have multiple states, which might reflect the gemetric mdeling sequence. Fr example a gemetric variable might be created (say as a curve) and then it can be mdified by being trimmed, prjected, extended, transfrmed r translated. Withut the cncept f mdifiers each state r mdeling peratin wuld require t be a separate variable and this wuld frce the user t have t make up the names f all these intermediate variables. Mdifiers avid impsing this naming prcess n the user. Dependencies, replicatin and mdifiers can all be cmbined t represent the typical mdeling peratins fund in architectur e and cnstructins. Buildings are cmpsed f cllectins f cmpnents. Typically these cllectins are ften the prduct f a series f standard peratins acrss all members. On the ther hand, within such cllectins there may be special cnditins where different r additinal mdeling peratins are required t be applied t a sub cllectin f members. Mdifiers enable these special cnditins t be identified and fr additinal mdeling peratin applied. Assciative prgramming invlves the fllwing cncepts: Assignments and Dependencies In assciative mde, except where therwise nted, all DesignScript statement are f the frm: variable = expressin; fr example: a = 10; // a is defines as int with the value 10; b = a * 2; // b is defined by the expressin 'a * 2' These statements define relatinships between the variable (n the left hand side f the statement) and references t ther variables within the expressin (n the right hand side f the statement). These relatinships define a graph. [Nte: In the fllwing cde fragment, we have added line numbers s as t be able t describe the executin rder. These line numbers shuld be remved befre executing these fragments in DesignScript] 1 a; b; // define the variables t be utput at the tp r uter scpe a = 10; // riginal value f 'a' 5 b = a * 2; // define b as dependent n a.. b initially = 10, then = 30 6 a = a + 5; // changing the value f 'a' will change the value f 'b' (nw = 30) 7 If this cde fragment is executed in single step debug, the fllwing sequence f statements will be executed: 4, 5, 6, 5. In assciative prgramming, statement 5 is nt just executed nce (in sequence, after statement 3). In assciative prgramming, statement 5 establishes a persistent relatinship between the variable b and variable a. When the value f variable a is re-defined in statement 6, the Assciative update mechanism in DesignScript will execute all statements that depend n variable a, which (in this example) includes statement 5. Hence the executin sequence: 4, 5, 6, 5. This can be cmpared t the exact same cde fragment executed imperatively, as fllws: 1 a; b; // define the variables t be utput at the tp r uter scpe 2 [Imperative] 3 4 a = 10; // riginal value f 'a' 5 b = a * 2; // calculating b based n the current value f a.. b = 10 6 a = a + 5; // changing the value f 'a' will NOT cause the value f 'b' t change 7 If this cde fragment is executed in single step debug, the fllwing sequence f statements will be executed: 4, 5, 6. In imperative prgramming, statement 5 is just executed nce (in sequence, after statement 3). In imperative prgramming, statement 5 des nt establish a persistent relatinship between the variable b and variable a.

10 D e s i g n S c r i p t L a n g u a g e S u m m a r y P a g e 10 Cllectins and Replicatin: a cllectin can be used where a single value is expected 1 a; b; // define the variables t be utput at the tp r uter scpe a = 10; // riginal value f a 5 b = a * 2; // define b as dependent n a 6 7 a = 5, 10, 15 ; // redefine a as a cllectin.. the value f b is nw = 10, 20, 30 In this example, when a becmes a cllectin f values, the expressin a * 2 is executed fr every member f a and the resulting cllectin f values are assigned t b. In assciative prgramming, the existence f variable as a cllectin is prpagated t all dependent variables, in this example b. This prpagatin f cllectins is called replicatin. Nte: The replicatin in this example is equivalent t the fllwing Imperative cde: a; b; // define the variables t be utput at the tp r uter scpe [Imperative] i = 0; a = 5, 10, 15 ; // define a as a cllectin.. fr(aa in a) b[i] = aa * 2; i = i + 1; // explicit 'fr' lp // the value f b is nw = 10, 20, 30 We can bserve that replicatin saves cnsiderable prgram space and prgrammer attentin. If this cde fragment is executed in single step debug, the fllwing sequence f statements will be executed: 4, 5, 6, 5. Nte that variables can be untyped, but if they are declared as typed then DesignScript assumes that the user wants t restrict the values that can be assigned t that variable and will reprt errrs if an errneus assignment is attempted. Fr example, if a and b are defined as single int s, belw: a : int; // explicitly defined as a single int b : int; // explicitly defined as a single int a = 10; b = a * 2; a = 5, 10, 15 ; // changed int an array f int's this will fail Zipped replicatin: When there are multiple cllectins within the same expressin, we need t cntrl hw these are cmbined. With zipped replicatin, when there are multiple cllectins, the crrespnding member f each cllectin is used fr each evaluatin f the expressin. This wrks well when all cllectins are the same dimensin and length. If cllectins are f different lengths, then the shrtest cllectins determines the number f times the expressin is evaluated, and hence the size f the resulting cllectin. a; b; c; // define the variables t be utput at the tp r uter scpe a = 1, 5,9; b = 2, 4,6; c = a + b; // zipped replicatin peratin.. c = 3, 9, 15 Cartesian replicatin cntrlled by Replicatin Guides When there are multiple cllectins, we need t cntrl hw these are cmbined. With cartesian replicatin, each member f ne cllectin is evaluated with every member f the ther cllectins, s that resulting cllectin is the cartesian prduct f the input cllectins. The rder in which the cartesian prduct is created is cntrlled by replicatin guides in the frm <n>, which define the sequence f the replicatin peratins. This must be a cntinuusly increasing sequence f int s starting at 1. This sequence is equivalent t the rder f the nested fr lps that wuld have had t be written in an Imperative script

11 D e s i g n S c r i p t L a n g u a g e S u m m a r y P a g e 11 a; b; c; d; // define the variables t be utput at the tp r uter scpe a = 1, 5,9; b = 2, 4 ; c = a<1> + b<2>; // cartesian replicatin c = 3, 5, 7, 9, 11, 13 d = a<2> + b<1>; // changing the sequence f replicatin guides changes the resulting cllectin // d = 3, 7, 11, 5, 9, 13 Replicatin guides can be used in any expressin with any term which is a cllectin n matter where that cllectin appears in the expressin, fr example as arguments in a functin call r as a literal cllectin r as a range expressin. Using replicatin guides with arguments: a; b; c; d; // define the variables t be utput at the tp r uter scpe def intadd : int (first : int, secnd : int) = first + secnd; // define a functin a = 1, 5,9; b = 2, 4 ; c = intadd(a<1>, b<2>); // cartesian replicatin c = 3, 5, 7, 9, 11, 13 d = intadd(a<2>, b<1>); // changing the sequence f replicatin guides changes the // resulting cllectin d = 3, 7, 11, 5, 9, 13 Using f replicatin guides with range expressins: c; d; // define the variables t be utput at the tp r uter scpe c = (1..9..#3)<1> + ( )<2>; // cartesian replicatin c = 3, 5, 7, 9, 11, 13 d = (1..9..#3)<2> + ( )<1>; // changing the sequence f replicatin guides changes the // resulting cllectin d = 3, 7, 11, 5, 9, 13 Nte: in the term ((1..9..#3))<1>, the range expressin #3 has t wrapped in brackets s that the replicatin guide <2> applies t the resulting evaluatin the range expressin. If the term was #3<1> then the replicatin guide <1> wuld nly apply t the value 3. Using replicatin guides with Instance methds: Replicatin and replicatin guides can be used in any expressin which uses cllectins. This includes thse expressins where an instance methd is being called and the instance is a cllectin and the ther arguments t that methd are als cllectins. If n replicatin guides are used, then the result will be a zipped cllectin (as wuld be expected) a; b; a = Pint.ByCrdinates(1..5, 1, 0); b = a.translate(0, 1..5, 0); If replicatin guides are used, then the result will be a cartesian cllectin a; b; a = Pint.ByCrdinates(1..5, 1, 0); b = a<1>.translate(0, (1..5)<2>, 0); Nte: the syntax t apply replicatin guides t an instance variable that is a cllectin. The replicatin guide cmes immediately after the term t which it is t be applied.

12 D e s i g n S c r i pt L a n g u a g e S u m m a r y P a g e 12 Cmbining zipped and cartesian replicatin In the fllwing example, we are taking the cartesian prduct f ne 1D array and anther 1D array [t create an intermediate 2D array) and then 'zipping' this intermediate 2D array with anther 2D array surfacepints_2d_array : Pint[][]; // define a 2D array f Pints surface : NurbsSurface; // define surface xsize = 10; ysize = 15; xheight = 2; yheight = 4; numclsx = 8; numclsy = 6; xcrds_1d_array ycrds_1d_array = 0..xSize..#numClsX; // 1D array = 0..ySize..#numClsY; // 1D array xsinewave_1d_array = (Math.Sin( #numClsX) * xheight); ysinewave_1d_array = (Math.Sin( #numClsY) * yheight); // 1D array // 1D array zheight_2d_array = xsinewave_1d_array<1> + ysinewave_1d_array<2>; // using cartesian replicatin // adding a 1D array t anther 1D array creates a 2D array surfacepints_2d_array = Pint.ByCrdinates(xCrds_1D_array<1>, ycrds_1d_array<2>, zheight_2d_array<1><2>); // this peratin is taking the cartesian prduct f xcrds_1d_array and ycrds_1d_array // [t create a 2D array) and then 'zipping' this 2D array with zheight_2d_array surface = NurbsSurface.ByPints(surfacePints_2D_array); // create a surface Cmpare this script with the same gemetry created Imperatively n Page 7. Nte: replicatin wrks well with rectangular cllectin, but the results may be undefined when used with ragged cllectins. Mdifiers: a variable can have a sequence f states As we have seen, a variable may be defined in ne statement (where it is n the left hand side f the = sign and has a value assigned t it) and a variable may be referenced in a subsequent expressin (n the right hand side f the = sign). a = 10; // a is defines as int with the value 10; b = a * 2; // b is defined by the expressin 'a * 2' We nw intrduce the cncept in Assciative prgramming f a mdifier in which a previusly defined variable appears n bth left and right hand side f statement, s as t have its riginal value mdified. a; b; // define the variables t be utput at the tp r uter scpe a = 10; // riginal value f a b = a *2; // define b as dependent n a a = a + 1; // mdify a t be 1 mre than its riginal value. nw a = 11 // the value f b is nw = 22 Essentially, the variable a has multiple states

13 D e s i g n S c r i pt L a n g u a g e S u m m a r y P a g e 13 state 1: a = 10; // riginal value f a state 2: a = a+1; // mdify a t be 1 mre than its riginal value. nw a = 11 when a variable is referenced, the value f its final state is used. In this case, when the statement b = a *2; is evaluated, the value f the secnd (and final) state f a is used (i.e. 11) Mdifiers are extremely useful t represent cmpund mdeling peratins, fr example: start = Pint.ByCrdinates(10, 0, 0); end = Pint.ByCrdinates(10, 5, 0); a = Line.ByStartPintEndPint(start, end); a = a.parametertrim(0.2, 0.8); // trim the line; a = a.translate(1, 1, 0); // mve the trimmed line; Mdifiers avid having t give a separated variable name t each peratin. In this case the intermediate states f are nt visible r accessible. Alternatively, the methds can be chained tgether start = Pint.ByCrdinates(10, 0, 0); end = Pint.ByCrdinates(10, 5, 0); a = Line.ByStartPintEndPint(start, end).parametertrim(0.2, 0.8).Translate(1, 1, 0); If intermediate states are required t be accessible, then each state must be assigned t a different variable: start = Pint.ByCrdinates(10, 0, 0); end = Pint.ByCrdinates(10, 5, 0); a = Line.ByStartPintEndPint(start, end); b = a.parametertrim(0.2, 0.8); // trim the line; c = b.translate(1, 1, 0); // mve the trimmed line; Mdifying a member f cllectin: A member f a cllectin can be mdified, withut breaking the integrity f the cllectin. a; b; // define the variables t be utput at the tp r uter scpe a = ; // initially a = 1,5,9 b = a *2; // define b as dependent n a, b initially = 2, 10, 18 // subsequently b = 2, 10, 2 a[-1] = a[-1] + 1; // mdify a member f the cllectin // a = 1,5,10 nte: use f negative indexing frm the end f the cllectin Because a member f the cllectin a has been mdified, this will trigger a re-cmputatin f dependent statement b = a *2; Hwever, this re-cmputatin will use the cllectin a including the mdificatin t a[-1] The use f mdifier saves having t use explicit names fr the intermediate states in a sequence f mdelling peratins. Summary: A statement where the variable n the left hand side is als referenced within the expressin n the right hand side is effectively a mdifier f that variable, e.g. a = a + 1; In-line cnditinal: an in-line cnditinal is defined as: variable = blean_expressin? expressin_if_true : expressin_if_false; fr example: a; b; // define the variables t be utput at the tp r uter scpe a = 4; // variable a as a single value b = a<2?10:20; // make the value f 'b' depend cnditinally n the value a : b = 20; //

14 D e s i g n S c r i pt L a n g u a g e S u m m a r y P a g e 14 In-line cnditinal with a cllectin A new cllectin can be built frm an existing cllectin, using replicatin, where the individual members f the existing cllectins are evaluated, and the expressin_if_true and the expressin_if_false are used t build the new cllectin, fr example: a; b; // define the variables t be utput at the tp r uter scpe a = 0..5; // 'a' = 0, 1, 2, 3, 4, 5 b = a<2?10:20; // 'b' = 10, 10, 20, 20, 20, 20; // build cllectin 'b' by evaluating // each member f the cllectin 'a' Understanding the differences between Assciative and Imperative prgramming: Assciative prgramming supprts graph based dependencies and uses: replicatin and replicatin guides, mdifiers in assciative prgramming a prgram statement nt nly defines that the value f a variable will be calculated based n references t ther variables, but als defines a persistent dependency relatinship between the variable whse value is being cmputed and the references t the ther variables. nce a dependencies has been established, a subsequent change t these ther variables in successive statements will cause the variable t be recmputed. In single-step debug mde the executin cursr may apparently mve backwards thrugh the surce cde as statements are executed and the value f variables are recmputed based n these dependencies. in the absence f graph based dependencies, statements are executed in lexical rder Imperative prgramming supprts explicit flw cntrl : iteratin with fr and while lps cnditinals with if..else statements in the absence f such flw explicit cntrl statements are executed in lexical rder in imperative prgramming a prgram statement defines the value f a variable t be calculated based n references t ther variables, but this is a ne-time peratin. A subsequent change t these ther variables in successive statements des nt cause the variable t be recmputed. frward references are nt allwed: a variable cannt be cmputed frm variables which have yet t been defined. Additinal functinality cmmn t bth Assciative and Imperative language interpretatin: Functins are first class elements f the language, Functin must be defined in the glbal scpe (the utermst blck) Functins are defined using the def key wrd as: def functin_name (argument_list) prgram statements def functin_name : return_type (argument_list) prgram statements The argument_list is a cmma separated list, with ptinal types By cnventin functin names start with an uppercase letter and argument names start with a lwer case letter. Fr example, with untyped arguments def f(x) = x * 5; // x is untyped, but the functin will fail if it is nt an int r a duble The functin can be called with different arguments.. sme which wrk and thers which fail: a = f(10); // a = 50.. with an int b = f(10.1); // b = with a duble c = f(mypint); // c = null.. representing failure

15 D e s i g n S c r i pt L a n g u a g e S u m m a r y P a g e 15 Functin Overlading it is pssible t have multiple definitins f the same functin with different types f arguments, fr example: def f(x : int) = x * 5; // x as an int def f(x : duble) = x * 4.0; // x as an duble def f(x : Pint) = x.translate( 6.0, 0, 0); // x as a Pint In additin the type f the return argument can be explicitly defined, fr example: def f : int (x : int) = x * 5; // x as an int def f : duble (x : duble) = x * 4.0; // x as an duble def f : Pint (x : Pint) = x.translate( 6.0, 0, 0); // x as a Pint In the Dynam UI use defined functins are immediately recgnized and in this case because there are verladed functins with the same name, the autcmplete ffers the user the alternative versins f the functins. Depending n the type f the argument the apprpriate versin f the functin will autmatically be called, but if an argument is prvided fr which there is n verladed methd, then this will fail. a = f(10); // a = 50.. with an int: DesignScript will call: def f:int (x : int) b = f(10.1); // b = with a duble: DesignScript will call: def f:duble(x : duble) c = f(mypint); // c = mypint translated : DesignScript will call: def f:pint(x : Pint) d = f(yurline); // d = null.. DesignScript will call: def f(x) which will fail A functin may have a single statement, f the fllwing frm: def f(x) = x * 5; Or alternatively a functin may have multiple statements, in which the last must be a return statement defined using the return keywrd, in the frm: return = expressin; A functin can return any type. The return statement shuld be the last statement f the functin and nt nested within a blck, fr example: def f : int (x) y : int; y = x * 5; return = y + 1; // define a lcal variable // use the lcal variable tgether with arguments // define a return value Scping issues with functins. If we cnsider the functin definitin f, abve and within the same script have the statements Generally, all variables within a functin must either be defined lcally r must be passed in as arguments. The fllwing examples shw varius cnditins where variable which are in scpe are used within the functin, but the functin wuld fail if the scpe changed r the variable referenced was n lnger available. This culd be the rigin f majr prgramming errrs. y = 1; z = f(y+10); then because the variable y is defined bth in the uter scpe f the functin and within the functin, the executin f f will change the value f y in the uter scpe. This kind f side effect is ptentially a surce f errrs. In the case abve, a variable was being assigned t within a functin and had the same name as a variable in the main script, but whether r nt the variable was present in the main script the functin wuld still execute. In the next example, a variable in the uter scpe is referenced in a functin

16 D e s i g n S c r i pt L a n g u a g e S u m m a r y P a g e 16 def f (x) return = y * x; // define a return value y = 2; z = f(10); // z = 20 If y is cmmented ut then it will nt be available within f and the functin will fail, belw: def f (x) return = y * x; // this will fail // y = 2; cmment ut y s that it is nt available within f z = f(10); // z = null This means that functin f can nly perate in the cntext where the variable y is defined in the uter scpe. One f the mtivatins fr creating a functin is that it can eventually be mved t a functin library and used mre generally. Fr the functin t fulfill this rle, it cannt reference variables in its uter scpe. As such when the cde is maturing it is ften helpful t ensure that all variables within a functin are defined lcally r are arguments. Prgramming with Functins: Functins are first class features f the DesignScript language and as such they can be assigned t variables and passed arguments, fr example: def innerf_1 (x : int) return = x * 5; def innerf_2 (x : int) return = x + 5; // define a return value // define a return value def uterf ( func : var, x : int) return = func(x); // call the functin y = uterf(innerf_1, 10); // y = 50.. call uterf with innerf1 z = uterf(innerf_2, 10); // z = 15.. call uterf with innerf2 In additin a cllectin f functins can be defined, and the apprpriate functin can be selected by indexing int the cllectin, fr example. fcllectin = innerf_1, innerf_2; z = uterf(fcllectin[-1], 10); // use the last functin in the fcllectin y = 15 Hwever, neither a DesignScript class nr a DesignScript methd can be an argument.

DesignScript summary:

DesignScript summary: DesignScript summary: This manual is designed fr thse readers wh have sme experience with prgramming and scripting languages and want t quickly understand hw DesignScript implements typical prgramming

More information

Eastern Mediterranean University School of Computing and Technology Information Technology Lecture2 Functions

Eastern Mediterranean University School of Computing and Technology Information Technology Lecture2 Functions Eastern Mediterranean University Schl f Cmputing and Technlgy Infrmatin Technlgy Lecture2 Functins User Defined Functins Why d we need functins? T make yur prgram readable and rganized T reduce repeated

More information

- Replacement of a single statement with a sequence of statements(promotes regularity)

- Replacement of a single statement with a sequence of statements(promotes regularity) ALGOL - Java and C built using ALGOL 60 - Simple and cncise and elegance - Universal - Clse as pssible t mathematical ntatin - Language can describe the algrithms - Mechanically translatable t machine

More information

Lab 1 - Calculator. K&R All of Chapter 1, 7.4, and Appendix B1.2

Lab 1 - Calculator. K&R All of Chapter 1, 7.4, and Appendix B1.2 UNIVERSITY OF CALIFORNIA, SANTA CRUZ BOARD OF STUDIES IN COMPUTER ENGINEERING CMPE13/L: INTRODUCTION TO PROGRAMMING IN C SPRING 2012 Lab 1 - Calculatr Intrductin In this lab yu will be writing yur first

More information

Infrastructure Series

Infrastructure Series Infrastructure Series TechDc WebSphere Message Brker / IBM Integratin Bus Parallel Prcessing (Aggregatin) (Message Flw Develpment) February 2015 Authr(s): - IBM Message Brker - Develpment Parallel Prcessing

More information

Computer Organization and Architecture

Computer Organization and Architecture Campus de Gualtar 4710-057 Braga UNIVERSIDADE DO MINHO ESCOLA DE ENGENHARIA Departament de Infrmática Cmputer Organizatin and Architecture 5th Editin, 2000 by William Stallings Table f Cntents I. OVERVIEW.

More information

RISKMAN REFERENCE GUIDE TO USER MANAGEMENT (Non-Network Logins)

RISKMAN REFERENCE GUIDE TO USER MANAGEMENT (Non-Network Logins) Intrductin This reference guide is aimed at managers wh will be respnsible fr managing users within RiskMan where RiskMan is nt cnfigured t use netwrk lgins. This guide is used in cnjunctin with the respective

More information

CS1150 Principles of Computer Science Loops

CS1150 Principles of Computer Science Loops CS1150 Principles f Cmputer Science Lps Yanyan Zhuang Department f Cmputer Science http://www.cs.uccs.edu/~yzhuang CS1150 UC. Clrad Springs Annuncement HW1 graded HW2 due tnight HW3 will be psted sn Due

More information

CS1150 Principles of Computer Science Methods

CS1150 Principles of Computer Science Methods CS1150 Principles f Cmputer Science Methds Yanyan Zhuang Department f Cmputer Science http://www.cs.uccs.edu/~yzhuang CS1150 UC. Clrad Springs Opening Prblem Find the sum f integers frm 1 t 10, frm 20

More information

CS1150 Principles of Computer Science Midterm Review

CS1150 Principles of Computer Science Midterm Review CS1150 Principles f Cmputer Science Midterm Review Yanyan Zhuang Department f Cmputer Science http://www.cs.uccs.edu/~yzhuang CS1150 UC. Clrad Springs Office hurs 10/15, Mnday, 12:05 12:50pm 10/17, Wednesday

More information

Lab 0: Compiling, Running, and Debugging

Lab 0: Compiling, Running, and Debugging UNIVERSITY OF CALIFORNIA, SANTA CRUZ BOARD OF STUDIES IN COMPUTER ENGINEERING CMPE13/L: INTRODUCTION TO PROGRAMMING IN C SPRING 2012 Lab 0: Cmpiling, Running, and Debugging Intrductin Reading This is the

More information

TRAINING GUIDE. Overview of Lucity Spatial

TRAINING GUIDE. Overview of Lucity Spatial TRAINING GUIDE Overview f Lucity Spatial Overview f Lucity Spatial In this sessin, we ll cver the key cmpnents f Lucity Spatial. Table f Cntents Lucity Spatial... 2 Requirements... 2 Setup... 3 Assign

More information

Querying Data with Transact SQL

Querying Data with Transact SQL Querying Data with Transact SQL Curse Cde: 20761 Certificatin Exam: 70-761 Duratin: 5 Days Certificatin Track: MCSA: SQL 2016 Database Develpment Frmat: Classrm Level: 200 Abut this curse: This curse is

More information

CS5530 Mobile/Wireless Systems Swift

CS5530 Mobile/Wireless Systems Swift Mbile/Wireless Systems Swift Yanyan Zhuang Department f Cmputer Science http://www.cs.uccs.edu/~yzhuang UC. Clrad Springs cat annunce.txt_ imacs remte VNC access VNP: http://www.uccs.edu/itservices/services/netwrk-andinternet/vpn.html

More information

Chapter 6: Lgic Based Testing LOGIC BASED TESTING: This unit gives an indepth verview f lgic based testing and its implementatin. At the end f this unit, the student will be able t: Understand the cncept

More information

$ARCSIGHT_HOME/current/user/agent/map. The files are named in sequential order such as:

$ARCSIGHT_HOME/current/user/agent/map. The files are named in sequential order such as: Lcatin f the map.x.prperties files $ARCSIGHT_HOME/current/user/agent/map File naming cnventin The files are named in sequential rder such as: Sme examples: 1. map.1.prperties 2. map.2.prperties 3. map.3.prperties

More information

Lab 1 - Calculator. K&R All of Chapter 1, 7.4, and Appendix B1.2 Iterative Code Design handout Style Guidelines handout

Lab 1 - Calculator. K&R All of Chapter 1, 7.4, and Appendix B1.2 Iterative Code Design handout Style Guidelines handout UNIVERSITY OF CALIFORNIA, SANTA CRUZ BOARD OF STUDIES IN COMPUTER ENGINEERING CMPE13/L: INTRODUCTION TO PROGRAMMING IN C SPRING 2013 Lab 1 - Calculatr Intrductin Reading Cncepts In this lab yu will be

More information

Using the Swiftpage Connect List Manager

Using the Swiftpage Connect List Manager Quick Start Guide T: Using the Swiftpage Cnnect List Manager The Swiftpage Cnnect List Manager can be used t imprt yur cntacts, mdify cntact infrmatin, create grups ut f thse cntacts, filter yur cntacts

More information

CS1150 Principles of Computer Science Introduction (Part II)

CS1150 Principles of Computer Science Introduction (Part II) Principles f Cmputer Science Intrductin (Part II) Yanyan Zhuang Department f Cmputer Science http://www.cs.uccs.edu/~yzhuang UC. Clrad Springs Review Terminlgy Class } Every Java prgram must have at least

More information

Using the Swiftpage Connect List Manager

Using the Swiftpage Connect List Manager Quick Start Guide T: Using the Swiftpage Cnnect List Manager The Swiftpage Cnnect List Manager can be used t imprt yur cntacts, mdify cntact infrmatin, create grups ut f thse cntacts, filter yur cntacts

More information

Integrating QuickBooks with TimePro

Integrating QuickBooks with TimePro Integrating QuickBks with TimePr With TimePr s QuickBks Integratin Mdule, yu can imprt and exprt data between TimePr and QuickBks. Imprting Data frm QuickBks The TimePr QuickBks Imprt Facility allws data

More information

Lab 4. Name: Checked: Objectives:

Lab 4. Name: Checked: Objectives: Lab 4 Name: Checked: Objectives: Learn hw t test cde snippets interactively. Learn abut the Java API Practice using Randm, Math, and String methds and assrted ther methds frm the Java API Part A. Use jgrasp

More information

DECISION CONTROL CONSTRUCTS IN JAVA

DECISION CONTROL CONSTRUCTS IN JAVA DECISION CONTROL CONSTRUCTS IN JAVA Decisin cntrl statements can change the executin flw f a prgram. Decisin cntrl statements in Java are: if statement Cnditinal peratr switch statement If statement The

More information

Contents: Module. Objectives. Lesson 1: Lesson 2: appropriately. As benefit of good. with almost any planning. it places on the.

Contents: Module. Objectives. Lesson 1: Lesson 2: appropriately. As benefit of good. with almost any planning. it places on the. 1 f 22 26/09/2016 15:58 Mdule Cnsideratins Cntents: Lessn 1: Lessn 2: Mdule Befre yu start with almst any planning. apprpriately. As benefit f gd T appreciate architecture. it places n the understanding

More information

Relius Documents ASP Checklist Entry

Relius Documents ASP Checklist Entry Relius Dcuments ASP Checklist Entry Overview Checklist Entry is the main data entry interface fr the Relius Dcuments ASP system. The data that is cllected within this prgram is used primarily t build dcuments,

More information

Using CppSim to Generate Neural Network Modules in Simulink using the simulink_neural_net_gen command

Using CppSim to Generate Neural Network Modules in Simulink using the simulink_neural_net_gen command Using CppSim t Generate Neural Netwrk Mdules in Simulink using the simulink_neural_net_gen cmmand Michael H. Perrtt http://www.cppsim.cm June 24, 2008 Cpyright 2008 by Michael H. Perrtt All rights reserved.

More information

Extended Traceability Report for Enterprise Architect

Extended Traceability Report for Enterprise Architect Extended Traceability Reprt User Guide Extended Traceability Reprt fr Enterprise Architect Extended Traceability Reprt fr Enterprise Architect... 1 Disclaimer... 2 Dependencies... 2 Overview... 2 Limitatins

More information

COP2800 Homework #3 Assignment Spring 2013

COP2800 Homework #3 Assignment Spring 2013 YOUR NAME: DATE: LAST FOUR DIGITS OF YOUR UF-ID: Please Print Clearly (Blck Letters) YOUR PARTNER S NAME: DATE: LAST FOUR DIGITS OF PARTNER S UF-ID: Please Print Clearly Date Assigned: 15 February 2013

More information

Lab 5 Sorting with Linked Lists

Lab 5 Sorting with Linked Lists UNIVERSITY OF CALIFORNIA, SANTA CRUZ BOARD OF STUDIES IN COMPUTER ENGINEERING CMPE13/L: INTRODUCTION TO PROGRAMMING IN C WINTER 2013 Lab 5 Srting with Linked Lists Intrductin Reading This lab intrduces

More information

Data Structure Interview Questions

Data Structure Interview Questions Data Structure Interview Questins A list f tp frequently asked Data Structure interview questins and answers are given belw. 1) What is Data Structure? Explain. Data structure is a way that specifies hw

More information

LAB 7 (June 29/July 4) Structures, Stream I/O, Self-referential structures (Linked list) in C

LAB 7 (June 29/July 4) Structures, Stream I/O, Self-referential structures (Linked list) in C LAB 7 (June 29/July 4) Structures, Stream I/O, Self-referential structures (Linked list) in C Due: July 9 (Sun) 11:59 pm 1. Prblem A Subject: Structure declaratin, initializatin and assignment. Structure

More information

August 22, 2006 IPRO Tech Client Services Tip of the Day. Concordance and IPRO Camera Button / Backwards DB Link Setup

August 22, 2006 IPRO Tech Client Services Tip of the Day. Concordance and IPRO Camera Button / Backwards DB Link Setup Cncrdance and IPRO Camera Buttn / Backwards DB Link Setup When linking Cncrdance and IPRO, yu will need t update the DDEIVIEW.CPL file t establish the camera buttn. Setting up the camera buttn feature

More information

These tasks can now be performed by a special program called FTP clients.

These tasks can now be performed by a special program called FTP clients. FTP Cmmander FAQ: Intrductin FTP (File Transfer Prtcl) was first used in Unix systems a lng time ag t cpy and mve shared files. With the develpment f the Internet, FTP became widely used t uplad and dwnlad

More information

Interfacing to MATLAB. You can download the interface developed in this tutorial. It exists as a collection of 3 MATLAB files.

Interfacing to MATLAB. You can download the interface developed in this tutorial. It exists as a collection of 3 MATLAB files. Interfacing t MATLAB Overview: Getting Started Basic Tutrial Interfacing with OCX Installatin GUI with MATLAB's GUIDE First Buttn & Image Mre ActiveX Cntrls Exting the GUI Advanced Tutrial MATLAB Cntrls

More information

Please contact technical support if you have questions about the directory that your organization uses for user management.

Please contact technical support if you have questions about the directory that your organization uses for user management. Overview ACTIVE DATA CALENDAR LDAP/AD IMPLEMENTATION GUIDE Active Data Calendar allws fr the use f single authenticatin fr users lgging int the administrative area f the applicatin thrugh LDAP/AD. LDAP

More information

Using SPLAY Tree s for state-full packet classification

Using SPLAY Tree s for state-full packet classification Curse Prject Using SPLAY Tree s fr state-full packet classificatin 1- What is a Splay Tree? These ntes discuss the splay tree, a frm f self-adjusting search tree in which the amrtized time fr an access,

More information

Getting Started with the Web Designer Suite

Getting Started with the Web Designer Suite Getting Started with the Web Designer Suite The Web Designer Suite prvides yu with a slew f Dreamweaver extensins that will assist yu in the design phase f creating a website. The tls prvided in this suite

More information

Creating Relativity Dynamic Objects

Creating Relativity Dynamic Objects Creating Relativity Dynamic Objects Nvember 22, 2017 - Versin 9.3 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

More information

Common Language Runtime

Common Language Runtime Intrductin t.net framewrk.net is a general-purpse sftware develpment platfrm, similar t Java. Micrsft intrduced.net with purpse f bridging gap between different applicatins..net framewrk aims at cmbining

More information

Iteration Part 2. Review: Iteration [Part 1] Flow charts for two loop constructs. Review: Syntax of loops. while continuation_condition : statement1

Iteration Part 2. Review: Iteration [Part 1] Flow charts for two loop constructs. Review: Syntax of loops. while continuation_condition : statement1 Review: Iteratin [Part 1] Iteratin Part 2 CS111 Cmputer Prgramming Department f Cmputer Science Wellesley Cllege Iteratin is the repeated executin f a set f statements until a stpping cnditin is reached.

More information

Project #1 - Fraction Calculator

Project #1 - Fraction Calculator AP Cmputer Science Liberty High Schl Prject #1 - Fractin Calculatr Students will implement a basic calculatr that handles fractins. 1. Required Behavir and Grading Scheme (100 pints ttal) Criteria Pints

More information

Preparation: Follow the instructions on the course website to install Java JDK and jgrasp on your laptop.

Preparation: Follow the instructions on the course website to install Java JDK and jgrasp on your laptop. Lab 1 Name: Checked: (instructr r TA initials) Objectives: Learn abut jgrasp - the prgramming envirnment that we will be using (IDE) Cmpile and run a Java prgram Understand the relatinship between a Java

More information

ROCK-POND REPORTING 2.1

ROCK-POND REPORTING 2.1 ROCK-POND REPORTING 2.1 AUTO-SCHEDULER USER GUIDE Revised n 08/19/2014 OVERVIEW The purpse f this dcument is t describe the prcess in which t fllw t setup the Rck-Pnd Reprting prduct s that users can schedule

More information

Proper Document Usage and Document Distribution. TIP! How to Use the Guide. Managing the News Page

Proper Document Usage and Document Distribution. TIP! How to Use the Guide. Managing the News Page Managing the News Page TABLE OF CONTENTS: The News Page Key Infrmatin Area fr Members... 2 Newsletter Articles... 3 Adding Newsletter as Individual Articles... 3 Adding a Newsletter Created Externally...

More information

Lecture 6 -.NET Remoting

Lecture 6 -.NET Remoting Lecture 6 -.NET Remting 1. What is.net Remting?.NET Remting is a RPC technique that facilitates cmmunicatin between different applicatin dmains. It allws cmmunicatin within the same prcess, between varius

More information

It has hardware. It has application software.

It has hardware. It has application software. Q.1 What is System? Explain with an example A system is an arrangement in which all its unit assemble wrk tgether accrding t a set f rules. It can als be defined as a way f wrking, rganizing r ding ne

More information

Dashboard Extension for Enterprise Architect

Dashboard Extension for Enterprise Architect Dashbard Extensin fr Enterprise Architect Dashbard Extensin fr Enterprise Architect... 1 Disclaimer... 2 Dependencies... 2 Overview... 2 Limitatins f the free versin f the extensin... 3 Example Dashbard

More information

The Java if statement is used to test the condition. It checks Boolean condition: true or false. There are various types of if statement in java.

The Java if statement is used to test the condition. It checks Boolean condition: true or false. There are various types of if statement in java. Java If-else Statement The Java if statement is used t test the cnditin. It checks Blean cnditin: true r false. There are varius types f if statement in java. if statement if-else statement if-else-if

More information

UiPath Automation. Walkthrough. Walkthrough Calculate Client Security Hash

UiPath Automation. Walkthrough. Walkthrough Calculate Client Security Hash UiPath Autmatin Walkthrugh Walkthrugh Calculate Client Security Hash Walkthrugh Calculate Client Security Hash Start with the REFramewrk template. We start ff with a simple implementatin t demnstrate the

More information

Chapter-10 INHERITANCE

Chapter-10 INHERITANCE Chapter-10 INHERITANCE Intrductin: Inheritance is anther imprtant aspect f bject riented prgramming. C++ allws the user t create a new class (derived class) frm an existing class (base class). Inheritance:

More information

Creating Relativity Dynamic Objects

Creating Relativity Dynamic Objects Creating Relativity Dynamic Objects January 29, 2018 - Versin 9.5 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

More information

InformationNOW Letters

InformationNOW Letters InfrmatinNOW Letters Abut this Guide This Quick Reference Guide prvides an verview f letters in InfrmatinNOW. There are three types f letters: Student: May be used t create varius letters, frms, custmized

More information

Microsoft Excel Extensions for Enterprise Architect

Microsoft Excel Extensions for Enterprise Architect Excel Extensins User Guide Micrsft Excel Extensins fr Enterprise Architect Micrsft Excel Extensins fr Enterprise Architect... 1 Disclaimer... 2 Dependencies... 2 Overview... 2 Installatin... 4 Verifying

More information

Report Writing Guidelines Writing Support Services

Report Writing Guidelines Writing Support Services Reprt Writing Guidelines Writing Supprt Services Overview The guidelines presented here shuld give yu an idea f general cnventins fr writing frmal reprts. Hwever, yu shuld always cnsider yur particular

More information

Studio Software Update 7.7 Release Notes

Studio Software Update 7.7 Release Notes Studi Sftware Update 7.7 Release Ntes Summary: Previus Studi Release: 2013.10.17/2015.01.07 All included Studi applicatins have been validated fr cmpatibility with previusly created Akrmetrix Studi file

More information

Ascii Art Capstone project in C

Ascii Art Capstone project in C Ascii Art Capstne prject in C CSSE 120 Intrductin t Sftware Develpment (Rbtics) Spring 2010-2011 Hw t begin the Ascii Art prject Page 1 Prceed as fllws, in the rder listed. 1. If yu have nt dne s already,

More information

Course 10262A: Developing Windows Applications with Microsoft Visual Studio 2010 OVERVIEW

Course 10262A: Developing Windows Applications with Microsoft Visual Studio 2010 OVERVIEW Curse 10262A: Develping Windws Applicatins with Micrsft Visual Studi 2010 OVERVIEW Abut this Curse In this curse, experienced develpers wh knw the basics f Windws Frms develpment gain mre advanced Windws

More information

Faculty Textbook Adoption Instructions

Faculty Textbook Adoption Instructions Faculty Textbk Adptin Instructins The Bkstre has partnered with MBS Direct t prvide textbks t ur students. This partnership ffers ur students and parents mre chices while saving them mney, including ptins

More information

SAP Note Plan & Consol 10.0 for NetWeaver Documentation Addendum

SAP Note Plan & Consol 10.0 for NetWeaver Documentation Addendum SAP Nte 1586088 - Plan & Cnsl 10.0 fr NetWeaver Dcumentatin Addendum Nte Language: English Versin: 26 Validity: Valid Since 21.12.2012 Summary Symptm Dcumentatin Addendum Other terms Dcumentatin, help,

More information

The QMF Family V Newsletter 3rd Quarter 2013 Edition

The QMF Family V Newsletter 3rd Quarter 2013 Edition The QMF Family Newsletter 3rd Quarter 2013 Editin In This Issue Dive int QMF at the IBM Infrmatin On Demand Cnference irtual data surces and analytic queries in QMF A message frm the develpers f QMF: Changing

More information

Custodial Integrator. Release Notes. Version 3.11 (TLM)

Custodial Integrator. Release Notes. Version 3.11 (TLM) Custdial Integratr Release Ntes Versin 3.11 (TLM) 2018 Mrningstar. All Rights Reserved. Custdial Integratr Prduct Versin: V3.11.001 Dcument Versin: 020 Dcument Issue Date: December 14, 2018 Technical Supprt:

More information

Gemini Intercom Quick Start Guide

Gemini Intercom Quick Start Guide Gemini Intercm Quick Start Guide 2 Quick Start Guide Cntents Cntents... 1 Overview... 3 First Step unpack and inspect... 3 Netwrk plan and IP addresses... 4 Management PC... 5 Install Sftware... 6 Cnfigure

More information

Definiens XD Release Notes

Definiens XD Release Notes Definiens XD 1.1.2 Release Ntes Errr! N text f specified style in dcument. Definiens XD 1.1.2 - Release Ntes Imprint and Versin Dcument Versin XD 1.1.2 Cpyright 2009 Definiens AG. All rights reserved.

More information

Arius 3.0. Release Notes and Installation Instructions. Milliman, Inc Peachtree Road, NE Suite 1900 Atlanta, GA USA

Arius 3.0. Release Notes and Installation Instructions. Milliman, Inc Peachtree Road, NE Suite 1900 Atlanta, GA USA Release Ntes and Installatin Instructins Milliman, Inc. 3424 Peachtree Rad, NE Suite 1900 Atlanta, GA 30326 USA Tel +1 800 404 2276 Fax +1 404 237 6984 actuarialsftware.cm 1. Release ntes Release 3.0 adds

More information

Quick start guide: Working in Transit NXT with a PPF

Quick start guide: Working in Transit NXT with a PPF Quick start guide: Wrking in Transit NXT with a PPF STAR UK Limited Cntents What is a PPF?... 3 What are language pairs?... 3 Hw d I pen the PPF?... 3 Hw d I translate in Transit NXT?... 6 What is a fuzzy

More information

Summary. Server environment: Subversion 1.4.6

Summary. Server environment: Subversion 1.4.6 Surce Management Tl Server Envirnment Operatin Summary In the e- gvernment standard framewrk, Subversin, an pen surce, is used as the surce management tl fr develpment envirnment. Subversin (SVN, versin

More information

CISC-103: Web Applications using Computer Science

CISC-103: Web Applications using Computer Science CISC-103: Web Applicatins using Cmputer Science Instructr: Debra Yarringtn Email: yarringt@eecis.udel.edu Web Site: http://www.eecis.udel.edu/~yarringt TA: Patrick McClry Email: patmcclry@gmail.cm Office:

More information

Computer Organization and Architecture

Computer Organization and Architecture Campus de Gualtar 4710-057 Braga UNIVERSIDADE DO MINHO ESCOLA DE ENGENHARIA Departament de Infrmática Cmputer Organizatin and Architecture 5th Editin, 2000 by William Stallings Table f Cntents I. OVERVIEW.

More information

PAGE NAMING STRATEGIES

PAGE NAMING STRATEGIES PAGE NAMING STRATEGIES Naming Yur Pages in SiteCatalyst May 14, 2007 Versin 1.1 CHAPTER 1 1 Page Naming The pagename variable is used t identify each page that will be tracked n the web site. If the pagename

More information

Studio Software Update 8.2 Release Notes

Studio Software Update 8.2 Release Notes Studi Sftware Update 8.2 Release Ntes Previus Studi Release: 8.1 Supprted Equipment PC: Z97, Z170 Offline Studi Operating System: Windws XP (Service Pack 3) r higher; extensive testing specifically perfrmed

More information

Compliance Guardian 4. User Guide

Compliance Guardian 4. User Guide Cmpliance Guardian 4 User Guide Issued September 2015 Table f Cntents What's New in this Guide... 3 Abut Cmpliance Guardian... 4 Cmplementary Prducts... 5 Submitting Dcumentatin Feedback t AvePint... 6

More information

Overview of OPC Alarms and Events

Overview of OPC Alarms and Events Overview f OPC Alarms and Events Cpyright 2016 EXELE Infrmatin Systems, Inc. EXELE Infrmatin Systems (585) 385-9740 Web: http://www.exele.cm Supprt: supprt@exele.cm Sales: sales@exele.cm Table f Cntents

More information

TRAINING GUIDE. Lucity Mobile

TRAINING GUIDE. Lucity Mobile TRAINING GUIDE The Lucity mbile app gives users the pwer f the Lucity tls while in the field. They can lkup asset infrmatin, review and create wrk rders, create inspectins, and many mre things. This manual

More information

B Tech Project First Stage Report on

B Tech Project First Stage Report on B Tech Prject First Stage Reprt n GPU Based Image Prcessing Submitted by Sumit Shekhar (05007028) Under the guidance f Prf Subhasis Chaudhari 1. Intrductin 1.1 Graphic Prcessr Units A graphic prcessr unit

More information

Procedures for Developing Online Training

Procedures for Developing Online Training Prcedures fr Develping Online Training Fllwing are prcedures fr develping nline training mdules t be psted n Online@UT (Blackbard Learn). These steps were develped thrugh a prcess and will cntinue t be

More information

IMPORTING INFOSPHERE DATA ARCHITECT MODELS INFORMATION SERVER V8.7

IMPORTING INFOSPHERE DATA ARCHITECT MODELS INFORMATION SERVER V8.7 IMPORTING INFOSPHERE DATA ARCHITECT MODELS INFORMATION SERVER V8.7 Prepared by: March Haber, march@il.ibm.cm Last Updated: January, 2012 IBM MetaData Wrkbench Enablement Series Table f Cntents: Table f

More information

Whitepaper. Migrating External Specs to AutoCAD Plant 3D. Set Up the Required Folder Structure. Migrating External Specs to AutoCAD Plant 3D

Whitepaper. Migrating External Specs to AutoCAD Plant 3D. Set Up the Required Folder Structure. Migrating External Specs to AutoCAD Plant 3D Whitepaper The wrkflw fr migrating specs frm 3 rd -party sftware packages t AutCAD Plant 3D is as fllws: Set Up the Required Flder Structure Build CSV Files Cntaining Part Infrmatin Map External Parts

More information

C++ Reference Material Programming Style Conventions

C++ Reference Material Programming Style Conventions C++ Reference Material Prgramming Style Cnventins What fllws here is a set f reasnably widely used C++ prgramming style cnventins. Whenever yu mve int a new prgramming envirnment, any cnventins yu have

More information

Xilinx Answer Xilinx PCI Express DMA Drivers and Software Guide

Xilinx Answer Xilinx PCI Express DMA Drivers and Software Guide Xilinx Answer 65444 Xilinx PCI Express DMA Drivers and Sftware Guide Imprtant Nte: This dwnladable PDF f an Answer Recrd is prvided t enhance its usability and readability. It is imprtant t nte that Answer

More information

DocAve 6 Granular Backup and Restore

DocAve 6 Granular Backup and Restore DcAve 6 Granular Backup and Restre User Guide Service Pack 3 Revisin H Issued August 2013 1 Table f Cntents Abut DcAve Granular Backup and Restre... 5 Cmplementary Prducts... 5 Submitting Dcumentatin Feedback

More information

The Login Page Designer

The Login Page Designer The Lgin Page Designer A new Lgin Page tab is nw available when yu g t Site Cnfiguratin. The purpse f the Admin Lgin Page is t give fundatin staff the pprtunity t build a custm, yet simple, layut fr their

More information

Creating Relativity Dynamic Objects

Creating Relativity Dynamic Objects Creating Relativity Dynamic Objects Nvember 28, 2017 - Versin 9.4 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

More information

The following screens show some of the extra features provided by the Extended Order Entry screen:

The following screens show some of the extra features provided by the Extended Order Entry screen: SmartFinder Orders Extended Order Entry Extended Order Entry is an enhanced replacement fr the Sage Order Entry screen. It prvides yu with mre functinality while entering an rder, and fast access t rder,

More information

UiPath Automation. Walkthrough. Walkthrough Calculate Client Security Hash

UiPath Automation. Walkthrough. Walkthrough Calculate Client Security Hash UiPath Autmatin Walkthrugh Walkthrugh Calculate Client Security Hash Walkthrugh Calculate Client Security Hash Start with the REFramewrk template. We start ff with a simple implementatin t demnstrate the

More information

GPA: Plugin for OS Command With Solution Manager 7.1

GPA: Plugin for OS Command With Solution Manager 7.1 GPA: Plugin fr OS Cmmand With Slutin Manager 7.1 The plugin OS Cmmand can be used in yur wn guided prcedures. It ffers the pssibility t execute pre-defined perating system cmmand n each hst part f the

More information

Chapter 1 Introduction. What is a Design Pattern? Design Patterns in Smalltalk MVC

Chapter 1 Introduction. What is a Design Pattern? Design Patterns in Smalltalk MVC Chapter 1 Intrductin Designing bject-riented sftware is hard, and designing reusable bject-riented sftware is even harder. It takes a lng time fr nvices t learn what gd bject-riented design is all abut.

More information

How To enrich transcribed documents with mark-up

How To enrich transcribed documents with mark-up Hw T enrich transcribed dcuments with mark-up Versin v1.4.0 (22_02_2018_15:07) Last update 30.09.2018 This guide will shw yu hw t add mark-up t dcuments which are already transcribed in Transkribus. This

More information

Tutorial 5: Retention time scheduling

Tutorial 5: Retention time scheduling SRM Curse 2014 Tutrial 5 - Scheduling Tutrial 5: Retentin time scheduling The term scheduled SRM refers t measuring SRM transitins nt ver the whle chrmatgraphic gradient but nly fr a shrt time windw arund

More information

Graduate Application Review Process Documentation

Graduate Application Review Process Documentation Graduate Applicatin Review Prcess Cntents System Cnfiguratin... 1 Cgns... 1 Banner Dcument Management (ApplicatinXtender)... 2 Banner Wrkflw... 4 Navigatin... 5 Cgns... 5 IBM Cgns Sftware Welcme Page...

More information

INSTALLING CCRQINVOICE

INSTALLING CCRQINVOICE INSTALLING CCRQINVOICE Thank yu fr selecting CCRQInvice. This dcument prvides a quick review f hw t install CCRQInvice. Detailed instructins can be fund in the prgram manual. While this may seem like a

More information

UML : MODELS, VIEWS, AND DIAGRAMS

UML : MODELS, VIEWS, AND DIAGRAMS UML : MODELS, VIEWS, AND DIAGRAMS Purpse and Target Grup f a Mdel In real life we ften bserve that the results f cumbersme, tedius, and expensive mdeling simply disappear in a stack f paper n smene's desk.

More information

1 Version Spaces. CS 478 Homework 1 SOLUTION

1 Version Spaces. CS 478 Homework 1 SOLUTION CS 478 Hmewrk SOLUTION This is a pssible slutin t the hmewrk, althugh there may be ther crrect respnses t sme f the questins. The questins are repeated in this fnt, while answers are in a mnspaced fnt.

More information

Stealing passwords via browser refresh

Stealing passwords via browser refresh Stealing passwrds via brwser refresh Authr: Karmendra Khli [karmendra.khli@paladin.net] Date: August 07, 2004 Versin: 1.1 The brwser s back and refresh features can be used t steal passwrds frm insecurely

More information

STIDistrict AL Rollover Procedures

STIDistrict AL Rollover Procedures 2009-2010 STIDistrict AL Rllver Prcedures General Infrmatin abut STIDistrict Rllver IMPORTANT NOTE! Rllver shuld be perfrmed between June 25 and July 25 2010. During this perid, the STIState applicatin

More information

UFuRT: A Work-Centered Framework and Process for Design and Evaluation of Information Systems

UFuRT: A Work-Centered Framework and Process for Design and Evaluation of Information Systems In: Prceedings f HCI Internatinal 2007 UFuRT: A Wrk-Centered Framewrk and Prcess fr Design and Evaluatin f Infrmatin Systems Jiajie Zhang 1, Keith A. Butler 2 1 University f Texas at Hustn, 7000 Fannin,

More information

Setting up the ncipher nshield HSM for use with Kerberized Certificate Authority

Setting up the ncipher nshield HSM for use with Kerberized Certificate Authority Setting up the ncipher nshield HSM fr use with Kerberized Certificate Authrity Intrductin This dcument cntains instructins fr setting up ncipher nshield hardware security mdules (HSM) fr use with the Kerberized

More information

InformationNOW Letters

InformationNOW Letters InfrmatinNOW Letters Abut this Guide This Quick Reference Guide prvides an verview f letters in InfrmatinNOW. There are three types f letters: Student: May be used t create varius letters, frms, custmized

More information

Populate and Extract Data from Your Database

Populate and Extract Data from Your Database Ppulate and Extract Data frm Yur Database 1. Overview In this lab, yu will: 1. Check/revise yur data mdel and/r marketing material (hme page cntent) frm last week's lab. Yu will wrk with tw classmates

More information

1 Binary Trees and Adaptive Data Compression

1 Binary Trees and Adaptive Data Compression University f Illinis at Chicag CS 202: Data Structures and Discrete Mathematics II Handut 5 Prfessr Rbert H. Slan September 18, 2002 A Little Bttle... with the wrds DRINK ME, (r Adaptive data cmpressin

More information

Because this underlying hardware is dedicated to processing graphics commands, OpenGL drawing is typically very fast.

Because this underlying hardware is dedicated to processing graphics commands, OpenGL drawing is typically very fast. The Open Graphics Library (OpenGL) is used fr visualizing 2D and 3D data. It is a multipurpse pen-standard graphics library that supprts applicatins fr 2D and 3D digital cntent creatin, mechanical and

More information