3.6.2 DeleteElements
Command structure of DeleteElements.
Given a Netlist or Circuit object, DeleteElements removes netlist elements from the top-level netlist or from subcircuits defined in the circuit and returns the new Netlist or Circuit object, respectively. The argument stringpattern is either a single string pattern or a list of string patterns. Netlist elements whose reference designator matches any of the string patterns are removed. To delete elements in subcircuits, referencing to certain subcircuits is performed by means of the subcircuit specification subcirspec which is a sequence of rules of the following form:
Possible subcircuit specifications.
Note that there is no check whether the returned Circuit object defines a valid circuit.
See also: AddElements, GetElements.
Examples
Load Analog Insydes.
In[1]:= <<AnalogInsydes`
Define a simple voltage divider with load resistance.
In[2]:= netload = Netlist[ {V0, {1, 0}, V0}, {R1, {1, 2}, R1}, {R2, {2, 0}, R2}, {Rload, {2, 0}, Rload} ]
Out[2]=
Remove all elements whose reference designator match the string pattern "*load".
In[3]:= net = DeleteElements[netload, "*load"]
Out[3]=
Display new netlist.
In[4]:= DisplayForm[net]
Out[4]//DisplayForm=
|