sc/qa/unit/data/functions/array/fods/fourier.fods |  236 +++++++++++++++++++---
 sc/source/core/tool/interpr3.cxx                  |    8 
 2 files changed, 215 insertions(+), 29 deletions(-)

New commits:
commit e324a6cea23fe19ec8a67f368c31e1567928a5af
Author:     Dennis Francis <dennis.fran...@collabora.com>
AuthorDate: Thu Jun 20 11:59:44 2019 +0530
Commit:     Dennis Francis <dennis.fran...@collabora.com>
CommitDate: Thu Jun 20 13:18:11 2019 +0200

    tdf#126012: Take care of polar and min-magnitude flags...
    
    even in one point case (FOURIER). Add relevant test cases too.
    
    Change-Id: I647ac14ff8e9ee11664b23b37d150f51e6a08354
    Reviewed-on: https://gerrit.libreoffice.org/74412
    Reviewed-by: Dennis Francis <dennis.fran...@collabora.com>
    Tested-by: Dennis Francis <dennis.fran...@collabora.com>

diff --git a/sc/qa/unit/data/functions/array/fods/fourier.fods 
b/sc/qa/unit/data/functions/array/fods/fourier.fods
index 789e1bd15f73..91b1aa4d098e 100644
--- a/sc/qa/unit/data/functions/array/fods/fourier.fods
+++ b/sc/qa/unit/data/functions/array/fods/fourier.fods
@@ -1,20 +1,20 @@
 <?xml version="1.0" encoding="UTF-8"?>
 
 <office:document 
xmlns:office="urn:oasis:names:tc:opendocument:xmlns:office:1.0" 
xmlns:style="urn:oasis:names:tc:opendocument:xmlns:style:1.0" 
xmlns:text="urn:oasis:names:tc:opendocument:xmlns:text:1.0" 
xmlns:table="urn:oasis:names:tc:opendocument:xmlns:table:1.0" 
xmlns:draw="urn:oasis:names:tc:opendocument:xmlns:drawing:1.0" 
xmlns:fo="urn:oasis:names:tc:opendocument:xmlns:xsl-fo-compatible:1.0" 
xmlns:xlink="http://www.w3.org/1999/xlink"; 
xmlns:dc="http://purl.org/dc/elements/1.1/"; 
xmlns:meta="urn:oasis:names:tc:opendocument:xmlns:meta:1.0" 
xmlns:number="urn:oasis:names:tc:opendocument:xmlns:datastyle:1.0" 
xmlns:presentation="urn:oasis:names:tc:opendocument:xmlns:presentation:1.0" 
xmlns:svg="urn:oasis:names:tc:opendocument:xmlns:svg-compatible:1.0" 
xmlns:chart="urn:oasis:names:tc:opendocument:xmlns:chart:1.0" 
xmlns:dr3d="urn:oasis:names:tc:opendocument:xmlns:dr3d:1.0" 
xmlns:math="http://www.w3.org/1998/Math/MathML"; 
xmlns:form="urn:oasis:names:tc:opendocument:xmlns:form:1.0" xmlns:scr
 ipt="urn:oasis:names:tc:opendocument:xmlns:script:1.0" 
xmlns:config="urn:oasis:names:tc:opendocument:xmlns:config:1.0" 
xmlns:ooo="http://openoffice.org/2004/office"; 
xmlns:ooow="http://openoffice.org/2004/writer"; 
xmlns:oooc="http://openoffice.org/2004/calc"; 
xmlns:dom="http://www.w3.org/2001/xml-events"; 
xmlns:xforms="http://www.w3.org/2002/xforms"; 
xmlns:xsd="http://www.w3.org/2001/XMLSchema"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xmlns:rpt="http://openoffice.org/2005/report"; 
xmlns:of="urn:oasis:names:tc:opendocument:xmlns:of:1.2" 
xmlns:xhtml="http://www.w3.org/1999/xhtml"; 
xmlns:grddl="http://www.w3.org/2003/g/data-view#"; 
xmlns:tableooo="http://openoffice.org/2009/table"; 
xmlns:drawooo="http://openoffice.org/2010/draw"; 
xmlns:calcext="urn:org:documentfoundation:names:experimental:calc:xmlns:calcext:1.0"
 
xmlns:loext="urn:org:documentfoundation:names:experimental:office:xmlns:loext:1.0"
 xmlns:field="urn:openoffice:names:experimental:ooo-ms-interop:xmlns:field:1.0" 
xmlns:form
 x="urn:openoffice:names:experimental:ooxml-odf-interop:xmlns:form:1.0" 
xmlns:css3t="http://www.w3.org/TR/css3-text/"; office:version="1.2" 
office:mimetype="application/vnd.oasis.opendocument.spreadsheet">
- 
<office:meta><meta:creation-date>2019-02-19T14:19:02.782037492</meta:creation-date><dc:date>2019-03-03T16:30:38.015797381</dc:date><meta:editing-duration>PT2H52M20S</meta:editing-duration><meta:editing-cycles>66</meta:editing-cycles><meta:generator>LibreOfficeDev/6.3.0.0.alpha0$Linux_X86_64
 
LibreOffice_project/b4df9b0b4c7411f257b0a397687587114a53208e</meta:generator><meta:document-statistic
 meta:table-count="3" meta:cell-count="2175" 
meta:object-count="0"/></office:meta>
+ 
<office:meta><meta:creation-date>2019-02-19T14:19:02.782037492</meta:creation-date><dc:date>2019-06-20T11:49:43.838698519</dc:date><meta:editing-duration>PT3H13M28S</meta:editing-duration><meta:editing-cycles>71</meta:editing-cycles><meta:generator>LibreOfficeDev/6.3.0.0.alpha0$Linux_X86_64
 
LibreOffice_project/74a7b890524af4a52e711d8f0793ce844ded0948</meta:generator><meta:document-statistic
 meta:table-count="3" meta:cell-count="2235" 
meta:object-count="0"/></office:meta>
  <office:settings>
   <config:config-item-set config:name="ooo:view-settings">
    <config:config-item config:name="VisibleAreaTop" 
config:type="int">0</config:config-item>
    <config:config-item config:name="VisibleAreaLeft" 
config:type="int">0</config:config-item>
-   <config:config-item config:name="VisibleAreaWidth" 
config:type="int">20041</config:config-item>
-   <config:config-item config:name="VisibleAreaHeight" 
config:type="int">4713</config:config-item>
+   <config:config-item config:name="VisibleAreaWidth" 
config:type="int">58208</config:config-item>
+   <config:config-item config:name="VisibleAreaHeight" 
config:type="int">25287</config:config-item>
    <config:config-item-map-indexed config:name="Views">
     <config:config-item-map-entry>
      <config:config-item config:name="ViewId" 
config:type="string">view1</config:config-item>
      <config:config-item-map-named config:name="Tables">
       <config:config-item-map-entry config:name="Sheet1">
        <config:config-item config:name="CursorPositionX" 
config:type="int">1</config:config-item>
-       <config:config-item config:name="CursorPositionY" 
config:type="int">8</config:config-item>
+       <config:config-item config:name="CursorPositionY" 
config:type="int">17</config:config-item>
        <config:config-item config:name="HorizontalSplitMode" 
config:type="short">0</config:config-item>
        <config:config-item config:name="VerticalSplitMode" 
config:type="short">0</config:config-item>
        <config:config-item config:name="HorizontalSplitPosition" 
config:type="int">0</config:config-item>
@@ -31,8 +31,8 @@
        <config:config-item config:name="AnchoredTextOverflowLegacy" 
config:type="boolean">false</config:config-item>
       </config:config-item-map-entry>
       <config:config-item-map-entry config:name="Sheet2">
-       <config:config-item config:name="CursorPositionX" 
config:type="int">0</config:config-item>
-       <config:config-item config:name="CursorPositionY" 
config:type="int">3</config:config-item>
+       <config:config-item config:name="CursorPositionX" 
config:type="int">1</config:config-item>
+       <config:config-item config:name="CursorPositionY" 
config:type="int">71</config:config-item>
        <config:config-item config:name="HorizontalSplitMode" 
config:type="short">0</config:config-item>
        <config:config-item config:name="VerticalSplitMode" 
config:type="short">0</config:config-item>
        <config:config-item config:name="HorizontalSplitPosition" 
config:type="int">0</config:config-item>
@@ -41,7 +41,7 @@
        <config:config-item config:name="PositionLeft" 
config:type="int">0</config:config-item>
        <config:config-item config:name="PositionRight" 
config:type="int">0</config:config-item>
        <config:config-item config:name="PositionTop" 
config:type="int">0</config:config-item>
-       <config:config-item config:name="PositionBottom" 
config:type="int">0</config:config-item>
+       <config:config-item config:name="PositionBottom" 
config:type="int">44</config:config-item>
        <config:config-item config:name="ZoomType" 
config:type="short">0</config:config-item>
        <config:config-item config:name="ZoomValue" 
config:type="int">100</config:config-item>
        <config:config-item config:name="PageViewZoomValue" 
config:type="int">60</config:config-item>
@@ -49,8 +49,8 @@
        <config:config-item config:name="AnchoredTextOverflowLegacy" 
config:type="boolean">false</config:config-item>
       </config:config-item-map-entry>
       <config:config-item-map-entry config:name="Sheet3">
-       <config:config-item config:name="CursorPositionX" 
config:type="int">4</config:config-item>
-       <config:config-item config:name="CursorPositionY" 
config:type="int">39</config:config-item>
+       <config:config-item config:name="CursorPositionX" 
config:type="int">3</config:config-item>
+       <config:config-item config:name="CursorPositionY" 
config:type="int">15</config:config-item>
        <config:config-item config:name="HorizontalSplitMode" 
config:type="short">0</config:config-item>
        <config:config-item config:name="VerticalSplitMode" 
config:type="short">0</config:config-item>
        <config:config-item config:name="HorizontalSplitPosition" 
config:type="int">0</config:config-item>
@@ -67,8 +67,8 @@
        <config:config-item config:name="AnchoredTextOverflowLegacy" 
config:type="boolean">false</config:config-item>
       </config:config-item-map-entry>
      </config:config-item-map-named>
-     <config:config-item config:name="ActiveTable" 
config:type="string">Sheet1</config:config-item>
-     <config:config-item config:name="HorizontalScrollbarWidth" 
config:type="int">1861</config:config-item>
+     <config:config-item config:name="ActiveTable" 
config:type="string">Sheet2</config:config-item>
+     <config:config-item config:name="HorizontalScrollbarWidth" 
config:type="int">1307</config:config-item>
      <config:config-item config:name="ZoomType" 
config:type="short">0</config:config-item>
      <config:config-item config:name="ZoomValue" 
config:type="int">100</config:config-item>
      <config:config-item config:name="PageViewZoomValue" 
config:type="int">60</config:config-item>
@@ -125,9 +125,9 @@
      <config:config-item config:name="EndLine" config:type="string"/>
     </config:config-item-map-entry>
    </config:config-item-map-indexed>
-   <config:config-item config:name="PrinterName" config:type="string">Generic 
Printer</config:config-item>
+   <config:config-item config:name="PrinterName" 
config:type="string">DeskJet-2130-series</config:config-item>
    <config:config-item config:name="PrinterPaperFromSetup" 
config:type="boolean">false</config:config-item>
-   <config:config-item config:name="PrinterSetup" 
config:type="base64Binary">nwH+/0dlbmVyaWMgUHJpbnRlcgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAU0dFTlBSVAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAWAAMAwAAAAAAAAAAEAAhSAAAEdAAASm9iRGF0YSAxCnByaW50ZXI9R2VuZXJpYyBQcmludGVyCm9yaWVudGF0aW9uPVBvcnRyYWl0CmNvcGllcz0xCmNvbGxhdGU9ZmFsc2UKbWFyZ2luZGFqdXN0bWVudD0wLDAsMCwwCmNvbG9yZGVwdGg9MjQKcHNsZXZlbD0wCnBkZmRldmljZT0xCmNvbG9yZGV2aWNlPTAKUFBEQ29udGV4RGF0YQpEdXBsZXg6Tm9uZQBQYWdlU2l6ZTpBNAAAEgBDT01QQVRfRFVQTEVYX01PREUPAER1cGxleE1vZGU6Ok9mZg==</config:config-item>
+   <config:config-item config:name="PrinterSetup" 
config:type="base64Binary">qgH+/0Rlc2tKZXQtMjEzMC1zZXJpZXMAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAQ1VQUzpEZXNrSmV0LTIxMzAtc2VyaWVzAAAAAAAAAAAWAAMAxwAAAAAAAAAEAAhSAAAEdAAASm9iRGF0YSAxCnByaW50ZXI9RGVza0pldC0yMTMwLXNlcmllcwpvcmllbnRhdGlvbj1Qb3J0cmFpdApjb3BpZXM9MQpjb2xsYXRlPWZhbHNlCm1hcmdpbmRhanVzdG1lbnQ9MCwwLDAsMApjb2xvcmRlcHRoPTI0CnBzbGV2ZWw9MApwZGZkZXZpY2U9MQpjb2xvcmRldmljZT0wClBQRENvbnRleERhdGEKUGFnZVNpemU6QTQASW5wdXRTbG90Ok1haW4AABIAQ09NUEFUX0RVUExFWF9NT0RFEwBEdXBsZXhNb2RlOjpVbmtub3du</config:config-item>
    <config:config-item config:name="EmbedOnlyUsedFonts" 
config:type="boolean">false</config:config-item>
    <config:config-item config:name="ApplyUserData" 
config:type="boolean">true</config:config-item>
    <config:config-item config:name="EmbedComplexScriptFonts" 
config:type="boolean">true</config:config-item>
@@ -1624,8 +1624,6 @@
   <style:style style:name="ce22" style:family="table-cell" 
style:parent-style-name="Default" style:data-style-name="N99">
    <style:table-cell-properties style:text-align-source="fix" 
style:repeat-content="false"/>
    <style:paragraph-properties fo:text-align="center" fo:margin-left="0pt"/>
-   <style:map style:condition="cell-content()=1" style:apply-style-name="Good" 
style:base-cell-address="Sheet1.B3"/>
-   <style:map style:condition="cell-content()=0" style:apply-style-name="Bad" 
style:base-cell-address="Sheet1.B3"/>
   </style:style>
   <style:style style:name="ce23" style:family="table-cell" 
style:parent-style-name="Default">
    <style:table-cell-properties fo:background-color="#000000"/>
@@ -1637,18 +1635,12 @@
   <style:style style:name="ce25" style:family="table-cell" 
style:parent-style-name="Default">
    <style:text-properties fo:color="#3465a4" fo:font-weight="bold" 
style:font-weight-asian="bold" style:font-weight-complex="bold"/>
   </style:style>
-  <style:style style:name="ce26" style:family="table-cell" 
style:parent-style-name="Default" style:data-style-name="N99">
-   <style:map style:condition="cell-content()=1" style:apply-style-name="Good" 
style:base-cell-address="Sheet2.N2"/>
-   <style:map style:condition="cell-content()=0" style:apply-style-name="Bad" 
style:base-cell-address="Sheet2.N2"/>
-  </style:style>
+  <style:style style:name="ce26" style:family="table-cell" 
style:parent-style-name="Default" style:data-style-name="N99"/>
   <style:style style:name="ce27" style:family="table-cell" 
style:parent-style-name="Default">
    <style:table-cell-properties fo:background-color="#ffff00"/>
    <style:text-properties fo:color="#ff0000"/>
   </style:style>
-  <style:style style:name="ce10" style:family="table-cell" 
style:parent-style-name="Default" style:data-style-name="N99">
-   <style:map style:condition="cell-content()=1" style:apply-style-name="Good" 
style:base-cell-address="Sheet3.N2"/>
-   <style:map style:condition="cell-content()=0" style:apply-style-name="Bad" 
style:base-cell-address="Sheet3.N2"/>
-  </style:style>
+  <style:style style:name="ce10" style:family="table-cell" 
style:parent-style-name="Default" style:data-style-name="N99"/>
   <style:page-layout style:name="pm1">
    <style:page-layout-properties style:writing-mode="lr-tb"/>
    <style:header-style>
@@ -1689,7 +1681,7 @@
      
<text:p><text:sheet-name>???</text:sheet-name><text:s/>(<text:title>???</text:title>)</text:p>
     </style:region-left>
     <style:region-right>
-     <text:p><text:date style:data-style-name="N2" 
text:date-value="2019-03-03">00/00/0000</text:date>, <text:time 
style:data-style-name="N2" 
text:time-value="15:46:05.649339134">00:00:00</text:time></text:p>
+     <text:p><text:date style:data-style-name="N2" 
text:date-value="2019-06-20">00/00/0000</text:date>, <text:time 
style:data-style-name="N2" 
text:time-value="11:56:21.139087245">00:00:00</text:time></text:p>
     </style:region-right>
    </style:header>
    <style:header-left style:display="false"/>
@@ -1703,6 +1695,7 @@
   <office:spreadsheet>
    <table:calculation-settings table:automatic-find-labels="false" 
table:use-regular-expressions="false" table:use-wildcards="true"/>
    <table:table table:name="Sheet1" table:style-name="ta1">
+    <office:forms form:automatic-focus="false" form:apply-design-mode="false"/>
     <table:table-column table:style-name="co1" 
table:default-cell-style-name="Default"/>
     <table:table-column table:style-name="co2" 
table:default-cell-style-name="Default"/>
     <table:table-column table:style-name="co3" 
table:default-cell-style-name="Default"/>
@@ -1742,7 +1735,7 @@
      <table:table-cell office:value-type="string" calcext:value-type="string">
       <text:p>Sheet2</text:p>
      </table:table-cell>
-     <table:table-cell table:style-name="ce22" 
table:formula="of:=AND([Sheet2.$N$2:.$S$52])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+     <table:table-cell table:style-name="ce22" 
table:formula="of:=AND([Sheet2.$N$2:.$S$56])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
       <text:p>TRUE</text:p>
      </table:table-cell>
      <table:table-cell office:value-type="string" calcext:value-type="string">
@@ -1768,6 +1761,7 @@
     </calcext:conditional-formats>
    </table:table>
    <table:table table:name="Sheet2" table:style-name="ta1">
+    <office:forms form:automatic-focus="false" form:apply-design-mode="false"/>
     <table:table-column table:style-name="co4" 
table:number-columns-repeated="13" table:default-cell-style-name="Default"/>
     <table:table-column table:style-name="co5" 
table:default-cell-style-name="ce26"/>
     <table:table-column table:style-name="co6" 
table:number-columns-repeated="2" table:default-cell-style-name="ce26"/>
@@ -4620,11 +4614,199 @@
     <table:table-row table:style-name="ro2">
      <table:table-cell table:style-name="ce24" 
table:number-columns-repeated="12"/>
      <table:table-cell/>
-     <table:table-cell table:style-name="Default" 
table:number-columns-repeated="6"/>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$C53]); 1; 
ABS([.$C53]-[.$E53])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$D53]); 1; 
ABS([.$D53]-[.$F53])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$G53]); 1; 
ABS([.$G53]-[.$I53])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$H53]); 1; 
ABS([.$H53]-[.$J53])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$K53]); 1; 
ABS([.$K53]-[.$A53])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$L53]); 1; 
ABS([.$L53]-[.$B53])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:number-columns-repeated="2"/>
+    </table:table-row>
+    <table:table-row table:style-name="ro2">
+     <table:table-cell office:value-type="float" office:value="-0.5" 
calcext:value-type="float">
+      <text:p>-0.5</text:p>
+     </table:table-cell>
+     <table:table-cell office:value-type="float" office:value="0" 
calcext:value-type="float">
+      <text:p>0</text:p>
+     </table:table-cell>
+     <table:table-cell table:number-matrix-columns-spanned="2" 
table:number-matrix-rows-spanned="1" 
table:formula="of:=ORG.LIBREOFFICE.FOURIER([.A54:.B54];1)" 
office:value-type="float" office:value="-0.5" calcext:value-type="float">
+      <text:p>-0.5</text:p>
+     </table:table-cell>
+     <table:table-cell office:value-type="float" office:value="0" 
calcext:value-type="float">
+      <text:p>0</text:p>
+     </table:table-cell>
+     <table:table-cell office:value-type="float" office:value="-0.5" 
calcext:value-type="float">
+      <text:p>-0.5</text:p>
+     </table:table-cell>
+     <table:table-cell office:value-type="float" office:value="0" 
calcext:value-type="float">
+      <text:p>0</text:p>
+     </table:table-cell>
+     <table:table-cell table:number-matrix-columns-spanned="2" 
table:number-matrix-rows-spanned="1" 
table:formula="of:=ORG.LIBREOFFICE.FOURIER([.A54:.B54];1;;1)" 
office:value-type="float" office:value="0.5" calcext:value-type="float">
+      <text:p>0.5</text:p>
+     </table:table-cell>
+     <table:table-cell office:value-type="float" 
office:value="3.14159265358979" calcext:value-type="float">
+      <text:p>3.14159265358979</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=SQRT([.C54]*[.C54]+[.D54]*[.D54])" 
office:value-type="float" office:value="0.5" calcext:value-type="float">
+      <text:p>0.5</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=ATAN2([.C54];[.D54])" 
office:value-type="float" office:value="3.14159265358979" 
calcext:value-type="float">
+      <text:p>3.14159265358979</text:p>
+     </table:table-cell>
+     <table:table-cell table:number-matrix-columns-spanned="2" 
table:number-matrix-rows-spanned="1" 
table:formula="of:=ORG.LIBREOFFICE.FOURIER([.C54:.D54];1;1)" 
office:value-type="float" office:value="-0.5" calcext:value-type="float">
+      <text:p>-0.5</text:p>
+     </table:table-cell>
+     <table:table-cell office:value-type="float" office:value="0" 
calcext:value-type="float">
+      <text:p>0</text:p>
+     </table:table-cell>
+     <table:table-cell/>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$C54]); 1; 
ABS([.$C54]-[.$E54])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$D54]); 1; 
ABS([.$D54]-[.$F54])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$G54]); 1; 
ABS([.$G54]-[.$I54])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$H54]); 1; 
ABS([.$H54]-[.$J54])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$K54]); 1; 
ABS([.$K54]-[.$A54])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$L54]); 1; 
ABS([.$L54]-[.$B54])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:number-columns-repeated="2"/>
+    </table:table-row>
+    <table:table-row table:style-name="ro2">
+     <table:table-cell office:value-type="float" office:value="0" 
calcext:value-type="float">
+      <text:p>0</text:p>
+     </table:table-cell>
+     <table:table-cell office:value-type="float" office:value="-0.5" 
calcext:value-type="float">
+      <text:p>-0.5</text:p>
+     </table:table-cell>
+     <table:table-cell table:number-matrix-columns-spanned="2" 
table:number-matrix-rows-spanned="1" 
table:formula="of:=ORG.LIBREOFFICE.FOURIER([.A55:.B55];1)" 
office:value-type="float" office:value="0" calcext:value-type="float">
+      <text:p>0</text:p>
+     </table:table-cell>
+     <table:table-cell office:value-type="float" office:value="-0.5" 
calcext:value-type="float">
+      <text:p>-0.5</text:p>
+     </table:table-cell>
+     <table:table-cell office:value-type="float" office:value="0" 
calcext:value-type="float">
+      <text:p>0</text:p>
+     </table:table-cell>
+     <table:table-cell office:value-type="float" office:value="-0.5" 
calcext:value-type="float">
+      <text:p>-0.5</text:p>
+     </table:table-cell>
+     <table:table-cell table:number-matrix-columns-spanned="2" 
table:number-matrix-rows-spanned="1" 
table:formula="of:=ORG.LIBREOFFICE.FOURIER([.A55:.B55];1;;1)" 
office:value-type="float" office:value="0.5" calcext:value-type="float">
+      <text:p>0.5</text:p>
+     </table:table-cell>
+     <table:table-cell office:value-type="float" 
office:value="-1.5707963267949" calcext:value-type="float">
+      <text:p>-1.5707963267949</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=SQRT([.C55]*[.C55]+[.D55]*[.D55])" 
office:value-type="float" office:value="0.5" calcext:value-type="float">
+      <text:p>0.5</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=ATAN2([.C55];[.D55])" 
office:value-type="float" office:value="-1.5707963267949" 
calcext:value-type="float">
+      <text:p>-1.5707963267949</text:p>
+     </table:table-cell>
+     <table:table-cell table:number-matrix-columns-spanned="2" 
table:number-matrix-rows-spanned="1" 
table:formula="of:=ORG.LIBREOFFICE.FOURIER([.C55:.D55];1;1)" 
office:value-type="float" office:value="0" calcext:value-type="float">
+      <text:p>0</text:p>
+     </table:table-cell>
+     <table:table-cell office:value-type="float" office:value="-0.5" 
calcext:value-type="float">
+      <text:p>-0.5</text:p>
+     </table:table-cell>
+     <table:table-cell/>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$C55]); 1; 
ABS([.$C55]-[.$E55])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$D55]); 1; 
ABS([.$D55]-[.$F55])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$G55]); 1; 
ABS([.$G55]-[.$I55])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$H55]); 1; 
ABS([.$H55]-[.$J55])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$K55]); 1; 
ABS([.$K55]-[.$A55])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$L55]); 1; 
ABS([.$L55]-[.$B55])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:number-columns-repeated="2"/>
+    </table:table-row>
+    <table:table-row table:style-name="ro2">
+     <table:table-cell office:value-type="float" office:value="0.003" 
calcext:value-type="float">
+      <text:p>0.003</text:p>
+     </table:table-cell>
+     <table:table-cell office:value-type="float" office:value="-0.0002" 
calcext:value-type="float">
+      <text:p>-0.0002</text:p>
+     </table:table-cell>
+     <table:table-cell table:number-matrix-columns-spanned="2" 
table:number-matrix-rows-spanned="1" 
table:formula="of:=ORG.LIBREOFFICE.FOURIER([.A56:.B56];1)" 
office:value-type="float" office:value="0.003" calcext:value-type="float">
+      <text:p>0.003</text:p>
+     </table:table-cell>
+     <table:table-cell office:value-type="float" office:value="-0.0002" 
calcext:value-type="float">
+      <text:p>-0.0002</text:p>
+     </table:table-cell>
+     <table:table-cell office:value-type="float" office:value="0.003" 
calcext:value-type="float">
+      <text:p>0.003</text:p>
+     </table:table-cell>
+     <table:table-cell office:value-type="float" office:value="-0.0002" 
calcext:value-type="float">
+      <text:p>-0.0002</text:p>
+     </table:table-cell>
+     <table:table-cell table:number-matrix-columns-spanned="2" 
table:number-matrix-rows-spanned="1" 
table:formula="of:=ORG.LIBREOFFICE.FOURIER([.A56:.B56];1;;1;0.01)" 
office:value-type="float" office:value="0" calcext:value-type="float">
+      <text:p>0</text:p>
+     </table:table-cell>
+     <table:table-cell office:value-type="float" office:value="0" 
calcext:value-type="float">
+      <text:p>0</text:p>
+     </table:table-cell>
+     <table:table-cell table:number-columns-repeated="2" 
office:value-type="float" office:value="0" calcext:value-type="float">
+      <text:p>0</text:p>
+     </table:table-cell>
+     <table:table-cell table:number-matrix-columns-spanned="2" 
table:number-matrix-rows-spanned="1" 
table:formula="of:=ORG.LIBREOFFICE.FOURIER([.C56:.D56];1;1)" 
office:value-type="float" office:value="0.003" calcext:value-type="float">
+      <text:p>0.003</text:p>
+     </table:table-cell>
+     <table:table-cell office:value-type="float" office:value="-0.0002" 
calcext:value-type="float">
+      <text:p>-0.0002</text:p>
+     </table:table-cell>
+     <table:table-cell/>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$C56]); 1; 
ABS([.$C56]-[.$E56])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$D56]); 1; 
ABS([.$D56]-[.$F56])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$G56]); 1; 
ABS([.$G56]-[.$I56])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$H56]); 1; 
ABS([.$H56]-[.$J56])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$K56]); 1; 
ABS([.$K56]-[.$A56])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
+     <table:table-cell table:formula="of:=IF(ISBLANK([.$L56]); 1; 
ABS([.$L56]-[.$B56])&lt;[.$U$1])" office:value-type="boolean" 
office:boolean-value="true" calcext:value-type="boolean">
+      <text:p>TRUE</text:p>
+     </table:table-cell>
      <table:table-cell table:number-columns-repeated="2"/>
     </table:table-row>
     <calcext:conditional-formats>
-     <calcext:conditional-format 
calcext:target-range-address="Sheet2.N2:Sheet2.S52">
+     <calcext:conditional-format 
calcext:target-range-address="Sheet2.N2:Sheet2.S56">
       <calcext:condition calcext:apply-style-name="Good" calcext:value="=1" 
calcext:base-cell-address="Sheet2.N2"/>
       <calcext:condition calcext:apply-style-name="Bad" calcext:value="=0" 
calcext:base-cell-address="Sheet2.N2"/>
      </calcext:conditional-format>
diff --git a/sc/source/core/tool/interpr3.cxx b/sc/source/core/tool/interpr3.cxx
index 9dffa0d11b28..85eb4b7167a4 100644
--- a/sc/source/core/tool/interpr3.cxx
+++ b/sc/source/core/tool/interpr3.cxx
@@ -5360,8 +5360,12 @@ ScMatrixRef 
ScFFT::Compute(std::function<ScMatrixGenerator>& rMatGenFunc)
     SCSIZE nPoints = mbReal ? aArray.size() : (aArray.size()/2);
     if (nPoints == 1)
     {
-        mpInputMat->Resize(2, 1, 0.0);
-        return mpInputMat;
+        std::vector<double> aOutArray(2);
+        aOutArray[0] = aArray[0];
+        aOutArray[1] = mbReal ? 0.0 : aArray[1];
+        if (mbPolar)
+            lcl_convertToPolar(aOutArray, mfMinMag);
+        return rMatGenFunc(2, 1, aOutArray);
     }
 
     if (mbReal && (nPoints % 2) == 0)
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to