Community Profile

photo

Fangjun Jiang


Last seen: Today
2,674 2011 年以降の合計貢献数

What is a model?
Professional Interests: Model-Based Development

連絡する

Fangjun Jiang's バッジ

  • 36 Month Streak
  • Revival Level 3
  • First Review
  • Ace
  • Thankful Level 2
  • Knowledgeable Level 4
  • First Answer
  • Solver

詳細を表示...

貢献した分野
表示方法

回答済み
save a fprintf as text file
fid=fopen('MyTextFile.txt','wt'); fprintf(fid,...); fclose(fid);

1日 前 | 0

| 採用済み

回答済み
Saturating Functions at a certain value
x=[0:0.01:20]; expo=@(x) min(2.^x,100); plot(x,expo(x));

4日 前 | 0

回答済み
Is it possible to create a library of Model Reference blocks?
It is possible but based on what you described, I would say a library of subsystem blocks are better than a library of model ref...

4日 前 | 0

回答済み
How to create a block diagram that will increment a value?
A counter block, multiplied by 0.1 or -0.1

4日 前 | 0

| 採用済み

回答済み
how to get simulink stop time even if using code generation
Not sure what you mean. >> vdp >> get_param('vdp','StopTime') ans = '20'

4日 前 | 0

回答済み
Triggering blocks on simulink
It sounds right. Comparing a with 0.75 and 0.85 will generate two high or low logical signals. Combine these two logical signals...

5日 前 | 0

回答済み
How do you change the port names in a lookup table programatically?
You can't change the lable "u1", "u2". They are just to identify the first dimention input, 2nd dimension input, etc. They have ...

6日 前 | 0

回答済み
Re-arrange cell accordingly to a sorted vector
utilizde another output of sort(). Note legend() is a function. [newY, index]=sort(Y) newLegend=oldLegend(index)

6日 前 | 1

| 採用済み

回答済み
Cell rows/columns size
c={'12',[],'adjk';'jkjf','j;',[]} b=cellfun(@isempty,c)

6日 前 | 0

| 採用済み

回答済み
Ways to define 'data store memory' block
This is on that page. Create A=Simulink.Signal in base workspace, then you can use DataStoreRead or DataStoreWrite block with da...

6日 前 | 0

回答済み
Distributing a cell array into another
strcat(repmat(A,size(B')),repmat({' '},[length(B),length(A)]),repmat(B',size(A)))

7日 前 | 0

回答済み
Execution Time Calculation in Simulink
Like this? tic; sim('MyModel'); toc;

8日 前 | 0

回答済み
Passing the Value as Argument but not getting it in the function file
In your function, you need to assign or return iNew,jNew

8日 前 | 0

回答済み
Removing loaded variables from workspace after changing name with eval
Use one example, figure out if you can use the code below. If not, use "clear" to delete variable from workspace. Patient=load(...

8日 前 | 0

回答済み
is it a normal display of the command window on MATLAB for window? and how to fix if it needs attention?
Some of the folders must have been moved or deleted. Run "restoredefaultpath" and re-start MATLAB.

8日 前 | 0

回答済み
Changing model programmatically: discard changes and exit?
close_system(sys,saveflag)

8日 前 | 0

| 採用済み

回答済み
dec2bin is adding inappropriate 0s to negative numbers when numBits is specified
Report to tech support. I think it looks like a bug. From "doc dec2bin" in R2020a Starting in R2020a, the dec2bin function con...

8日 前 | 0

| 採用済み

回答済み
how to store coordinate values xy[] for randomly generate point
Try one-liner, no loop. xy=[xm*rand(NumOfNodes,1), ym*rand(NumOfNodes,1)]

10日 前 | 0

| 採用済み

回答済み
display my generated matrix
disp(dist) open('dist')

11日 前 | 0

回答済み
Installation for all users on a common machine
Just follow the installation instruction and activate license. You will be asked to activate MATLAB per machine or per user.

11日 前 | 0

回答済み
Storage Class replaced to default AUTO.
If the data is in MATLAB base workspace, they have to be saved separately, in .mat file or exported to .m file, although MATLAB ...

11日 前 | 0

| 採用済み

回答済み
How can I overcome the error "variable admit must be of data type logical instead of double"..I have to return logical values true or false using the function below.what is wrong with this?
The error message must have come from somewhere else, not from this function. Here, nothing is wrong except that the data type o...

11日 前 | 1

| 採用済み

回答済み
How to extract value of cell in excel?
readtable() is ideal for this. See "doc readtable" for examples.

11日 前 | 0

回答済み
changing Kp value in a loop for PID tuning
pidsys=pid(1) creats a PID controller. pidsys is an object with the class of 'pid'. You can run class(pidsys) or get(pidsys) to ...

11日 前 | 0

回答済み
p_save Change Size on Every Loop Iteration
p_save(:,i)=p

11日 前 | 1

回答済み
Convert a table of tables in a single table
Okay, what you have is new in R2020a. Here is an example: a{1}=table(rand(9,1)); a{2}=table(rand(9,1)); b=cellfun(@table2arra...

11日 前 | 0

| 採用済み

回答済み
How to load .prj file from windows command prompt?
matlab.exe -r "open('D:\automation\simulink\autogen\autogen.prj')"

11日 前 | 1

| 採用済み

回答済み
I need to install a toolbox for a specific function and i have restricted acces, why ?
You may have the license to the toolbox. But the license administrators (on both the Mathworks side and your organization side) ...

12日 前 | 0

回答済み
Why FixedStep is not really fixed in simulink?
It conflicts with your solver specification. ode45 is a variable-step solver. FixedStep - Fixed step size [ positive scalar ] ...

12日 前 | 1

| 採用済み

回答済み
My "roots" command is not working and displaying an error (MATLAB 2017a) ver.
You are running your own roots.m SCRIPT, not the MATLAB roots() function.

12日 前 | 1

| 採用済み

Load more