How can i fit circular convolution function in matlab?

1 view (last 30 days)
Hi i have a Gaussian distribution: x=-5:0.1:5; w=0.2; y=exp((-0.5*x.^2)/w.^2);
and i have another function M given by % T is variable temperature that is from T1, to T2. % a and b are parameters to be fitted if T<a; M=A*(1-T/a)^b else M=0;
I want to convolve these two functions y and M and fit with a dataset A. First column is temperature and second is M. 141.2697 23 141.1745 -6 141.0958 -5 140.6993 -4 140.586 -6 140.4592 31 140.3205 -1 140.2184 -18 140.133 4 140.0531 8 139.7098 -1 139.5982 6 139.4723 -15 139.3313 22 139.2264 1 139.1279 9 139.0406 13 138.7523 2 138.6839 -13 138.6165 20 138.5527 -3 138.4884 -24 138.4402 28 138.3932 -3 138.2202 20 138.1586 -5 138.0943 8 138.0217 20 137.9681 19 137.916 -28 137.8697 -1 137.7116 -7 137.66 12 137.587 18 137.5274 7 137.467 45 137.4062 33 137.3768 18 137.2131 2 137.1637 1 137.103 23 137.033 -4 136.9569 43 136.9173 30 136.8757 -2 136.7167 20 136.6617 26 136.5832 -2 136.5183 12 136.441 -2 136.405 38 136.3727 8 136.2223 69 136.1714 85 136.0979 96 136.038 96 135.9802 206 135.9402 273 135.9002 308 135.7191 531 135.6735 552 135.6061 602 135.5256 724 135.4629 728 135.4219 865 135.3853 891 135.2113 1050 135.166 1086 135.0912 1170 135.0352 1255 134.976 1235 134.933 1320 134.8913 1398 134.7323 1510 134.6623 1579 134.589 1669 134.5287 1673 134.4691 1651 134.4265 1675 134.3849 1788 134.2149 1872 134.1564 1941 134.0743 1901 134.0206 1895 133.9765 1957 133.9352 1951 133.9056 2020 133.707 1965 133.6111 2127 133.4719 2150 133.3544 2253 133.2352 2175 133.1515 2181 133.0764 2163 132.7629 2276 132.6432 2295 132.4758 2220 132.3387 2386 132.2395 2457 132.1444 2427 132.0781 2430 131.7491 2466 131.6262 2566 131.4799 2479 131.3604 2380 131.2394 2524 131.1553 2485 131.0773 2553 130.7583 2517 130.5929 2624 I want to fit this with convolution of y and M and find the paramers A, a and b. Can someone help me on this.
Thanks
  1 Comment
Matt J
Matt J on 2 Oct 2013
Please highlight your code and reformat it readably with the
toolbar button.

Sign in to comment.

Answers (1)

Image Analyst
Image Analyst on 2 Oct 2013
I don't understand what you want to do. y is a vector that has a Gaussian shape. A is some vector of arbitrary values. And you could make an "M1" matrix that is M evaluated over some range for a specified T and a. Okay, so now you have three vectors. Now what? What is to be convolved , or what is to be fitted ? Sounds like you want to convolve y and M1, like
out = conv(y, M1);
But I don't know what it means to "fit it with a dataset A."
Please explain.

Categories

Find more on Interpolation in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!