Skip to content

Commit

Permalink
add cutouts example, fix cutOutSides element name (#791) (thanks @sde…
Browse files Browse the repository at this point in the history
  • Loading branch information
MarAlder committed Aug 9, 2023
1 parent f803ed3 commit f55186f
Show file tree
Hide file tree
Showing 2 changed files with 339 additions and 1 deletion.
338 changes: 338 additions & 0 deletions examples/wing_cutOuts.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,338 @@
<?xml version="1.0" encoding="UTF-8"?>
<cpacs xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../schema/cpacs_schema.xsd">
<header>
<name>Wing CutOut example</name>
<version>1.1</version>
<versionInfos>
<versionInfo version="1.1">
<creator>Descartes</creator>
<timestamp>2023-08-09T09:56:24</timestamp>
<description>Demonstration of wing cutout</description>
<cpacsVersion>3.5</cpacsVersion>
</versionInfo>
</versionInfos>
</header>
<vehicles>
<aircraft>
<model uID="model">
<name>model</name>
<wings>
<wing uID="Wing" symmetry="x-z-plane">
<name>Wing</name>
<transformation uID="Wing_transformation1">
<scaling uID="Wing_transformation1_scaling1">
<x>1</x>
<y>1</y>
<z>1</z>
</scaling>
<rotation uID="Wing_transformation1_rotation1">
<x>0</x>
<y>0</y>
<z>0</z>
</rotation>
<translation uID="Wing_transformation1_translation1">
<x>0</x>
<y>0</y>
<z>0</z>
</translation>
</transformation>
<sections>
<section uID="Wing_section1">
<name>Wing_section1</name>
<transformation uID="Wing_section1_transformation1">
<scaling uID="Wing_section1_transformation1_scaling1">
<x>2.22916</x>
<y>2.22916</y>
<z>2.22916</z>
</scaling>
<rotation uID="Wing_section1_transformation1_rotation1">
<x>0</x>
<y>0</y>
<z>0</z>
</rotation>
<translation uID="Wing_section1_transformation1_translation1">
<x>0</x>
<y>0</y>
<z>0</z>
</translation>
</transformation>
<elements>
<element uID="Wing_section1_element1">
<name>Wing_section1_element1</name>
<airfoilUID>NACA0012</airfoilUID>
<transformation uID="Wing_section1_element1_transformation1"/>
</element>
</elements>
</section>
<section uID="Wing_section2">
<name>Wing_section2</name>
<transformation uID="Wing_section2_transformation1">
<scaling uID="Wing_section2_transformation1_scaling1">
<x>1.36313</x>
<y>1.36313</y>
<z>1.36313</z>
</scaling>
<rotation uID="Wing_section2_transformation1_rotation1">
<x>0</x>
<y>0</y>
<z>0</z>
</rotation>
<translation uID="Wing_section2_transformation1_translation1">
<x>0.866025</x>
<y>1.5</y>
<z>0</z>
</translation>
</transformation>
<elements>
<element uID="Wing_section2_element1">
<name>Wing_section2_element1</name>
<airfoilUID>NACA0012</airfoilUID>
<transformation uID="Wing_section2_element1_transformation1"/>
</element>
</elements>
</section>
<section uID="Wing_section3">
<name>Wing_section3</name>
<transformation uID="Wing_section3_transformation1">
<scaling uID="Wing_section3_transformation1_scaling1">
<x>0.668747</x>
<y>0.668747</y>
<z>0.668747</z>
</scaling>
<rotation uID="Wing_section3_transformation1_rotation1">
<x>0</x>
<y>0</y>
<z>0</z>
</rotation>
<translation uID="Wing_section3_transformation1_translation1">
<x>2.88675</x>
<y>5</y>
<z>0</z>
</translation>
</transformation>
<elements>
<element uID="Wing_section3_element1">
<name>Wing_section3_element1</name>
<airfoilUID>NACA0012</airfoilUID>
<transformation uID="Wing_section3_element1_transformation1"/>
</element>
</elements>
</section>
</sections>
<segments>
<segment uID="Wing_segment1">
<name>Wing_segment1</name>
<fromElementUID>Wing_section1_element1</fromElementUID>
<toElementUID>Wing_section2_element1</toElementUID>
</segment>
<segment uID="Wing_segment2">
<name>Wing_segment2</name>
<fromElementUID>Wing_section2_element1</fromElementUID>
<toElementUID>Wing_section3_element1</toElementUID>
</segment>
</segments>
<componentSegments>
<componentSegment uID="WingCS">
<name>WingCS</name>
<fromElementUID>Wing_section1_element1</fromElementUID>
<toElementUID>Wing_section3_element1</toElementUID>
<structure>
<upperShell uID="WingCSUpperShell">
<skin>
<material>
<materialUID>dummyMaterial</materialUID>
</material>
</skin>
</upperShell>
<lowerShell uID="WingCSLowerShell">
<skin>
<material>
<materialUID>dummyMaterial</materialUID>
</material>
</skin>
</lowerShell>
<ribsDefinitions>
<ribsDefinition uID="Wing_rib01">
<name>Wing_rib01</name>
<ribsPositioning>
<startEtaXsiPoint>
<eta>0.1</eta>
<xsi>0.5</xsi>
<referenceUID>WingCS</referenceUID>
</startEtaXsiPoint>
<endEtaXsiPoint>
<eta>0.9</eta>
<xsi>0.5</xsi>
<referenceUID>WingCS</referenceUID>
</endEtaXsiPoint>
<ribStart>leadingEdge</ribStart>
<ribEnd>trailingEdge</ribEnd>
<numberOfRibs>7</numberOfRibs>
<ribReference>leadingEdge</ribReference>
<ribCrossingBehaviour>cross</ribCrossingBehaviour>
<ribRotation>
<z>90</z>
</ribRotation>
</ribsPositioning>
<ribCrossSection>
<material>
<materialUID>dummyMaterial</materialUID>
</material>
</ribCrossSection>
</ribsDefinition>
</ribsDefinitions>
<spars>
<sparPositions>
<sparPosition uID="Wing_spar01_pos01">
<sparPositionEtaXsi>
<eta>0</eta>
<xsi>0.15</xsi>
<referenceUID>Wing_segment1</referenceUID>
</sparPositionEtaXsi>
</sparPosition>
<sparPosition uID="Wing_spar01_pos02">
<sparPositionEtaXsi>
<eta>1</eta>
<xsi>0.15</xsi>
<referenceUID>Wing_segment2</referenceUID>
</sparPositionEtaXsi>
</sparPosition>
<sparPosition uID="Wing_spar02_pos01">
<sparPositionEtaXsi>
<eta>0</eta>
<xsi>0.65</xsi>
<referenceUID>Wing_segment1</referenceUID>
</sparPositionEtaXsi>
</sparPosition>
<sparPosition uID="Wing_spar02_pos02">
<sparPositionEtaXsi>
<eta>1</eta>
<xsi>0.65</xsi>
<referenceUID>Wing_segment2</referenceUID>
</sparPositionEtaXsi>
</sparPosition>
</sparPositions>
<sparSegments>
<sparSegment uID="Wing_spar01">
<name>Wing_spar01</name>
<description>Definition of wing spar Wing_spar01</description>
<sparPositionUIDs>
<sparPositionUID>Wing_spar01_pos01</sparPositionUID>
<sparPositionUID>Wing_spar01_pos02</sparPositionUID>
</sparPositionUIDs>
<sparCrossSection>
<web1>
<material>
<materialUID>dummyMaterial</materialUID>
</material>
<relPos>0.5</relPos>
</web1>
<rotation>90</rotation>
</sparCrossSection>
</sparSegment>
<sparSegment uID="Wing_spar02">
<name>Wing_spar02</name>
<description>Definition of wing spar Wing_spar02</description>
<sparPositionUIDs>
<sparPositionUID>Wing_spar02_pos01</sparPositionUID>
<sparPositionUID>Wing_spar02_pos02</sparPositionUID>
</sparPositionUIDs>
<sparCrossSection>
<web1>
<material>
<materialUID>dummyMaterial</materialUID>
</material>
<relPos>0.5</relPos>
</web1>
<rotation>90</rotation>
</sparCrossSection>
</sparSegment>
</sparSegments>
</spars>
<wingCutOuts>
<cutOut uID="Wing_cutout01">
<positioningLeadingEdge>
<xsi1>0</xsi1>
<xsi2>0</xsi2>
</positioningLeadingEdge>
<positioningTrailingEdge>
<sparUID>Wing_spar01</sparUID>
</positioningTrailingEdge>
<positioningInnerBorder>
<ribNumber>1</ribNumber>
<ribDefinitionUID>Wing_rib01</ribDefinitionUID>
</positioningInnerBorder>
<positioningOuterBorder>
<eta1>
<eta>0.3</eta>
<referenceUID>WingCS</referenceUID>
</eta1>
<eta2>
<eta>0.3</eta>
<referenceUID>WingCS</referenceUID>
</eta2>
</positioningOuterBorder>
<cutOutSides>both</cutOutSides>
</cutOut>
<cutOut uID="Wing_cutout02">
<positioningLeadingEdge>
<xsi1>0.4</xsi1>
<xsi2>0.4</xsi2>
</positioningLeadingEdge>
<positioningTrailingEdge>
<xsi1>0.5</xsi1>
<xsi2>0.5</xsi2>
</positioningTrailingEdge>
<positioningInnerBorder>
<eta1>
<eta>0</eta>
<referenceUID>WingCS</referenceUID>
</eta1>
<eta2>
<eta>0</eta>
<referenceUID>WingCS</referenceUID>
</eta2>
</positioningInnerBorder>
<positioningOuterBorder>
<eta1>
<eta>0.06</eta>
<referenceUID>WingCS</referenceUID>
</eta1>
<eta2>
<eta>0.08</eta>
<referenceUID>WingCS</referenceUID>
</eta2>
</positioningOuterBorder>
<cutOutSides>upper</cutOutSides>
</cutOut>
</wingCutOuts>
</structure>
</componentSegment>
</componentSegments>
</wing>
</wings>
</model>
</aircraft>
<profiles>
<wingAirfoils>
<wingAirfoil uID="NACA0012">
<name>NACA0012</name>
<pointList>
<x>1;0.955135;0.910361;0.865767;0.821443;0.777479;0.733963;0.690983;0.648625;0.606975;0.566116;0.526131;0.487101;0.449103;0.412215;0.37651;0.342061;0.308937;0.277205;0.246929;0.218169;0.190983;0.165427;0.141551;0.119404;0.0990311;0.0804722;0.0637651;0.0489435;0.0360371;0.0250721;0.0160704;0.00905024;0.00402571;0.00100693;0;0.00100693;0.00402571;0.00905024;0.0160704;0.0250721;0.0360371;0.0489435;0.0637651;0.0804722;0.0990311;0.119404;0.141551;0.165427;0.190983;0.218169;0.246929;0.277205;0.308937;0.342061;0.37651;0.412215;0.449103;0.487101;0.526131;0.566116;0.606975;0.648625;0.690983;0.733963;0.777479;0.821443;0.865767;0.910361;0.955135;1</x>
<y>0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0;0</y>
<z>-2.1684e-19;-0.00557559;-0.010874;-0.0155467;-0.0198545;-0.0239099;-0.0277128;-0.0312588;-0.0345405;-0.0375472;-0.0402659;-0.0426819;-0.0447799;-0.0465444;-0.0479606;-0.0490153;-0.0496975;-0.049999;-0.0499148;-0.0494435;-0.0485877;-0.0473536;-0.0457513;-0.0437944;-0.0414996;-0.0388862;-0.0359755;-0.0327902;-0.0293537;-0.0256889;-0.021818;-0.0177616;-0.013538;-0.00916246;-0.00464703;0;0.00464703;0.00916246;0.013538;0.0177616;0.021818;0.0256889;0.0293537;0.0327902;0.0359755;0.0388862;0.0414996;0.0437944;0.0457513;0.0473536;0.0485877;0.0494435;0.0499148;0.049999;0.0496975;0.0490153;0.0479606;0.0465444;0.0447799;0.0426819;0.0402659;0.0375472;0.0345405;0.0312588;0.0277128;0.0239099;0.0198545;0.0155467;0.010874;0.00557559;2.1684e-19</z>
</pointList>
</wingAirfoil>
</wingAirfoils>
</profiles>
<materials>
<material uID="dummyMaterial">
<name>dummyMaterial</name>
<rho>1.0</rho>
<isotropicProperties>
<E>1.0</E>
</isotropicProperties>
</material>
</materials>
</vehicles>
</cpacs>
2 changes: 1 addition & 1 deletion schema/cpacs_schema.xsd
Original file line number Diff line number Diff line change
Expand Up @@ -38470,7 +38470,7 @@ The fuel tank volume type should also be used for the wing fuel tank</xsd:docume
<xsd:element name="positioningTrailingEdge" type="cellPositioningChordwiseType"/>
<xsd:element name="positioningInnerBorder" type="cellPositioningSpanwiseType"/>
<xsd:element name="positioningOuterBorder" type="cellPositioningSpanwiseType"/>
<xsd:element name="cutOutSidesType">
<xsd:element name="cutOutSides">
<xsd:annotation>
<xsd:documentation>Type of the cutout (upper|lower|both): upper shell, lower shell or both.
</xsd:documentation>
Expand Down

0 comments on commit f55186f

Please sign in to comment.