Community Profile

photo

Rik


Last seen: Today Active since 2017

E-mails with feedback/questions about FEX submissions are welcomed. In general I will post e-mails about Answers on the related page, unless there is good cause not to do so.

Statistics

All
  • Treasure Hunt Participant
  • MATLAB Central Treasure Hunt Finisher
  • 36 Month Streak
  • Ace
  • Draw Letters
  • Community Group Solver
  • 5-Star Galaxy Level 5
  • GitHub Submissions Level 3
  • Indexing I Master
  • Cody Challenge Master
  • Introduction to MATLAB Master
  • Speed Demon

View badges

Content Feed

Answered
How to store values from nested for loop
The first step to implement a summation in Matlab is very easy: just use a for loop. It is often possible to do this with a matr...

alrededor de 11 horas ago | 1

| accepted

Answered
How to create a matrix with nested for loop for fraction entries?
Why use loops at all? y=1; ii=0.5:.1:.7; jj=.4:.1:.6; [ii,jj]=ndgrid(ii,jj); mat=ii.*y.*jj; disp(mat)

alrededor de 11 horas ago | 1

Answered
Having error when ploting bars with filled pattern
Download the applyhatch_plusC function from the FileExchange here and add it to your path somewhere (or your current folder). N...

alrededor de 15 horas ago | 0

Answered
Appending a file with a string output and a numeric output
Use the 'a', 'a+', or 'A' flags in fopen to append data. This should work for text files as well. You don't really need the 't' ...

alrededor de 15 horas ago | 1

Answered
mex - setup FORTRAN can't install for 2017b or 2021a for windows 10
MinGW is only for C an C++, not Fortran. The linked page looks like you need the Intel Parallel Studio XE. The 2017 version s...

4 días ago | 0

Answered
why the command "figure(gcf+1)" gives error?????
The gcf get the handle to the current figure. In old releases this used to be a double, but since several years ago it has been ...

4 días ago | 0

| accepted

Answered
How to vectorize nested for loops
ndgrid will do the trick: rowsA=59; pix = 25.4/600; R = 2.5; ht = 1.5; A=abs(-rowsA:rowsA); % e.g. 5 4 3 2 1 0 1 2 3 4 5 size...

5 días ago | 0

| accepted

Answered
New. to Matlab, can you help me with the code?
A much better solution is to learn Matlab with a tutorial. You may consider doing the Onramp tutorial (which is provided for fre...

5 días ago | 1

Answered
Have problem in solution
It looks like you want different things to happen depending on the value of Erf: for every element smaller than 2 you want y to ...

6 días ago | 0

| accepted

Answered
How can I obtain the permutation of 3 binary variables?
The easiest way to do this is with bin2dec. You can loop from 0 to 2^n-1 to get all combinations. To convert the character array...

7 días ago | 0

| accepted

Answered
how to find the answer of:
Use the inverse of tan: atan B=atan(log10(50)/exp(0.53))

7 días ago | 0

| accepted

Answered
How to create an independent loop?
If you want something to be independent, you need to use a function: for n=1:200 my_fun(n,struct_with_your_other_variables...

7 días ago | 1

| accepted

Answered
How to unstructure the structure data?
If you use the normal dot indexing with a struct array, that will generate a comma separated list. You can put that between bra...

11 días ago | 1

| accepted

Answered
find function using wildcards
You can use the patterns introduced in R2020b: str={'/* GeoForschungsZentrum Potsdam ...

12 días ago | 1

| accepted

Answered
How can I use fprintf to print matrix by column?
fprintf tranverses the input in a column-major order. If you want to change that, you can't, so you will have to flip the array ...

12 días ago | 0

Answered
I wrote this code and it didn't work and its gave me " Unrecognized function or variable 'seq' " error , What I can do to sole this error??
Apparently your code doesn't guarantee the creation of the seq variable. Since it only occurs in block starting with Test=='T', ...

12 días ago | 0

Answered
How to check for data normality using kstest?
If you want to test if your data is from a standard normal distribution you should not change it before calling kstest. If yo...

13 días ago | 0

| accepted

Answered
How can I mouse pick up and move
You can do this with the WindowButtonDownFcn (or the equivalent for uifigures: ButtonDownFcn). Inside that callback you can ret...

15 días ago | 0

Answered
How can i read in a .txt file without the first column gets saved?
I prefer not to mix tasks. I first read my file, then I do the processing. It is generally a lot easier to remove parts of char ...

15 días ago | 0

Answered
Mathmatica saving Matlab files as Wolfram Mathmatica Package files
Your files have not changed, only the description your OS displays. You should look up a guide for your specific OS. On windo...

15 días ago | 0

| accepted

Answered
graph with two formulas
You probably want the errorbar function: x = 1:10:100; y = [20 30 45 40 60 65 80 75 95 90]; err = 8*ones(size(y)); errorbar(...

15 días ago | 0

| accepted

Answered
Pressure drop script is not running
If you have problems with a function, you should really check the documentation. The input function does not work like you expe...

16 días ago | 0

| accepted

Answered
How to extract common points from a csv file with same Id?
The easiest way is probably with histcounts (or histc on old releases).

19 días ago | 0

Answered
Is the Raspberry pi MATLAB and SIMULINK support package compatible with the raspberry pi 400?
The Pi 400 is identical to the Pi 4 in most relevant aspects, so I think you can expect it to work.

19 días ago | 0

Answered
How to add 3th moving ball
If you replace numbered variables with arrays you can use simple loops with indexing. With your current setup you will have to c...

19 días ago | 0

Answered
Replacing for loop in the function
What you want is not possible. Depending on what f is there might be ways to avoid the loop and use vector-operations instead, b...

20 días ago | 1

Answered
Why do I get the error '??? Output argument ‹variable› (and maybe others) not assigned during call to ‹function›.' ?
The error is in getgamspath. Consider this function: function [output1,output2]=IncorrectFunction output2=1; end Running it ...

21 días ago | 0

Answered
how to define and write the first line of a function while one of the inputs are a matrix with strings as entries (strings are defined in the body of function)
You can only have variable names in your function signature, not any indexing. function PS=level2(NOH,NOC,tetta,A)

24 días ago | 0

| accepted

Answered
How to load multiple .mat files containing timetables into the workspace and concatenate them vertically
If you use struct2cell (either inside your loop or in a cellfun) you can extract the data itself. Then you should be able to use...

25 días ago | 0

Answered
what is the alternative of cd in .executable app ?
You can use && to execute another command if the first one completes successfully: doscmd = [... 'cd /d "' pathTargetFiles...

25 días ago | 0

| accepted

Load more