<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic I'm sorry for the poor in Intel® Fortran Compiler</title>
    <link>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112627#M129466</link>
    <description>&lt;P&gt;I'm sorry for the poor presentation of that question.&lt;/P&gt;

&lt;P&gt;First, the data in the two files have the same data range (i.e. 1 - 218). But the data in 'SIM' file increases in the same interval (1 - 218) as one varies some parameters in the model that generated it. So,the data in that 'SIM' file was increased 3 times (i.e. 3*218=654).&lt;/P&gt;

&lt;P&gt;I want to calculate functn for ranges (1 to 218) until end of ndata instead of taking the sum for the entire ndata.&lt;/P&gt;</description>
    <pubDate>Fri, 26 Aug 2016 20:44:07 GMT</pubDate>
    <dc:creator>Gloria_E_</dc:creator>
    <dc:date>2016-08-26T20:44:07Z</dc:date>
    <item>
      <title>LOOP</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112625#M129464</link>
      <description>&lt;P&gt;Please how do I calculate functn for ranges (1 to 218) until end of ndata? See the attached file.&lt;BR /&gt;
	&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Fri, 26 Aug 2016 12:06:36 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112625#M129464</guid>
      <dc:creator>Gloria_E_</dc:creator>
      <dc:date>2016-08-26T12:06:36Z</dc:date>
    </item>
    <item>
      <title>This is a poorly posed</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112626#M129465</link>
      <description>&lt;P&gt;This is a poorly posed question and cannot be answered without knowing about the contents of the two input data files and the relation between the two files.&lt;/P&gt;</description>
      <pubDate>Fri, 26 Aug 2016 12:16:03 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112626#M129465</guid>
      <dc:creator>mecej4</dc:creator>
      <dc:date>2016-08-26T12:16:03Z</dc:date>
    </item>
    <item>
      <title>I'm sorry for the poor</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112627#M129466</link>
      <description>&lt;P&gt;I'm sorry for the poor presentation of that question.&lt;/P&gt;

&lt;P&gt;First, the data in the two files have the same data range (i.e. 1 - 218). But the data in 'SIM' file increases in the same interval (1 - 218) as one varies some parameters in the model that generated it. So,the data in that 'SIM' file was increased 3 times (i.e. 3*218=654).&lt;/P&gt;

&lt;P&gt;I want to calculate functn for ranges (1 to 218) until end of ndata instead of taking the sum for the entire ndata.&lt;/P&gt;</description>
      <pubDate>Fri, 26 Aug 2016 20:44:07 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112627#M129466</guid>
      <dc:creator>Gloria_E_</dc:creator>
      <dc:date>2016-08-26T20:44:07Z</dc:date>
    </item>
    <item>
      <title>Quote:Gloria E. wrote:</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112628#M129467</link>
      <description>&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;Gloria E. wrote:&lt;BR /&gt;&lt;P&gt;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="font-size: 1em; line-height: 1.5;"&gt;First, the data in the two files have the same data range (i.e. 1 - 218). But the data in 'SIM' file increases in the same interval (1 - 218) as one varies some parameters in the model that generated it. So,the data in that 'SIM' file was increased 3 times (i.e. 3*218=654).&lt;/SPAN&gt;&lt;/P&gt;

&lt;P&gt;&lt;SPAN style="font-size: 1em; line-height: 1.5;"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;

&lt;P&gt;Lines 219-436 are identical to lines 1-218. So are lines 437-654. What purpose does this duplication serve?&lt;/P&gt;

&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;

&lt;P style="font-size: 16.26px; line-height: 24.39px;"&gt;I want to calculate functn for ranges (1 to 218) until end of ndata instead of taking the sum for the entire ndata.&lt;/P&gt;

&lt;P&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;&lt;/P&gt;

&lt;P&gt;That sentence is incomprehensible. What is the definition of 'functn'? What do you mean by 'end of ndata'?&lt;/P&gt;

&lt;P&gt;Please tell us, precisely and clearly, what the data files contain and what you wish to compute.&lt;/P&gt;

&lt;P&gt;It is rarely useful to pore over lines of code and deduce definitions of terms and explanations of what the code is supposed to do.&lt;/P&gt;</description>
      <pubDate>Fri, 26 Aug 2016 22:11:00 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112628#M129467</guid>
      <dc:creator>mecej4</dc:creator>
      <dc:date>2016-08-26T22:11:00Z</dc:date>
    </item>
    <item>
      <title>I duplicated lines 1-218 to</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112629#M129468</link>
      <description>&lt;P&gt;I duplicated lines 1-218 to create a scenario to test the program. Actually, the data in 'SIM' file (1-218) will be replicated many times with different set of values.&lt;/P&gt;

&lt;P&gt;Functn is a cumulative of ((obsq - q)**2) for the following intervals 1-218, 219-436, 437-654 etc.&lt;/P&gt;

&lt;P&gt;'end of ndata' is the last value in 'SIM' file.&lt;/P&gt;

&lt;P&gt;I'm trying to get cumulative of ((obsq - q)**2) at these intervals (1-218, 219-436, 437-654, 655-872 .....). The data in 'OBS' file remains same for those intervals.&lt;/P&gt;</description>
      <pubDate>Sun, 28 Aug 2016 06:59:23 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112629#M129468</guid>
      <dc:creator>Gloria_E_</dc:creator>
      <dc:date>2016-08-28T06:59:23Z</dc:date>
    </item>
    <item>
      <title>If the data sets are small</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112630#M129469</link>
      <description>&lt;P&gt;If the data sets are small enough to fit into memory, it is more efficient to read all the input data into memory, and reuse the data as often as needed. For example:&lt;/P&gt;

&lt;PRE class="brush:fortran;"&gt;PROGRAM MY_TEST
   integer, parameter :: NOBS = 218
   REAL::obsq(NOBS),q(NOBS),functn
   INTEGER::ndata,set

	OPEN(16,FILE='SIM.DAT',STATUS='OLD')
	OPEN(9,FILE='CHINWE.DAT',STATUS='REPLACE')

	ndata=NOBS
    OPEN(8,FILE='OBS.DAT',STATUS='OLD')
    read(8,*)(obsq(i),i=1,ndata)       ! read once; use many times
    close(8)
    set=0
    DO
	   read(16,*,end=100)(q(i),i=1,ndata)
 	   functn = sum((obsq-q)**2)
	   set = set+1
	   write(9,*) set,functn
	   write(*,*) set,functn
    END DO
100 continue
    close (9)
    close (16)
END PROGRAM

&lt;/PRE&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 28 Aug 2016 14:42:26 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112630#M129469</guid>
      <dc:creator>mecej4</dc:creator>
      <dc:date>2016-08-28T14:42:26Z</dc:date>
    </item>
    <item>
      <title>Thank you very much. I really</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112631#M129470</link>
      <description>&lt;P&gt;Thank you very much. I really appreciate your effort.&lt;/P&gt;

&lt;P&gt;Please one more thing, I want the program to display different values of that 'functn' from 1-218, 219-436, 437-654 etc. For instance, the first 'functn' in the first interval will be 114.49, followed by 188.1064 and 285.72653 etc.&lt;/P&gt;

&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 28 Aug 2016 15:28:48 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112631#M129470</guid>
      <dc:creator>Gloria_E_</dc:creator>
      <dc:date>2016-08-28T15:28:48Z</dc:date>
    </item>
    <item>
      <title>The program in #6 will do</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112632#M129471</link>
      <description>&lt;P&gt;The program in #6 will do exactly what you asked for in #7 if the data in lines 219-436 of SIM.DAT are different from the data in lines 1-218, and so on. With the SIM.DAT that you posted in #1, as I already remarked, you have replicated data, so the output will be three identical lines.&lt;/P&gt;</description>
      <pubDate>Sun, 28 Aug 2016 15:53:40 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112632#M129471</guid>
      <dc:creator>mecej4</dc:creator>
      <dc:date>2016-08-28T15:53:40Z</dc:date>
    </item>
    <item>
      <title>Yes the output will be</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112633#M129472</link>
      <description>&lt;P&gt;Yes the output will be replicated three times. But I want the program to display the cumulative at different levels such as&lt;/P&gt;

&lt;P&gt;1 &amp;nbsp; &amp;nbsp; 114.49&lt;/P&gt;

&lt;P&gt;2 &amp;nbsp; &amp;nbsp; 188.10&lt;/P&gt;

&lt;P&gt;3 &amp;nbsp; &amp;nbsp; 285.72&lt;/P&gt;

&lt;P&gt;4.&amp;nbsp;&amp;nbsp;&amp;nbsp; 378.88&lt;/P&gt;

&lt;P&gt;and so on.&amp;nbsp;&lt;/P&gt;

&lt;P&gt;This&amp;nbsp; will be replicated three times because of the data in 'SIM' file.&lt;BR /&gt;
	&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 28 Aug 2016 20:47:50 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112633#M129472</guid>
      <dc:creator>Gloria_E_</dc:creator>
      <dc:date>2016-08-28T20:47:50Z</dc:date>
    </item>
    <item>
      <title>Sooner or later, you will</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112634#M129473</link>
      <description>&lt;P&gt;If I guess what you want correctly, i.e., that you wish to print the cumulative sums&amp;nbsp;Σ&lt;SUB&gt;j=1 to i&lt;/SUB&gt; (obs&lt;SUB&gt;j&lt;/SUB&gt; - sim&lt;SUB&gt;j&lt;/SUB&gt;)&lt;SUP&gt;2&lt;/SUP&gt;&amp;nbsp;for i = 1, 2,..., replace Line-16 of the code in #6 by&lt;/P&gt;

&lt;PRE class="brush:fortran;"&gt;     functn = 0
     do i=1,ndata
        functn=functn+(obsq(i)-q(i))**2
        write(*,'(F10.2)')functn
     end do
&lt;/PRE&gt;

&lt;P&gt;Sooner or later, you will have to learn to write your own programs, using a programming language suited for your needs.&lt;/P&gt;

&lt;P&gt;You will also need to describe your goals precisely. Vague statements such as those in #9 will not do. I have no idea as to where the numbers that you listed in #9 came from.&lt;/P&gt;</description>
      <pubDate>Sun, 28 Aug 2016 21:07:00 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112634#M129473</guid>
      <dc:creator>mecej4</dc:creator>
      <dc:date>2016-08-28T21:07:00Z</dc:date>
    </item>
    <item>
      <title>I think mecej4 is being very</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112635#M129474</link>
      <description>&lt;P&gt;I think mecej4 is being very kind to you. a little effort on your part is quite helpful to reviewers.&lt;/P&gt;

&lt;P&gt;Brooks&lt;/P&gt;</description>
      <pubDate>Sun, 04 Sep 2016 21:01:26 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112635#M129474</guid>
      <dc:creator>Brooks_Van_Horn</dc:creator>
      <dc:date>2016-09-04T21:01:26Z</dc:date>
    </item>
    <item>
      <title>Thank you mecej4. Your</title>
      <link>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112636#M129475</link>
      <description>&lt;P&gt;Thank you mecej4. Your comments were helpful to me.&lt;/P&gt;</description>
      <pubDate>Tue, 06 Sep 2016 19:50:27 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Fortran-Compiler/LOOP/m-p/1112636#M129475</guid>
      <dc:creator>Gloria_E_</dc:creator>
      <dc:date>2016-09-06T19:50:27Z</dc:date>
    </item>
  </channel>
</rss>

