MATLAB Help Center
Determine whether model is library
tf = bdIsLibrary(sys)
tf = bdIsLibrary(sys) returns whether the specified model is a library.
tf
sys
example
collapse all
Check One Model
Open the example. Then, load the vdp and MLFB_library models.
vdp
MLFB_library
h1=load_system('vdp')
h1 = 153.0010
h2=load_system('MLFB_library')
h2 = 360.0035
Check whether the vdp model is a library.
bdIsLibrary(h1)
ans = logical 0
The function returns a logical scalar, 0, which indicates that the vdp model is not a library.
0
Check Multiple Models
You can check whether multiple models are libraries with a single function call.
Check whether the vdp and MLFB_library models are libraries. Specify the models to check as a matrix of handles.
bdIsLibrary([h1,h2])
ans = 1×2 logical array 0 1
Alternatively, specify the models to check as a cell array of character vectors.
bdIsLibrary({'vdp','MLFB_library'})
The function returns the logical array [0 1], which indicates that:
[0 1]
The vdp model is not a library.
The MLFB_library model is a library.
Name or handle of loaded model, specified as a numeric array, string array, character vector, or cell array of character vectors.
Data Types: double | char | string | cell
double
char
string
cell
1
True or false result, returned as a 1 or 0 of data type logical.
logical
1 (true) — File is a library.
true
0 (false) — File is not a library.
false
When multiple files are specified, the function returns a logical array with one entry for each file.
Introduced in R2015a
bdIsLoaded | bdroot | find_system | bdIsSubsystem
bdIsLoaded
bdroot
find_system
bdIsSubsystem
You clicked a link that corresponds to this MATLAB command:
Run the command by entering it in the MATLAB Command Window. Web browsers do not support MATLAB commands.
Select a Web Site
Choose a web site to get translated content where available and see local events and offers. Based on your location, we recommend that you select: .
You can also select a web site from the following list
How to Get Best Site Performance
Select the China site (in Chinese or English) for best site performance. Other MathWorks country sites are not optimized for visits from your location.
Americas
Europe
Asia Pacific
Contact your local office