回答済み
how to save cell array which not have equal row in each column to .csv
function cell2csv(c,filename) % Writes a cell array of 1D arrays to a csv file c = c(:); fid = fopen(filename...

9年以上 前 | 0

回答済み
How to curve fit a transcendental function to data?
Set k0 = [k1_0;k2_0;k3_0] to a vector of initial values for your unknown parameters. Write your function as: predic...

9年以上 前 | 1

| 採用済み

回答済み
problem with Matrix Multiplication
Note that in Matlab, vectors are matrices of column or row shape and. A 2 by 2 matrix can only be multiplied by a column vector...

9年以上 前 | 0

回答済み
Problem with fmincon: nonlcon
To transfer the extra inputs to DiagCAW11_constraints you should use an anonymous function: Make sure that RC, r, bsum are de...

10年弱 前 | 0

回答済み
cumsum function for seperate time
Interesting problem. Here is one possible solution: dates = {'01/01/1975'; '05/01/1975'; '25/01/1975'; '05/02/1975';... ...

10年弱 前 | 0

回答済み
How to replace a variable or function with another variable or function ?
You could define an anonymous function f(x): f = @(x) x.*(x.^2-1); Note the '.' before the * and ^operators. This lets t...

約10年 前 | 2

回答済み
How to reset variables before each iteration
Here is an example that clears all variables except b and c: % Fist create some variables a = 1; b = 2; c = 3; d = 4; ...

約10年 前 | 0

解決済み


Remove the polynomials that have positive real elements of their roots.
The characteristic equation for a dynamic system is a polynomial whose roots indicate its behavior. If any of the <http://www.ma...

約10年 前

送信済み


read_excel_columns(filename,sheet,columns,firstrow,lastrow)
Read selected columns from a large Excel file using ActiveX

10年以上 前 | ダウンロード 1 件 |

5.0 / 5

回答済み
How do I read only specific columns in from an Excel file, not consecutive columns?
I enclose a first version of a function I just wrote. This will read a number of columns from a large Excel file. Since it ope...

10年以上 前 | 1

| 採用済み

解決済み


Read a column of numbers and interpolate missing data
Given an input cell array of strings s, pick out the second column and turn it into a row vector of data. Missing data will be i...

10年以上 前

回答済み
How to seperate fractional and decimal part in a real number
mod(number,1)

10年以上 前 | 0

回答済み
What kind of solver should I use for a non-continuous function?
Note that the function that you give to ode45 returns the velocity and acceleration. When you change the sign of v in this func...

10年以上 前 | 0

| 採用済み

回答済み
Consider a loop of string with unit length. Take n cuts independently and randomly along the string, what is the expected length of the smallest and the largest piece?
Your question is not very clear. The code below is an answer to: How can I code a test of this result? N=100000; % Number ...

10年以上 前 | 1

解決済み


Connect Four Win Checker
<http://en.wikipedia.org/wiki/Connect_Four Connect Four> is a game where you try to get four pieces in a row. For this problem, ...

10年以上 前

解決済み


Calculate the Levenshtein distance between two strings
This problem description is lifted from <http://en.wikipedia.org/wiki/Levenshtein_distance>. The Levenshtein distance betwee...

10年以上 前

回答済み
solve a system of ODE
function [t,x]=euleroesplicito(fcn,t0,x0,h,tend) n = fix((tend-t0)/h)+1; t = linspace(t0,t0+(n-1)*h,n); x = ze...

10年以上 前 | 1

| 採用済み

解決済み


Number of occurrences of letter in a text
Given an input text either as a string or as a cell array of strings, return a (1 x 26) matrix containing the number of occurren...

10年以上 前

解決済み


Word Counting and Indexing
You are given a list of strings, each being a list of words divided by spaces. Break the strings into words, then return a maste...

10年以上 前

解決済み


Given two strings, find the maximum overlap
Given two strings s1 and s2, create a new string s3 which is as short as possible and contains both strings. If s1 = [1 2...

10年以上 前

解決済み


Find the two-word state names
Given a list of states, remove all the states that have two-word names. If s1 = 'Alabama Montana North Carolina Vermont N...

10年以上 前

解決済み


Find state names that end with the letter A
Given a list of US states, remove all the states that end with the letter A. Example: Input s1 = 'Alabama Montana Nebras...

10年以上 前

解決済み


Prime factor digits
Consider the following number system. Calculate the prime factorization for each number n, then represent the prime factors in a...

10年以上 前

解決済み


Remove all the consonants
Remove all the consonants in the given phrase. Example: Input s1 = 'Jack and Jill went up the hill'; Output s2 is 'a ...

10年以上 前

解決済み


Pascal's Triangle
Given an integer n >= 0, generate the length n+1 row vector representing the n-th row of <http://en.wikipedia.org/wiki/Pascals_t...

10年以上 前

解決済み


De-dupe
Remove all the redundant elements in a vector, but keep the first occurrence of each value in its original location. So if a =...

10年以上 前

解決済み


Balanced number
Given a positive integer find whether it is a balanced number. For a balanced number the sum of first half of digits is equal to...

10年以上 前

解決済み


Find all elements less than 0 or greater than 10 and replace them with NaN
Given an input vector x, find all elements of x less than 0 or greater than 10 and replace them with NaN. Example: Input ...

10年以上 前

解決済み


Binary numbers
Given a positive, scalar integer n, create a (2^n)-by-n double-precision matrix containing the binary numbers from 0 through 2^n...

10年以上 前

回答済み
how to speedup the function datetime('('1/1/2014 1:00:00 AM','ConvertFrom','excel')?
[num,txt,raw] = xlsread('file.xlsx') returns date-time values as NaNs in the num output and as strings in the txt and raw ou...

10年以上 前 | 0

さらに読み込む