
693 P.2d 1056 (1984)
107 Idaho 854
Rosmarie BOGNER, Plaintiff-Respondent,
v.
STATE of Idaho DEPARTMENT OF REVENUE AND TAXATION, STATE TAX COMMISSION, Defendant-Appellant.
No. 15300.
Supreme Court of Idaho.
December 31, 1984.
*1057 Jim Jones, Atty. Gen., William A. Von Tagen, argued, Deputy Atty. Gen., and Lynn E. Thomas, Sol. Gen., Boise, for defendant-appellant.
Douglas James Aanestad, of Hogue, Speck, & Aanestad, Ketchum, for plaintiff-respondent.
BISTLINE, Justice.

HISTORY
The plaintiff-respondent, Rosmarie Bogner, is a West German citizen and has been a resident of Idaho since 1981. Her principal source of income is derived from a family business in West Germany. As a German citizen residing in Idaho, plaintiff is taxed on her German income by three governmental entities: West Germany, the United States, and Idaho.
In 1982, plaintiff filed a 1981 income tax return with the Internal Revenue Service. On this return, she claimed a credit for taxes paid to West Germany pursuant to Internal Revenue Code § 901. At about the same time, plaintiff filed her Idaho state income tax return. On this return, she claimed a deduction for foreign taxes paid pursuant to her interpretation of I.C. § 63-3022 and Internal Revenue Code § 164.
An auditor for the State Tax Commission subsequently disallowed the claimed foreign tax deduction. According to the auditor, once plaintiff chose to take the federal tax credit, she could no longer take a foreign tax deduction under Idaho law.
*1058 Plaintiff protested the auditor's findings and asked for a redetermination by the State Tax Commission. The Commission reviewed the case, considered plaintiff's arguments, and affirmed the auditor's position. Plaintiff then paid the tax and took her case to the district court. In a memorandum opinion dated October 13, 1983, the district court, Judge Kramer, entered a judgment reversing the State Tax Commission. Thereafter, the district court, Judge Phillip N. Becker, in a ruling that the Tax Commission had pursued this case frivolously, unreasonably and without foundation, ordered that the Tax Commission pay plaintiff's attorney's fees and related costs and expenses. The Tax Commission's appeal to this Court challenges both the judgment and order.

I.
The first issue deals with whether plaintiff can take a federal tax credit for foreign income taxes paid while at the same time take a state tax deduction for those taxes paid. We hold that she was entitled to do so.
In 1981, I.C. § 63-3022 stated:
The term "taxable income" means "taxable income" as defined in Section 63 of the Internal Revenue Code, adjusted as follows:

... .
(1) In the case of natural persons, there shall be allowed as deductions from gross income either of the following at the option of the taxpayer: (1) the standard deduction as defined by section 63 Internal Revenue Code, or (2) itemized deductions as defined in sections 163, 164 ... Internal Revenue Code. (Emphasis added.)[1]
Section 164 of the Internal Revenue Code specifically defines foreign income taxes as an allowable deduction.[2] Idaho Income Tax Regulation 22(f) interprets § 63-3022(1) in the following manner:
Subsection (1) of Section 63-3022 of the Code authorizes individual taxpayers to itemize deductions on their Idaho income tax return as they may elect, without regard to whether or not they itemize on their federal returns. (Emphasis added.)
Thus, it is clear that an Idaho resident on his or her state income tax form can deduct from taxable income itemized deductions as defined by various sections of the Internal Revenue Code, including § 164, regardless of whether they choose to do so on their federal returns. This is exactly what plaintiff has done. Accordingly, the district court did not err in holding that the Tax Commission's denial of her deduction was improper.
The Tax Commission argues that plaintiff cannot take a state tax deduction for her foreign taxes paid because instead of taking a federal tax deduction she took a federal tax credit. Such a proposition, however, flies in the face of the wording of the applicable statutes and regulations.
I.C. § 63-3022(1) allows a state taxpayer to deduct expenses that are defined as itemized deductions by federal law. The section does not require the taxpayer to have actually taken the deduction. Idaho Income Tax Regulation 22(f) clearly indicates this. The Tax Commission's interpretation of § 63-3022(l) is nothing more than an attempt at rewriting the statute. Neither the Tax Commission nor the courts have such authority. See C.J.S. Constitutional Law § 169 and cites therein. The Tax Commission's function is to enforce the law as written. And as written, it is clear that plaintiff was within the law in doing what she did.
The Tax Commission argues, however, that plaintiff ought not get a state *1059 tax deduction, because by taking the federal tax credit § 275(a) of the Internal Revenue Code precludes her from also taking a federal tax deduction.[3] This argument is not convincing. Section 275(a)'s purpose is, for federal purposes, to prevent a federal taxpayer who has paid foreign taxes from gaining a double benefit by taking both a federal tax credit and deduction for the same expense. Section 275(a) says nothing about denying the taxpayer his or her choice of options at the state level; the fact that § 275(a) requires a federal taxpayer to elect between one of two federal alternatives does not mean that the taxpayer must use that same option for his or her state income tax return.
The incorrectness of the Tax Commission's position is further highlighted by the fact that Idaho state tax law has no provision for tax credits. Thus, following the Tax Commission's line of reasoning, a state taxpayer could only get a deduction for foreign taxes paid if he or she also took a federal tax deduction instead of a federal tax credit. We find no support for this reasoning in the cases relied upon by the Tax Commission which are from other jurisdictions: Caterpillar Tractor Co. v. Lecksos, 84 Ill.2d 102, 49 Ill.Dec. 329, 417 N.E.2d 1343 (1981); Albany International v. Halperin, 388 A.2d 902 (Me. 1978); Pennsylvania v. Westinghouse Electric Corp., 478 A.2d 491, 386 A.2d 491 (Pa. 1978). Each case is inapposite to the issue with which we are dealing. In all three states, the state tax law defines a taxpayer's taxable income to be that which is properly reported for federal income tax purposes. See Ill. Rev. Stat. 1977 ch. 120 ¶ 2-203(e)(1); Me.Rev.State.Ann.Tit. 36 § 5102(8); 72 Penn.Stat. § 3420(b)(2)(c). These states are far different from Idaho's, which defines taxable income by starting with "gross income" for federal purposes and then making numerous adjustments as set forth in I.C. § 63-3022. Thus, Idaho "taxable income" is nearly always different from federal "taxable income" because of adjustments unique to Idaho.
On the contrary, Rhode Island's tax laws are very similar to Idaho's. G.L. 1956 (1980 Reenactment) § 44-11-11(a)(3) provides that a taxpayer may reduce his or her gross income as reported on federal income tax return by "all items deductible under the federal income tax law applicable to the taxable year." Thus, Rhode Island, like Idaho, determines taxable income by making statutory adjustments to federal gross income. It is not surprising, then, that in a case considering the exact issue before us, the Rhode Island Supreme Court decided as we do that the state taxpayer can take a deduction for foreign taxes paid even when taking a federal tax credit for federal purposes. George, Inc. v. Norberg, 444 A.2d 868 (R.I. 1982).

II.
The second issue is whether the trial court properly awarded attorney's fees to plaintiff. I.C. § 12-121 states that in any civil action a judge may award reasonable attorney's fees with the proviso that this section shall not alter on appeal any statute which otherwise provides for the award of attorney's fees.
I.C. § 63-3049[4] is the section which governs the judicial review of State *1060 Tax Commission decisions. The Tax Commission argues that because § 63-3049 is silent as to attorney's fees and costs, a judge is precluded from making such awards. In other words, silence in the statute is said to constitute a denial of such fees. We know of no authority and can think of no logical reason to support such a proposition. An appeal to district court is for certain a civil action, and hence within the purview of I.C. § 12-121.
A judge's discretion to award attorney's fees under § 12-121 is in turn modified by I.R.C.P. 54(e)(1), which states that a judge may only award such fees when the case was "brought, pursued or defended frivolously, unreasonably or without foundation; ...." Rule 54(e)(2) states that whenever a court awards attorney's fees pursuant to § 12-121, it shall make written findings as to the basis and reasons for making such a reward. Here the court stated the following in awarding the fees:
The Defendant has pursued this action frivolously, unreasonably and without foundation in that it has misread and misinterpreted Idaho Code Sections 63-3002 and 63-3022 and the related regulations, and has been unprepared and dilatory in discussing the issues at an informal hearing with Plaintiff and at other times while Plaintiff was pursuing her administrative remedies.
While we find no evidence in the record that the Tax Commission was dilatory and unprepared, we do agree with the district court, however, that the Tax Commission has defended this case without foundation and unreasonably in misreading and misinterpreting I.C. §§ 63-3002 and 63-3022 to its advantage. These statutes are clear and unambiguous.
The Tax Commission also argues that the trial court incorrectly awarded plaintiff attorney's fees for costs incurred for legal representation at the administrative remedy stage, and hence prior to the actual filing of her complaint. For the reasons stated below we hold that she is so entitled.
In Minich v. Gem State Developers, 99 Idaho 911, 918, 591 P.2d 1078, 1085 (1979), we stated: "The clear purpose of [I.C. § 12-121] ... is to reimburse the successful party for legal fees incurred in prosecuting his or her legal rights." We find nothing in § 12-121 which establishes that the legislature intended to deny awards of attorney's fees for costs incurred in pursuing an administrative remedy prior to instigating the very civil action which necessarily resulted when that effort failed.
Our interpretation of § 12-121 is supported by the recent legislation of I.C. § 12-117:

*1061 Attorney's fees, witness fees and expenses awarded in certain instances.  (1) In any administrative or civil judicial proceeding involving as adverse parties a state agency and a person, the court shall award the person reasonable attorney's fees, witness fees and reasonable expenses, if the court finds in favor of the person and also finds that the state agency acted without a reasonable basis in fact or law.
We believe the purpose of that statute is two-fold: (1) to serve as a deterrent to groundless or arbitrary agency action; and (2) to provide a remedy for persons who have borne unfair and unjustified financial burdens defending against groundless charges or attempting to correct mistakes agencies should never had made. Accord Van Gordon v. Oregon State Board of Dental Examiners, 63 Or. App. 561, 666 P.2d 276, 280 (1983).
Those purposes are fulfilled by interpreting I.C. § 12-121 to uphold the lower court's granting of attorney's fees while plaintiff attempted at the administrative stage to correct mistakes the Tax Commission should have avoided.
For the foregoing reasons the judgment of the district court is affirmed. The order allowing attorney's fees is affirmed. Costs and attorney's fees on appeal to respondent.
SHEPARD and HUNTLEY, JJ., concur.
DONALDSON, C.J., concurs in part and dissents in part.
I dissent as to attorney's fees allowed at the administrative level.
BAKES, Justice, dissenting:
Plaintiff respondent, Rosmarie Bogner, relied upon I.C. § 63-3022(l)(2) to claim a deduction for foreign taxes paid. I.C. § 63-3022(l)(2) allows a taxpayer to deduct from gross income "(a.) itemized deductions as defined in sections 163, 164, ... 165, 166, 170, 171, 211, 212, 213, 216, and 218, Internal Revenue Code... ." Although Bogner did not take a federal tax deduction pursuant to I.R.C. § 164 for foreign taxes paid, the majority agrees with Bogner that pursuant to I.C. § 63-3022(l)(2) a deduction for foreign taxes paid may be taken for state tax purposes. I cannot agree.
In determining whether Bogner's deduction may be taken pursuant to I.C. § 63-3022(l)(2), this Court must be mindful of I.C. § 63-3002. I.C. § 63-3002 states:
"It is the intent of the legislature by the adoption of [the Idaho Income Tax Act], insofar as possible to make the provisions of the Idaho act identical to the provisions of the Federal Internal Revenue Code relating to the measurement of taxable income ...; to achieve this result by the application of the various provisions of the Federal Internal Revenue Code relating to the definition of income, exceptions therefrom, deductions (personal and otherwise)... ." (Emphasis added.)
Thus, by legislative mandate, I.C. § 63-3022(l)(2) must be interpreted so as to be consistent with the Internal Revenue Code. To achieve this result the entire Federal Internal Revenue Code must be examined.
Under the Internal Revenue Code, Bogner is not entitled to a § 164 deduction. I.R.C. § 164 allows a taxpayer to take a deduction for foreign taxes paid. However, I.R.C. § 164(f) specifically cross references the taxpayer to I.R.C. § 275. I.R.C. § 275 states:
"(a) No deduction shall be allowed for the following taxes:
... .
"(4) income, war profits, and excess profits taxes imposed by the authority of any foreign country or possession of the United States, if the taxpayer chooses to take to any extent the benefits of section 901 (relating to the foreign tax credit)." (Emphasis added.)
Under I.R.C. § 901 a taxpayer may elect to claim a tax credit for foreign taxes paid. The federal statutory scheme thus forces the taxpayer to choose between a deduction or a credit for foreign taxes paid. If the taxpayer chooses to take a tax credit under I.R.C. § 901, as Bogner did here, the taxpayer simply has no deduction available *1062 under I.R.C. § 164. Since I.C. § 63-3022(l)(2) adopts I.R.C. § 164 by reference, it is error for this Court to allow Bogner a deduction for state tax purposes when no deduction is available at the federal level.
I also dissent from the majority's position on the district court's award of attorney fees. The district court's conclusion that the State Tax Commission "frivolously, unreasonably and without foundation ... misread and misinterpreted I.C. § 63-3002 and 63-3022 ..." is not justified in this case. Attorney fees pursuant to I.C. § 12-121 are not to be awarded where a genuine issue of law is presented. Minich v. Gem State Developers, Inc., 99 Idaho 911, 918, 591 P.2d 1078, 1085 (1979). Simple disagreement with a party's position is not ample justification for the award of attorney fees under I.C. § 12-121. Even if the district court did not accept the tax commission's reading of the statutory language, the reading is defensible and reasonable. Further, as the majority acknowledges, the record does not indicate that the tax commission was dilatory or unprepared in pursuing this cause. Thus, I would reverse the district court's award of attorney fees.
Lastly, I find error in the district court's allowance of attorney fees under I.C. § 12-121 for costs incurred during the administrative proceedings. Although the 1984 enactment of I.C. § 12-117 opens the door for assessing attorney fees incurred during administrative proceedings, it does not apply retroactively to this case. See I.C. § 73-101. ("No part of these compiled laws is retroactive, unless expressly so declared.") The new statute was clearly enacted to provide for situations not previously addressed in I.C. § 12-121, which by its terms applies only to "civil actions," and not to administrative proceedings. Accordingly, I cannot agree that I.C. § 12-117 supports the majority's interpretation of I.C. § 12-121. On the contrary, the enactment of I.C. § 12-117 indicates that attorney fees incurred during administrative proceedings may not be awarded under I.C. § 12-121.
NOTES
[1]  Subsequent amendments of this section contain a similar definition.
[2]  Internal Revenue Code § 164(a) reads as follows:

(a) General Rule.  Except as otherwise provided in this section, the following taxes shall be allowed as a deduction for the taxable year within which paid or accrued:
(1) State and local, and foreign, real property taxes.
[3]  Internal Revenue Code § 275(a) reads as follows:

(a) General rule.  No deduction shall be allowed for the following taxes:
... .
(4) Income, war profits, and excess profits taxes imposed by the authority of any foreign country or possession of the United States, if the taxpayer chooses to take to any extent the benefits of section 901 (relating to the foreign tax credit).
[4]  That statute reads:

Judicial review.  (a) Redetermination by the state tax commission may be reviewed in the district court for Ada County or the county in which the taxpayer resides or has his principal office or place of business by a complaint filed by the taxpayer against the state tax commission within thirty (30) days after the receipt of notice of the decision of the state tax commission denying, in whole or in part, any protest of the taxpayer or, within the same thirty (30) day period, by filing an appeal with the board of tax appeals. Upon the serving of summons upon the state tax commission the case shall proceed as other civil cases but may be heard by the judge in chambers. If the case is appealed to the board of tax appeals, the hearing before that body shall proceed as set forth in the act creating such board. If the court finds that any tax is due, it shall enter judgment for such tax, including any interest or penalties that may also be due and owing, against the taxpayer. Any taxes, penalties or interest paid, found by the court to be in excess of that which can be legally assessed, shall be ordered refunded to the taxpayer with interest from the time of payment. In the case of sales or use tax and corporate income tax decisions by the state tax commission, when the amount in dispute at the time the notice of deficiency determination/overassessment is issued exceeds twenty-five thousand dollars ($25,000), no appeal to the board of tax appeals shall be allowed.
(b) Before any such appeal may be filed by the taxpayer, the taxpayer shall pay the tax or deficiency as assessed, together with interest and penalties thereon, or in lieu thereof file with the clerk of the court sufficient and adequate bond in double the amount of the tax penalty and interest claimed due from the taxpayer, executed by a surety company licensed and authorized to do business in the state of Idaho, conditioned upon the payment of any tax, penalty and interest that may be found due by the court. No act, order or proceeding shall be valid until after the time allowed for taking such court action has expired or such court action is finally determined.
(c) Any party to the proceedings may appeal to the Supreme Court from the judgment of the district court under the rules and regulation prescribed for appeals. If the appeal be taken by the state tax commission, he shall not be required to give any undertaking or to make any deposits to secure the cost of such appeal.
